Society of Robots - Robot Forum

Electronics => Electronics => Topic started by: Bob Fonger on January 19, 2011, 04:24:56 PM

Title: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: Bob Fonger on January 19, 2011, 04:24:56 PM
Hello
I have a functioning Radio Control system that runs multiple Speed Controllers from the Controllers sticks on the radio.  And that is great and fine.  Next there are 4 gyros in the system that sense YAW Rotation and make the Speed controllers react to correct and YAW Rotation sensed from the Gyros.

That handles any YAW and dampens or arrests the YAW Rotation.

Now I need to arrest any motion straight ahead or straight backward, or straight slide to the right or left.  Gyros can not do that since they sense rotation only.

So I have purchased 2 AXON II  Computers and have ordered an 3 axis accelerometer.

How do you input the accelerometer out puts into the working stick controlled radio control system.

I need to drive the unit as I can now by the Radio TX, but just like the Gyro's I need the accelerometer to be present as well and assist when activated.
I am completely new to any of this except for basic radio Control systems in their basic intended form.
Title: Re: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: klims on January 19, 2011, 10:52:45 PM
Do you plan to read the accelerometer values from the Axon? Or will the Axon be used for something else?

As far as I know radio control systems take an input signal in the form on PWM. What type of signal does the accelerometer output?
My guess is that you will need the Axon to transform the accelerometer signal from whatever it is to PWM for the radio system.
Title: Re: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: Bob Fonger on January 21, 2011, 07:20:22 AM
Hello Thank you for the responce.
Yes that is what I am thinking. Accelerometer into AxonII  then AonII outputs XYZ signals, but then.....
How do you combine these outputs into the existing Radio Control system that is up and running.
I still need to control those speed controllers from my Radio sticks by hand, and then throw a switch to activate the AxonII and ?????? somehow combine it's signals for the speed controllers along with the Radio Controll Receiver Signals going to the same Speed Controllers.  That is my first fundimental question.

Do you use a Y-Harnes to combine the two signals to the same SpeedController?

Thank you for your help,
Regards
Bob Fonger
Noramco Wire and Cable
Bay # 4, 3529 - 12th Street N.E.
Calgary, Alberta  T2E 6P4
Tel: (403) 291-2955
Fax:(403) 291-2995
[email protected]
Title: Re: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: Bob Fonger on January 21, 2011, 01:04:28 PM
http://s898.photobucket.com/albums/ac187/Bob_Fonger/?albumview=slideshow (http://s898.photobucket.com/albums/ac187/Bob_Fonger/?albumview=slideshow)
Title: Re: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: waltr on January 21, 2011, 01:31:00 PM
Quote
Huh  somehow combine it's signals for the speed controllers along with the Radio Controll Receiver Signals going to the same Speed Controllers.  That is my first fundimental question.

Do you use a Y-Harnes to combine the two signals to the same SpeedController?

No, a 'Y' harness is used to control two servos from one output on the receiver.

If you use the Axon to read the accelerometers you also need to run the signal from the receiver into the Axon.
The Axon measures the input pulse width,
adjusts the pulse width with the information from the accelerometers,
then outputs the new pulse width to the servo.

You have read on how a servo's position is controlled by a varying width pulse, right?
Title: Re: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: Bob Fonger on February 15, 2011, 08:23:01 AM
Hello
Thank you for that last post.  That is starting to help me see it a bit.
So from Radio receiver into Axon and from Accelerometer into axon.  and then from Axon to my bank of speed controllers which are considered the same as servos.
How much code would be required to mix the input from the accelerometer with the inputs from the Radio receiver to get a combined output to the speed controller.
Is this something a Newbie can accomplish, or should I try to hire someone for the code?
Thank you
Regards
Bob Fonger
Noramco Wire and Cable
Bay # 4, 3529 - 12th Street N.E.
Calgary, Alberta  T2E 6P4
Tel: (403) 291-2955
Fax:(403) 291-2995
[email protected]
Title: Re: Radio Control system with Speed Controllers to react to Accelerometer info
Post by: waltr on February 15, 2011, 08:59:44 AM
Quote
Is this something a Newbie can accomplish
It depends on how much other experience you have and how fast you learn.
Also it can be a fairly simple linear translation or get quite complex.

Break the code tasks into steps and solve each step before combining them.

First step is to write code that outputs the proper pulses to the 'servos'. Connect a pot to an ADC input the control the 'servo' position. Do use an O'scope before connecting a real servo or your speed controllers to ensure the output pulse in correct.

Next step is code to measure the pulse width of the RC Receiver outputs. Then send the measure pulse width out.

Next, use the pot on the ADC to modify the measured input pulse width.

Separately, read the accelerometer and learn what the values represent and work on how the 'servo' output should change.

Lastly, combine all code.

An O'scope will be almost essential for checking that the output pulses are correct. Another very useful debugging aid is to have Serial output from the Axon. This way you can output reading, measured values and intermittent calculations to your PC for checking. 

Measuring the RC receiver pulse and outputting a new pulse has been done so there are some write-ups and code examples on the web. If the code examples are in C then read them even if it is written for a different processor like a PIC.

Good luck and have fun.