Hi - do you have any example code for controlling two dynamixels with a single GroupSyncWrite (in c++)? Your existing example code doesn't cover this case.
- can this even be done? Can I write A and B to motor 1 and C and D and E to motor 2?
- If so, when I instantiate the GroupSyncWrite, what is the value of the data_length? The size of the values I am passing to A or the size of the values I am passing to B, or the sum, or the max?
- When I write the data to 'initialize' the GroupSyncWrite, like so:
dxl_comm_result = packetHandler->write2ByteTxRx(portHandler, DXL_ID, ADDR_PRO_INDIRECTADDRESS_FOR_WRITE + 0, ADDR_PRO_GOAL_POSITION + 0, &dxl_error);
how does the work for different motors?
The SyncWrite is intended to write the data to the same address.
If you wish to write different data and data length on various addresses, please use Bulk Write as it will allow you to specify multiple addresses and data for multiple DYNAMIXELs.
Sync Read and Write example is available from DYNAMIXEL SDK > C++ > Example > sync_read_write.cpp