ros-drivers / transport_drivers

A set of ROS2 drivers for transport-layer protocols.
Apache License 2.0
92 stars 56 forks source link

No sending/receiving data on serial_driver_bridge #63

Closed afonsofonbraga closed 2 years ago

afonsofonbraga commented 3 years ago

Hi, I wasn't able to neither send nor receive anything with launching the serial_driver_bridge_node.launch.py I'm trying to execute the launch file using the configurations of my device:

/**:
  ros__parameters:
    device_name: /dev/ttyUSB0
    baud_rate: 115200
    flow_control: none
    parity: none
    stop_bits: "1"

I'm using ros2 galactic in docker. I'm sending the following message to my device :

echo -ne '\x00\x00\x45\x44\x76\x00\x00\x36\xFF\x4F' > /dev/ttyUSB0

and I'm receiving back a message (using hexdump):

 0000000    0000    0000    0076    3600    4eff    0000    0000    0000
0000010    0000    0000    0000    0000    0000    0000    0000    0000
*
0000060    0000    0000    0000    0000    0000    0000    0000    b578

Is there any other special config to make it work? Thanks

autowareisgreat commented 3 years ago

Hi, encounter same problem under ros fox by using

ros2 run serial_driver  serial_driver_bridge_node --ros_params .....

@JWhitleyWork

chenjunnn commented 2 years ago

I think the problem is #72 And I have created a PR to fix it. You can also clone my fork repo and build from source code to use serial_driver for now.

afonsofonbraga commented 2 years ago

Thanks for the reply! I've decided to create one by hand and it has worked. I'll try your fork later.