Skip to content

Raspberry Pi Installation

firepick1 (pixel) edited this page Oct 7, 2014 · 45 revisions

Follow these instructions to install FireREST on your Raspberry Pi and turn it into a smart camera node. For best results, start with a blank SD card and dedicate that card to FireREST only. FireREST installation on an existing Raspberry Pi SD card with other software is not supported.

Prerequisites

We recommend that you use two SD cards, one for a standard Raspberry Pi image, and one for FireREST. This will help you diagnose any hardware problems you may have. It will also give you experience installing a Raspberry Pi image:

  1. Raspberry Pi
  2. Raspberry Pi Camera
  3. Two SD cards (30MB/s or faster for best performance)
  4. On the first SD card, install the standard Raspberry Pi image.
  5. Test the camera

At this point, you have working hardware and are ready to install FireREST on the second SD card, choosing one of the options below.

OPTION 1. FireREST Quick Installation (~10m)

For a quick installation, download, unzip and install a pre-built FireREST Raspberry Pi image on an SD card in place of the standard Raspberry Pi image:

Your newly installed SD image is named firepick instead of raspberrypi. Login and complete your Raspberry Pi installation:

  1. ssh pi@firepick password is raspberry but you should change it
  2. cd FireREST; node server/firerest.js
  3. Open a browser to view http://firepick:8080.

Once you've verified that FireREST works, go ahead and customize your Raspberry Pi:

  1. sudo raspi-config
  2. Expand Filesystem Yes
  3. Change User Password change your password or allow the world to hack your home!
  4. Advanced Options|Hostname firepick
  5. Internationalisation Options | Change Locale choose a UTF-8 locale such as en_US.UTF-8
  6. Internationalisation Options | Change Timezone where you live
  7. Enable Camera Yes
  8. Overclock Turbo If your RPi freezes intermittently, choose a lower speed or add a heat sink
  9. Advanced Options|Memory Split 16 Provide more RAM for compiler, etc.
  10. Would you like to reboot now? Yes

Once you have installed a FireREST image, you can update it periodically:

OPTION 2. FireREST Custom Installation (~120m)

For a custom installation equivalent to OPTION 1, start with a standard Raspberry Pi:

  1. Pre-configure your Raspberry Pi

Now install and build FireREST components (e.g., OpenCV, FireSight, FireFUSE, FirePiCam, jannson, etc.). This process will take some time, but gives you more control over how things fit together.

From your main computer:

  1. ssh pi@firepick
  2. git clone git://github.com/firepick1/FireREST; cd FireREST
  3. ./tinypi
  4. . ./build
  5. fire/web -s
  6. Open a browser to view http://firepick:8080

For best performance, be sure to defragment the Linux partition after you customize your FireREST installation. This will squeeze all the unchanging files together for efficient SD access. For example, you can use gparted to shrink the Linux partition to its minimum size. After you minimize the partition, go ahead and Expand the Filesystem (see above) to use the entire SD card for normal write operations. Defragmenting your SD card can increase FireREST performance by 3x or more.

Once you have installed a FireREST image, you can upgrade it periodically:

Read Me

Your FireREST installation behaves differently than a standard Raspberry Pi:

  • FireREST requires the camera, which cannot be shared. Both raspistill and raspivid will fail with ENOSPC error as long as FireFUSE is mounted.

Troubleshooting

I can't ssh to firepick

Your local network should detect your Raspberry Pi as firepick when it boots up. Things to try:

  1. Verify that SD card is fully inserted
  2. Attach monitor and keyboard to your Raspberry Pi and use ifconfig to determine the IP address of your Raspberry Pi,
  3. Reboot your router and it may wake up and see your Raspberry Pi
  4. Use a wired connection (wifi tends to be sluggish)

How do I turn off firerest web server?

  1. fire/web -k

See Also