BYOAQ-BAT III: OS installation

If you haven’t already, please read the previous BYOAQ-BAT articles first – just search for the BYOAQ-BAT tag.


Next step is getting the Raspbian OS installed and talking to the sensors.

You’ll need a USB hub for plugging in a(n)

  • keyboard
  • mouse
  • ethernet dongle (WiFi is possible, but I use ethernet as there is no need to configure SSID)
  • Raspberry Pi

Don’t forget an HDMI TV / monitor

Get the latest image on a micro SD card – I’m using the 2015-01-31 Raspian.

Boot to raspi-config

  • Expand filesystem
  • Overscan Disabled
  • Memory Split 16MB
  • Overclock Medium 900MHz
  • Set hostname
  • I2C Enabled

Reboot

Ping google.co.uk to check internet access

Update latest image to the very latest bits

sudo apt-get update
sudo apt-get dist-upgrade

Install the following packages

  • python-smbus
  • python-dev
  • i2c-tools
  • ftpd
  • ftp

Remove the following package – we will add a high performance one later

sudo apt-get remove rpi-gpio

Scrub that for the moment, the standard package may well be up to speed now. I’ll come back to that later if necessary.

Ensure the i2c kernel drivers are loaded – add the following to /etc/modules:

i2c-bcm2708
i2c-dev

Reboot

Check what can be seen on the i2c bus: sudo i2cdetect -y 1

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- 68 -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- 77
  • 0x68 is the MPU9250 – accelerometer, gyroscope and magnetometer
  • 0x77 is the MS5611 – barometer

Next time, software installation. There will be a delay for the next article as my writing of the artcles has caught up with what I’ve done so far.

Leave a Reply

Your email address will not be published. Required fields are marked *