I am using Navio2 with Raspberry Pi 2 Model B and I have some issues with SPI while running the examples in C++ you are providing on your GitHub repository (the AccelGyroMag more precisely).
I used the Raspbian image provided in the DOC section of your website. At first, everything seems to work, I get beautiful data and I am happy. But as soon as a sudo apt-get upgrade is done, and then a reboot of the system, the spi_bcm2708 module disappears from the lsmod output and the examples can’t run anymore (sensor not enabled or sometimes some random values) for both MPU9250 and LSM9DS1.
First, I checked in /etc/modprobe.d/raspi-blacklist.conf for any blacklisted module, but the file is empty. I then tried to manually enable SPI interface in /boot/config.txt by adding dtparam=spi=on and reboot, but this still doesn’t work. I also tried sudo modprobe spi_bcm2708 but I am getting an error ([…] No such device). Can I use the spi_bcm2835 module instead ? If so, how ?
I also tried with Ubuntu 14.04 LTS, but the same issues are encountered. The only way I managed to make everything work was to change nothing on the Raspbian image provided. But I need to install ROS and a upgrade is required to work properly.
By running these procedures you’ve replaced our custom kernel that provides access to RC IO coprocessor and has some additional tuning required for running examples and APM. In next version of the image we will be controlling that the kernel stays intact, but in the current one it is better not to run upgrade and rpi-update.
The problem was I wanted to use the new RPi 3 and with current image it hangs on boot (rainbow) screen. You have to do a rpi-update apt-get update on RPi 2 and then move sd card to RPi 3 to boot your image. Now I am back on RPi 2 with a fresh image and examples work again.
The apt-get upgrade has been working for years now. rpi-update is a custom update mechanism for downstream Raspberry Pi Foundation’s kernels. We don’t use one, so it’s pretty obvious that it won’t work. We can get rid of rpi-update debian package in the next release, if it confuses anyone.