Git Product home page Git Product logo

self-balancing's Introduction

self-balancing

Self-Balancing Platform Implementation in a Pi - 3

Requires PiGPIO library and Python Bindings. All code is in Python 3.

Instructions: Go to MPU folder and run

$ make
$ ./mpud > /dev/null &

mpud is a simple daemon that uses the readings from the Digital Media Processor (DMP) of the IMU (MPU-6050) and stores the latest values in the SHM location /dev/shm/MPU. Thus, to get the latest readings (x, y, z angles) all that is needed to read the contents of this memory location as a file.

Now, class motor has a simple motor implementation for PWM control of a DC motor. Note that the power parameter is in the range 0-255. Here's an example usage of the motor class:

m1 = motor(enable = 22, cw = 13, ccw = 15)
m1.rotate(255) # Full power forwards
m2.rotate(-255) # Half power backwards

Note: All pin numbers are Physical Pin numbers.

self-balancing's People

Contributors

autolisis avatar prat-degwekar avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

prat-degwekar

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.