Code Monkey home page Code Monkey logo

cchaser's Introduction

#Cat Chaser

This projects primary purpose is to be a simple app that runs on Raspberry Pi to control a modified remote control car to chase cats.

This projects secondary purpose is to provide an example of how one might integrate a flask app with the GPIO pins of a Raspberry Pi. To control two independent DC motors while streaming 'live' video.

Pin settup and wiring

PIN 4, 17 should be wired to the inputs of a micro-controller attached to DC (Driving Motor)
PIN 24, 25 should be wired to the inputs of a micro-controller attached to DC (Turning Motor)

A good simple motor controller L293D

Environment

It is highly recommended to use a virtualenv

    pip install -r requirements.txt

Enable the Raspberry Pi camera, and stream video from Raspberry Pi, using mjpeg or streaming service of your preference. A good tutorial on how to do this can be found here

Settings

Make Sure that the RPi.GPIO module is accesable if it is not then the stub module will be used, and your motors won't spin

PI_ADDRESS: the external address of the Raspberry Pi used for streaming video
IMG_PORT: the port of the streaming service (ffmpeg)

Running

How to start server:

    python run.py
        -p --port       :default = 8000
        -o --host       :default = localhost
        -t --threads    :default = False (If you want to be able serve multiple requests)

How to add a user:

    python add_user.py

How to run tests:

   nosetests

cchaser's People

Contributors

mmilkin avatar

Watchers

James Cloos avatar  avatar

cchaser's Issues

Add PWM control

Add PWM control, to control the speed of motors
(make this settings driven, for non PWM ready boards)

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.