Script to install ros2 Foxy desktop on nano and xavier

I took Dusty’s Dockerfile for foxy converted and added to it to make a script to install ros2 foxy-desktop on the 4G jetson nano. Also works on Xavier. Tested on a clean install of the latest jetpack for both machines. I added urdf_parser_py xacro and joint_state_publisher to the standard desktop image. On the nano make sure you only have one terminal window up to launch the script. Memory is extremely tight. It will fail very close to the end if you have more apps running and you will have to start over. In case it still doesn’t work edit the script look for the colcon build line and change the number of workers from two to one. Takes awhile to build. GitHub - griz1112/build-ros2-foxy-for-jetson: script to build ros2 foxy desktop on jetson nano and jetson AGX Xavier

1 Like

Thanks @danpollock! FYI for other readers - here are links to Dan’s other posts on the topic:

One thing I ran into while doing this. In your Dockerfile.ros.foxy you install yaml-cpp 0.6. If you look into the foxy source at yaml_cpp_vendor its installing the same lib only its 0.7. I built the container without installing 0.6 so don’t think its necessary now. I was thinking about containers vs native and all of a sudden it hit me how many times I’ve had to reflash the Xavier due to garfing up the system while experimenting. Its a high number :) So I’ll be using containers from now on too. I’m still fine tuning my Dockerfile plan on pulling jetson-containers and adding it if that is ok.

Thanks - at some point there was a problem compiling yaml_cpp, and the fix hadn’t made it downstream into ROS yet, so I was manually building it from master. You are hopefully right it isn’t necessary anymore, I will have to try removing those steps from the Dockerfile at some point.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.