2. Custom Weather Station: Installing Ros2 (DIY BLOG)

in #diy5 years ago

Welcome back, in this post I will talk about installing ros2 on the raspberry Pi3. For the install process we will be following the ros2 install from source guide. Here I will cover my choice of operating system and problems encountered during the process.

serveimage (7).jpeg

Choosing an Operating System

  • Long story short I ended up using Ubuntu 18.04.4 64bit Server Edition for raspberry Pi3. The entire pre-build process here went without incident.

  • I started off by using Raspbian Stretch both because it is a Linux OS designed specifically for the raspberry Pi3 and because it was already installed and running on my system. I ran into problems with python3 as ros2 needs version 3.6 and the package provided in stretch was 3.5.x. Instead of compiling python from scratch I looked for other operating systems

  • I briefly tried Ubuntu Core until I figured out I needed to connect to a remote server to get SSH keys and found it absurd and ditched it.

Build Process

  • There was not enough memory to use the normal build commands. To get ros2 to compile I had to both add swap space and use a colcon command that allowed only building one project at a time.
  • Ubuntu 18.04 server had no swap space by default so I added 4Gb using this guide
  • I removed Rviz packages from the ros2 src folders since ubuntu server does not have a display.
  • To actually build the system use the command MAKEFLAGS="-j1 -l1" colcon build --symlink-install --executor sequential
  • Now just wait 6 - 8hrs because the build takes forever.

So far the tutorial programs are running so it all looks good so far.

Please like and subscribe.

Sort:  

I have created a community for Raspberry Pi posts:
https://beta.steemit.com/created/hive-142614
Please come over and subscribe.