You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think you meant to say 64 (without the 0x) but that would also be wrong, because it would not account for situations with multiple errors at once.
The correct check should be for bitmask 01111111 = 127 or 0x7F in Hexadecimal.
The line should become:
rxpacket[PKT_ERROR] > 127 (NOTE: just ">" not ">=")
This is causing the SDK to give error of "No reply packet" even if the servo replies but has an error condition of Voltage Error, Angle Limit Error, Checksum or Overload Error. In all cases, the SDK will discard the reply and return a code indicating the servo did not send a valid reply.
Pedro Ramilo
[ Seed Robotics ]
The text was updated successfully, but these errors were encountered:
I must add that this check (validity of the error mask) is somewhat redundant. Other bus devices using the Dynamixel protocol (by partner manufactures or custom designed by the users) could make use of the full byte.
Furthermore discarding a packet that is correct in length and checksum just because it fails the error mask verification seems a little aggressive.
Failing the checksum check or length check would seem much more severe and worth discarding the packet.
pramilo
changed the title
Bug in protocol1_packet_handler.cpp, line 222
Bug in protocol1_packet_handler.cpp, line 222 checking the returned Error Mask
Sep 21, 2017
Please fill out the questionaire to give you the best support service.
Which DYNAMIXEL is it?
[ ALL ] ( ex: MX-64AT , XM430-350R , PRO H54-100-S500-R , ...)
Which CONTROLLER is it?
[ USB2Dynamixel ] ( ex: OpenCM , OpenCR , Arduino Uno , PC via USB2Dynamixel , ... )
Which VERSION of DynamixelSDK is it?
([NOTE] DynamixelSDK Q&A is not available anymore if it is older than ver. 3.0.0, but feedback us)
[ 3.5.2 ] ( ex: 3.4.2 , dxl_sdk_win32_v2_02.zip , ... )
Any PICTURES or VIDEOS?
![ Nono ]( Link the PICTURES or VIDEOS here, if necessary )
Any SOURCE SAMPLES?
[ I attach
protocol1_packet_handler.zip
protocol1_packet_handler.zip
a commented file ]( Link the SOURCE SAMPLES here, if necessary )
Summary:
In line 222 of protocol1_packet_handler.cpp, you check if the error mask returned is valid.
However your check has a bug. Your code is:
rxpacket[PKT_ERROR] >= 0x64
The problem is that 0x64 = 01100100, does not cover all valid masks. (see http://support.robotis.com/en/product/actuator/dynamixel/communication/dxl_packet.htm )
I think you meant to say 64 (without the 0x) but that would also be wrong, because it would not account for situations with multiple errors at once.
The correct check should be for bitmask 01111111 = 127 or 0x7F in Hexadecimal.
The line should become:
rxpacket[PKT_ERROR] > 127 (NOTE: just ">" not ">=")
This is causing the SDK to give error of "No reply packet" even if the servo replies but has an error condition of Voltage Error, Angle Limit Error, Checksum or Overload Error. In all cases, the SDK will discard the reply and return a code indicating the servo did not send a valid reply.
Pedro Ramilo
[ Seed Robotics ]
The text was updated successfully, but these errors were encountered: