uint16_t dynamixel_addr_t
register address type
@ DYNAMIXEL_TIMEOUT
No response from the device.
int dynamixel_read16(const dynamixel_t *device, dynamixel_addr_t reg, uint16_t *value)
Read from a device 16bits register.
uint8_t dynamixel_id_t
device id type
int dynamixel_write(const dynamixel_t *device, dynamixel_addr_t reg, const uint8_t *data, size_t length)
Write to a device address.
int dynamixel_read8(const dynamixel_t *device, dynamixel_addr_t reg, uint8_t *value)
Read from a device 8bits register.
void dynamixel_init(dynamixel_t *device, uart_half_duplex_t *stream, dynamixel_id_t id)
Initialize a Dynamixel device.
Dynamixel protocol definitions.
@ DYNAMIXEL_INVALID_MESSAGE
Invalid message received.
Descriptor struct for a dynamixel device.
int dynamixel_write8(const dynamixel_t *device, dynamixel_addr_t reg, uint8_t value)
Write to a device 8bits register.
uart_half_duplex_t * stream
the stream used
Descriptor struct for half-duplex UART.
dynamixel_id_t id
the device address
int dynamixel_read(const dynamixel_t *device, dynamixel_addr_t reg, uint8_t *data, size_t length)
Read from a device address.
int dynamixel_ping(uart_half_duplex_t *stream, dynamixel_id_t id)
Send a PING message to a device.
@ DYNAMIXEL_BUFFER_TOO_SMALL
Buffer is too small for the message.
Interface definition for half-duplex UART driver.
int dynamixel_write16(const dynamixel_t *device, dynamixel_addr_t reg, uint16_t value)
Write to a device 16bits register.