I am using teensy with rosserial + ROS Noetic/Ubuntu 20.04 on RASPI4. The teensy code is implemented with ros_lib on platformio (https://platformio.org/lib/show/5526/...). The program compiles fine and uploads successfully on port /dev/ttyACM0
. However, when I do rosrun rossserial_python serial_node.py _port:=/dev/ttyACM0 _baud:=500000
then I get the sync failed error.
[ERROR] [1612795964.166906]: Unable to sync with device; possible link problem or link software version mismatch such as hydro rosserial_python with groovy Arduino.
Things I have already tried:
a) Setting correct baudrate in Serial.begin(500000)
b) Disabling all Serial.begin
and Serial.print
statements
c) Setting baudrate of ros node nh.gethardware()->setbaud(500000)
before nh.init()
d) Increasing the default buffer size to 1024 in ros.h of ros_lib
typedef NodeHandle_<arduinohardware, 10,="" 10,="" 1024,="" 1024=""> NodeHandle;
e) Tried the Arduino board instead of Teensy and the problem still remain.
However, nothing has worked so far.