Monday, March 19, 2012

Quadcopter Quick Update #2

  Here's another quick quadcopter update.

  I'm still waiting for my motors and ESCs to arrive before I begin building up the frame.  They should be here this week, hopefully sooner than later.

  I have connected the Accelerometer/Gyro sensor to my Arduino.  It took a little bit of work, but I now have good data coming from the accelerometer.  The gyro seems to have an introverted personality as I have not been able to get it to communicate.  I believe this is due to it needing a 3.3v I2C buss and the Arduino provides a 5v buss (although the accelerometer runs off of 3.3v, it can accept a 5v buss).  I have ordered a level translator to solve this problem.  Hopefully the 5v buss didn't fry the gyro.

  The coding is coming along well.  I estimate that I am over 3/4 of the way done, and I believe the most difficult tasks are completed.  I have made up a flow diagram to show my control loop.

  Quadcopter Control Loop

  Once I am able to get both sensors working, I will be able to start testing the code and debugging more.

  At this point the compiled code is arround 9k in size, so I am optimistic that when finished I will easily fit in the 30k that's available. I will be looking at my memory usage next to make sure I'm not going to run out of the 2KB SRAM I'm allowed.  Right now I estimate my loop time to be 15ms not including the time to scan the RC inputs.  I may use a second Arduino just for watching the RC inputs as they will only come every 20ms and if I start watching for them at the wrong time, I could waste a huge amount of time doing nothing.  I would then transfer the the inputs from the second Arduino to the first through the I2C buss, which should only take 0.2ms.

  That is all for now.

Phillip

<< Previous Quadrotor Post | Next Quadrotor Post >>