Page 1 of 1

Position Control

Posted: Wed Aug 07, 2019 7:46 am
by rohmer
Hello,
I converted the Arduino library to WiringPi/Arduino.

In writing a driver specific to my task, I need to send position/speed.

Using SpeedDistanceM1M2, I need to go backwards, and reading various topics it says send a position of a negative number, yet the method signature is a uint32_t (Unsigned).

Is this a bug in the Arduino library or am I missing something

Re: Position Control

Posted: Wed Aug 07, 2019 9:52 am
by Basicmicro Support
Yes. Still send a negative number for reverse. It is converted to an unsigned value so that there are no odd sign conversions when sending the individual bytes of the position value over the serial port. The sign bit will still transmit to the Roboclaw which does use a signed variable.