2025-05-18 17:34:52 +02:00

24 lines
509 B
C++

#pragma once
#include "Thing.h"
namespace RoboidControl {
class Motor : public Thing {
public:
Motor(Participant* owner);
// Motor(Thing* parent);
Motor(Thing& parent = Thing::Root);
/// @brief Motor turning direction
enum class Direction { Clockwise = 1, CounterClockwise = -1 };
/// @brief The forward turning direction of the motor
Direction direction;
virtual void SetTargetSpeed(float targetSpeed); // -1..0..1
protected:
float targetSpeed = 0;
};
} // namespace RoboidControl