$ raspi-config
- expand filesystem
- i18n locale & timezone
- advanced options / memory split / 32M (16M doesn't work? confirm)
- advanced options / change hostname
$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo BRANCH=next rpi-update
$ sudo apt-get install htop ipython vim-gtk tree locate python-dev python-pip ctags libi2c-dev
$ sudo pip install psutil
/boot/config.txt
hdmi_safe=1
gpu_mem=32
/etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid="xxx"
scan_ssid=1
key_mgmt=WPA-PSK
psk="xxx"
}
$ adduser xxx
$ visudo
xxx ALL=(ALL) NOPASSWD: ALL
$ ssh-keygen -t dsa
$ cat other_host.pub >> ~/.ssh/authorized_keys2
$ chown og-rwx ~/.ssh/authorized_keys2
$ sudo usermod --lock pi
Build and install https://github.com/sarfata/pi-blaster
Edit /etc/modules
and add the following entries:
i2c-bcm2708
i2c-dev
and reboot. Alternatively, modprobe them in. Either way, confirm the driver has loaded properly:
$ dmesg | grep i2c
[ 18.310467] bcm2708_i2c bcm2708_i2c.0: BSC0 Controller at 0x20205000 (irq 79) (baudrate 100k)
[ 18.332292] bcm2708_i2c bcm2708_i2c.1: BSC1 Controller at 0x20804000 (irq 79) (baudrate 100k)
[ 18.480593] i2c /dev entries driver
Then add your user to the i2c group:
$ sudo adduser pi i2c
Install some packages:
$ sudo apt-get install i2c-tools python-smbus
Check to see if the chip has registered (revision 2 RPi's should use icbus 1, whereas earlier revisions use 0):
$ i2cdetect -y 1
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: 20 -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
Edit /etc/modules
and add the following entry:
spi-bcm2708
and reboot. Alternatively, modprobe them in. Either way, confirm the driver has loaded properly:
$ dmesg | grep spi
[ 480.856103] bcm2708_spi bcm2708_spi.0: master is unqueued, this is deprecated
[ 480.856146] bcm2708_spi bcm2708_spi.0: SPI Controller at 0x20204000 (irq 80)
$ ls -l /dev/spi*