Hi Dan,
I think everything seems correct.
Though, I've some hints about some of your code.
while ( !dxl.readable() ); // wait until you can read, may want to add timeout here
readable is set to 1 when a data is in the RX buffer.
The problem is that it'll come to 0 the first time you read (with getc())
So if you've multiples char in your buffer, you won't be able to get them all off the buffer.
As for the solution, I've searched all night for a project and I havn't found one yet.
else if(time < 0){ //why would time ever be negative? from linux SDK
As for this question, time can be negative when the time counter goes off the limit of the integer.
Hope it helps,
Romain
Hello all,
I started this over in the Questions section (http://mbed.org/questions/2501/Help-port-Dynamixel-library-for-the-comm/) but thought it would maybe fit better over here.
Robotis provides a dynamixel SDK template that you can use to port it to other platforms. I'd like to port this to mbed.org so the community will have a robost dynamixel SDK.
http://support.robotis.com/en/software/dynamixel_sdk/sourcestructure.htm
it's a single file with function templates that one must fill in:
Here's what I have so far:
I'm getting there. Please feel free to critique and help answer any of the questions i have in the comments. Thanks a lot!