iRobotEducation / create3_docs

Documentation for the iRobot® Create®3 Educational Robot
BSD 3-Clause "New" or "Revised" License
49 stars 16 forks source link

Full Topic List not appearing on RPi 4 #76

Closed ghost closed 2 years ago

ghost commented 2 years ago

Hello!

I'm very excited to begin using the Create3 for some interesting SLAM projects. I've spent the better part of two days trying to get the basic ros2 setup running on a RPi 4 that I have connected via usb to my Create 3.

I follow the instructions on your website: https://iroboteducation.github.io/create3_docs/setup/pi4/

However, after completing them and checking for the available topics, All I see is

ubuntu@irobot:~$ ros2 topic list
/parameter_events
/rosout

Please help me figure out what's wrong with my installation.

System Info: Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-1062-raspi aarch64) RMW_IMPLEMENTATION=rmw_cyclonedds_cpp

Note: I also tried the RWM Fast-DDS since I didn't understand in the instructions where to find my robot's "Application Configuration page"

Bottom of ~/.bashrc:

export _colcon_cd_root=/opt/ros/galactic/
source /usr/share/colcon_argcomplete/hook/colcon-argcomplete.bash
source /opt/ros/galactic/setup.bash
export RMW_IMPLEMENTATION=rmw_cyclonedds_cpp
export CYCLONEDDS_URI=/home/ubuntu/ros_install/profile.xml
export FASTRTPS_DEFAULT_PROFILES_FILE=/home/ubuntu/ros_install/profile_fast.xml

RMW profile (located in ~/ros_install/):

<CycloneDDS>
   <Domain>
     <General>
        <DontRoute>true</DontRoute>
    </General>
   </Domain>
</CycloneDDS>

This profile was found here under Multiple network Interfaces due to being on my company's WiFi

shamlian commented 2 years ago

Hi there,

I'm a little confused. It looks like that RMW profile you're using is one you would want on a laptop; on your Pi, if you're connected both to the robot with usb0 and to your local network with wlan0, you'll want to use the multiple network interfaces XML config on the Pi, which is

<CycloneDDS>
   <Domain>
     <General>
        <NetworkInterfaceAddress>usb0,wlan0</NetworkInterfaceAddress>
    </General>
   </Domain>
</CycloneDDS>

Using this, you should be able to see the robot with a ros2 topic list. The robot's RMW can be forced to Cyclone by connecting to it with a browser to {robot ip}/ros-config, or if you know you're connected with the Pi, you can just curl -X POST -d "ros_domain_id=0&ros_namespace=&rmw_implementation=rmw_cyclonedds_cpp" "http://192.168.186.2/ros-config-save-main" from the prompt.

You will need to restart both the robot and also ROS 2 on your Pi (ros2 daemon stop && ros2 daemon start) for configuration changes to take effect.