LaunchPad Flight Controller
As some of you might know I have been studying in San Francisco the last semester at San Francisco State University. For that reason I have not done as much as development as I usually do, due to all my equipment being back in Denmark and also because I prioritised being social and not just sit behind my desk coding all night π
Anyway I did not fully stop working. I actually started working on my own flight controller written from scratch in one of by courses. Below is the result so far:
As you can see it hovers just fine and I am able to control it using my 9XR. The receiver used is a OrangeRX R615X outputting a CPPM (Coherent Pulse Position Modulation) signal where each pulse represent a channel sent from the transmitter. The width of each pulse is measured using Timer Input Capture interrupt in hardware. More information about this and the fundamentals can be found in the brief report I wrote for the course: https://github.com/Lauszus/LaunchPadFlightController/raw/752b9e841471f10ffa8bab8c53d25bf1fa7cec26/docs/Report.pdf.
The code is written in C for the Tiva C Series TM4C123GXL LaunchPad. It features the TM4C123GH6PM 32-bit ARM Cortex-M4 microcontroller running at 80 MHz with a FPU which is a big upgrade if you are used to 8-bit microcontrollers like the ATmega328P which is found on the Arduino Uno.
The full specs for my current setup is as follows:
- Microcontroller: Tiva C Series TM4C123G LaunchPad
- IMU: MPU-6500
- Motors: Sunnysky X2204 2300kv
- ESC’s: Blue Series 12A RapidESC (SimonK v2013-05-15)
- Props: Gemfan 5×3
- Frame: 250 FPV Quadcopter (Bought on eBay)
- LiPo: Turnigy nano-tech 1500 mAh
- RX: OrangeRX R615X
- TX: Turnigy 9XR
- TX module: OrangeRX 2.4GHz transmitter module
The full source code is available under the GPLv2 license at my Github: https://github.com/Lauszus/LaunchPadFlightController. The code is a bit limited, as it currently only gyro mode (acro mode) is supported, but I intend to implement accelerometer (self-level mode) in the future, as I will properly continue working on this project for my Bachelor thesis this semester – so expect some more updates in a future blog post.
Furthermore it only works with my specific hardware and only works on a quadcopter in X-configuration. If you want to use other hardware or mixes I recommend checking out MultiWii for 8-bit microcontrollers or Cleanflight for 32-bit microcontrollers. Both of them supports a variety of microcontrollers and sensors.
I have already gone through your report several times and your git code and the instruction given over there.
My doubt is how you have made connection between 2.4GHz Receiver and Tiva Launchpad ?
I think you have used only one pin for getting the value from the receiver. But I think we need four Tiva microcontroller pins (each one for aileron, elevator ,rudder and throttle).
So, please clear my doubt regarding connection between Rx (2.4GHz) and Tiva Launchpad.
@Shuhbam Garg
The receiver I am using: http://hobbyking.com/hobbyking/store/__46632__OrangeRx_R615X_DSM2_DSMX_Compatible_6Ch_2_4GHz_Receiver_w_CPPM.html support CPPM. This allows me to read all channels using only one input.
Hi Lauszus,
This is awesome. Can you post this in our TivaC forums? I’m sure many of our members will be interested in it.
http://forum.43oh.com/forum/54-projects/
Thanks!
@bluehash
Done: http://forum.43oh.com/topic/8242-launchpad-flight-controller/ π
How to connected TM4C123G LaunchPad, ESC, Sensor ?
plz help me.
@elcielo
Please see the following section in the readme: https://github.com/Lauszus/LaunchPadFlightController#pinout.
@elcielo
I will add more information later, when I have finished my bachelor π
@elcielo
I just published a new blog post with more information: http://blog.tkjelectronics.dk/2015/08/bachelors-thesis-launchpad-flight-controller.