Giter Site home page Giter Site logo

self-balancing-bicycle's Introduction

Self-balancing Bicycle

######Dependencies: In order to run the project code, you need to install LPCXpresso IDE. You also need to import the CMSISv1p30_LPC17xx, freeRTOS_Library, and ControlAlgorithmfreeRTOS projects provided in the ZIP file. This source code will only run on a FreeRTOS-capable ARM microprocessor like the one provided on the LPC1769 microcontroller. The freeRTOS instruction manual comes with links for downloading the necessary project folders for freeRTOS. Links to download the necessary software as well as reference material are provided below.

######Running the Project: To run the code, it must be uploaded to the LPC 1769 through the LPCXpresso IDE. The code can either be run off of a computer as a debug instance or flashed onto the board.

######Manual Control (Bluetooth): The phone application is called Bluetooth Serial Controller and can be downloaded for free on Google Play for Android devices. A config file for the controller is provided below. To enable the bicycle motor, press GO. To increase or decrease speed tap or hold down SPD UP or SPD DWN, respectively. To stop the motor, press STOP. This also disables control of the motor, so GO must be pressed again to re-enable control. Press LEFT and RIGHT to turn the steering motor left or right.

######Useful Links:

http://www.nxp.com/products/software-and-tools/software-development-tools/software-tools/lpc-microcontroller-utilities/lpcxpresso-ide-v8.2.2:LPCXPRESSO

http://www.nxp.com/wcm_documents/techzones/microcontrollers-techzone/LPCLibrary-Books/Books-pdf/using.freertos.lpc17xx.summary.pdf

https://www.lpcware.com/system/files/LPCXpresso_IDE_User_Guide.pdf

http://www.FreeRTOS.org/Documentation/code

######Repository(also includes controller config):

https://github.com/Nicholas-Foulk/Self-Balancing-Bicycle.git

######PWM and GPIO circuit for motor control box:

The pulse width modulation and general purpose input/output circuit goes with our proxy motor control box circuit, which is used for switching between manual and automatic control of the bicycle. The program is run on LPC Expresso IDE and requires a few pins on the LPC 1769 board. The c file, "test_pwm.c" was used for this portion.

######Accelerometer:

Our project has an accelerometer, LSM303D, in our project for collecting data off of the front the bicycle and it is setup on the LPC 1769 board using the SPI connections. The c file used for programming our connections is "LSM303D_SPI.c" and is in this repository.

######Control Algorithm:

Our control algorithm uses data gathered from the accelerometer and controls the stepper motor for our seesaw balancing system. The control algorithm was first implemented on LPC_1769 with no problems under the files CMSIS_CORE_17xx and ControlAlgorithm folders in this project. The control was later implemented in freeRTOS to introduce a round robin task scheme for including more processes into our project. FreeRTOS allows us to use our Bluetooth/UART program and control algorithm at the same time. Our freeRTOS implementation is requires the folders CMSISv1p30_LPC17xx, FreeRTOS_Library, and ControlAlgorithmfreeRTOS. The IDE used for the control algorithm is LPC Xpresso IDE.

self-balancing-bicycle's People

Contributors

nicholas-foulk avatar dustinphou avatar balloonn355 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.