go_away

Author Topic: Axon control on top of a RC car  (Read 1036 times)

0 Members and 1 Guest are viewing this topic.

Offline einar.gilbergTopic starter

  • Beginner
  • *
  • Posts: 2
  • Helpful? 0
Axon control on top of a RC car
« on: November 30, 2010, 01:15:00 PM »
I am about to set up my RC car with an additional control trough a Axon II. The set up has a "Y" shape, where the servos are at the root of the "Y". The Axon II comes in on one branch, and the radio control on the other. What will happen? Will current and signals reach the servo, or will current and signals from the radio control just enter the Axon II and destroy it? (and vise versa, the Axon takes out the RC)

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: Axon control on top of a RC car
« Reply #1 on: November 30, 2010, 02:26:25 PM »
Quote
What will happen?
The radio and Axon's outputs will both TRY to drive the wire. Just will cause bad things to happen and the servo won't know what to do. This could damage the output of either the radio or the Axon.
This will not work!

You can have either the radio or the Axon drive the servo signal but not both at the same time.

If you want the Axon to take over control there are a couple of ways to do this.
1- Run the radio's outputs into Axon inputs and have the code output these to the servo. Then when the Axon takes over it stops outputting from the radio and outputs its own pulse train.
2- Use external logic, AND gates, to select either the radio or Axon outputs to go to the servo.

Offline Soeren

  • Supreme Robot
  • *****
  • Posts: 4,672
  • Helpful? 227
  • Mind Reading: 0.0
Re: Axon control on top of a RC car
« Reply #2 on: December 01, 2010, 06:18:06 PM »
Hi,

A third way:
Detect whether the transmitter is active or not (eg. by a missing pulse detector) and let the Axon take over the control when the transmitter is shut down or outside range.

Then, when you want the Axon to be in charge, you just turn off the transmitter.
(Might be helpful to to add an LED or some other means to let you see which is controlling the vehicle).
Regards,
S°ren

A rather fast and fairly heavy robot with quite large wheels needs what? A lot of power?
Please remember...
Engineering is based on numbers - not adjectives

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,702
  • Helpful? 173
    • Society of Robots
Re: Axon control on top of a RC car
« Reply #3 on: December 01, 2010, 09:56:03 PM »
The best way to do this is to plug the RC receiver output directly into the Axon.

Using WebbotLib
-set that pin as a digital input
-use function pin_pulseIn() to measure that input
-set another pin as a servo

And then your code needs to do something like:

if(measured_pulse > 0)
   //then set measure_pulse as the servo signal
   measurde_pulse  = interpolate(measured_pulse , 1000, 2000, DRIVE_SPEED_MIN,DRIVE_SPEED_MAX);
   set servo speed to measured_pulse
else
  //use Axon II control of servo

Offline Soeren

  • Supreme Robot
  • *****
  • Posts: 4,672
  • Helpful? 227
  • Mind Reading: 0.0
Re: Axon control on top of a RC car
« Reply #4 on: December 01, 2010, 11:51:12 PM »
Hi,

And then your code needs to do something like:

if(measured_pulse > 0)
The number would need to be larger, to eliminate spurii.
Something like 200Ás to 600Ás - as large as possible without being too close to the accepted pulse range.
Regards,
S°ren

A rather fast and fairly heavy robot with quite large wheels needs what? A lot of power?
Please remember...
Engineering is based on numbers - not adjectives

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,702
  • Helpful? 173
    • Society of Robots
Re: Axon control on top of a RC car
« Reply #5 on: December 02, 2010, 07:04:00 AM »
And then your code needs to do something like:

if(measured_pulse > 0)
The number would need to be larger, to eliminate spurii.
Something like 200Ás to 600Ás - as large as possible without being too close to the accepted pulse range.
oops . . . agreed, I forgot about RC noise! :-X

 


Get Your Ad Here

data_list