67 Dshot(uint32_t speed_hz = 150000,
bool bidirectional =
false);
109 #endif //ARUNA_DSHOT_H uint32_t get_frequency()
get frequency of the driver
err_t _set(movement::axis_mask_t axisMask, int16_t speed) override
Implementation of axis movement, this function is called from set(...).
err_t write_frame_continuous(uint16_t dshot_frame)
Write set Dshot frame continuously on the bus.
void add_CRC(uint16_t &bits)
add CRC to end of bit stream.
Dshot(uint32_t speed_hz=150000, bool bidirectional=false)
Dshot parent object.
bool get_bidirectional()
Is this Dshot driver birectional (can spin both ways)
void set_bidirectional(bool is_bidirectional)
Set bidirectional property of the driver.
err_t set_speed(int16_t speed)
Set speed, use negative values to rotate in the other direction if bidirectional is enabled...
virtual err_t _write_frame_continuous(uint16_t dshot_frame)=0
Write set Dshot frame continuously on the bus.
void arm_ESC()
Call the function after the constructor to arm the ESC.
pthread_mutex_t write_mut
Link * driver
stores the driver.
uint16_t create_dshotFrame(uint16_t speed, uint8_t telemetry)
craft dshot package