Hardware Reference
In-Depth Information
Project box
Admittedly, this is purely an aesthetic component, but you can get a standard plastic
project box, cut a hole for the LCD to mount, then place the Raspberry Pi inside of the
box as well. Holes for the power cable and both USB ports will finish off the box, then
you can attach your finished Cacheberry Pi (in a box) to the dash of your car.
Preparing the Software Image
The Cacheberry Pi project offers a prebuilt image (based on Raspbian). Put a fresh
SD card into your Linux computer, and then download and uncompress a copy of the
Cacheberry Pi image:
$ wget http://cdn.jclement.ca/cacheberrypi/cacheberrypi.img.20120921.bz2
$ tar xf cacheberrypi.img.20120921.bz2
By the time you read this, there might be a newer image than the 2012-09-21 image.
You can confirm on the Cacheberry Pi project website .
After it downloads sucessfully, use the dd command to write the Cacheberry Pi image
onto the SD card. Be extra careful that you know which device is your inserted SD card
( Hack #02 explains how to figure that out). In Fedora, this is almost always /dev/
mmcblk0 , but on other distributions it is a /dev/sd* device. You do not want to use dd to
overwrite your laptop's hard drive with the Cacheberry Pi image!
Once you're sure you know the SD card device name, run the dd command as root,
changing the of= value as needed:
$ sudo dd bs=4M if=cacheberrypi.img.20120921 of=/dev/mmcblk0
When that finishes, run the sync command a few times to ensure the image was prop-
erly written onto the SD card (and not just into the memory buffers):
$ sync;sync;sync
Finally, remove the SD card from your laptop and insert it into your Raspberry Pi.
Wiring the Cacheberry Pi
This hack assumes you are using the components recommended by the Cacheberry
Pi project. If you differ from them, you will need to adjust accordingly.
Plug the USB GPSr directly into a USB port on the Raspberry Pi. The LCD screen has
four pins, labeled SCL, SDA, VCC, and GND. You will need to connect these pins to the
appropriate pins on the Raspberry Pi GPIO using female-to-female jumper wires.
Table 4-2 shows the pin mapping.
 
Search WWH ::




Custom Search