Code Monkey home page Code Monkey logo

footfall's Introduction

#Footfall

###Introduction

Footfall is a camera based people counting system that uses a Raspberry Pi and Pi Cam. There is more information about the system on our blog.

The source code provides a barebones system that will require some customisation.

Disclaimer: The original software was intended for sole use within Watershed, therefore some of the source code has been altered for public use and differs slightly to our systems. For example our system generated event tags showing screening in conjunction with the total number of people in Watershed, to do this we had to pre-populate some timestamps and may cause an issue if the system is ran past a certain time.

###How to Build You will need a few extra packages to build the RPi application. Copy the getrepos.sh file and place it inside the addons folder of your openFrameworks folder. Run the script by navigating to the addons folder and entering the following command into Terminal ./getrepos.sh. This will pull down the require packages.

There are three versions of Footfall.

  • 1 x Armv6l for Raspberry Pi 1 running Wheezy
  • 1 x Armv7l for Raspberry Pi 2 running Jessie
  • 1 x Armv7l for Raspberry Pi 2 running Jessie using Threading (1)

Move the Application directory from the Repo into openFrameworks/apps/myApps/

and run

make clean

Then ensure you have pulled the latest versions of the Addons using the script above.

For armv7l you will need to ensure your pi is up to date and that the camera enabled in raspi-config.

Please run the following.

sudo apt-get update

sudo apt-get upgrade

sudo raspi-update

sudo raspi-config

Enable Camera

and Reboot.

Test the camera is working.

raspistill -o testimage.jpg

##FIX: ofxCvPiCam A couple of people have run into compiler errors with the ofxCVPiCam library on RPi2.

It looks like the MMAL Libraries may have changed slightly so are causing strange errors.

You can resolve these by following [this guide] (orgicus/ofxCvPiCam#3).

cd ~/openFrameworks/addons/ofxCvPiCam/
mv libs old-libs

You will also need to update your Pi

sudo apt-get update

sudo apt-get upgrade

sudo raspi-update

Assuming you have built and compiled oF.

Create a new app your openFrameworks apps/myApps directory then copy the source code across, including the addons.make file.

To build the app.

  • cd projectFolder
  • make

If you are using a mouse and keyboard. You can either launch the app by

  • make run or
  • bin/projectName

However, if you are sshing into the pi. Launch the app like so.

  • DISPLAY=:0 make run & disown or
  • DISPLAY=:0 bin/projectName & disown This puts the app in the background.

###ToDo

  • Fix mask generator (1)
  • Complete variable transfer

###How to Customise Inside the bin/data folder of the RPi App there is a config.xml file. This contains all of the relevant variables you will need to change.

Inside the tag put your upload.php url this will fire the events into the database. The other settings will need tweaking depending on where you place the tracker.

The ThreadedFootfall example uses JSON for its config.

###Thanks Thanks to Kyle McDonald for ofxCv and George Profenza for [ofxCvPiCam] (https://github.com/orgicus/ofxCvPiCam).

footfall's People

Contributors

dhaylock avatar nicolaslt avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.