ros-drivers / rosserial

A ROS client library for small, embedded devices, such as Arduino. See: http://wiki.ros.org/rosserial
519 stars 524 forks source link

Messages in geometry_msgs not handling negative numbers #86

Open avardy opened 10 years ago

avardy commented 10 years ago

I tested geometry_msgs/Twist and geometry_msgs/Vector3 and there seems to be some error in the serialization which turns all negative numbers (I tested -100, -10) into -0.

As a hack to control my robot (iRobot Create with custom Arduino-based control board) I am sending Point32 messages to encode forward speed and rotation.

mikeferguson commented 10 years ago

@PaulBouchier if you end up looking into this, it is likely a regression in the Float64 support from recent updates. The Float64 handler is quite custom on the Arduino since there is no 64-bit types so we end up converting to 32-bit ones. We used this script as a test: https://github.com/ros-drivers/rosserial/blob/hydro-devel/rosserial_arduino/src/ros_lib/tests/float64_test/float64_test.pde

PaulBouchier commented 10 years ago

Thanks for the pointer Michael. I'm trying to get the arduino Due won't compile bug fixed, but I'll look at this after.