I did some test flights this morning, but unfortunately I had to
remove the XBee from the plane first. The servos were making a
ticking sound at 4 Hz (one tick per line of telemetry) which seemed
weird, but didn't actually move the servos perceptibly, so seemed
hopefully harmless. But when I tested switching on stabilized/auto
mode, the servos were glitching pretty hard (very noticeably) at 4 Hz,
and it seemed like a bad idea to fly it like that.
I'm wondering if the servo cables or receiver are picking up some hint
of the transmission. But it seems that since the glitching is mainly
happening when in stabilized/auto mode, it must be affecting the
gyro/accelerometer readings.
My top ideas right now are that either the transmissions are
interfering with the sensor readings, or that the XBee pulls extra
power when it transmits, and the extra power draw messes with the
readings.
Maybe to try to see if it's the power or the transmission, I'll try
powering the xbee board from an external 5V power source and see if
the problem still happens.
Has anyone else seen and solved similar problems?
Thanks!
Ben
Using another supply would definitely help if your setup do not need
a common ground between them.
Theoretically 900 and 2.4 are usable frequencies together. You can
try binding both once again, it may catch a different channel perhaps.
A ferrite core coil over servo wires also would help.
Ultimate solution is to have opto isolator on all servos. I think
Jordi has one.
http://store.diydrones.com/ProductDetails.asp?ProductCode=BR%2D0003%2D11
Regards
SID
Adam,
It will not eliminate RF interference but basically OPTO is for servo signal isolation. Definitely if you use them the servos will not jitter. To be installed between dev board and servos.
Regards
SID
Greetings,
I have a GPS tracker/telemetry gizmo that uses a 900 MHz XBee XSC (100mw) unit, and came very close to putting it in the plane last weekend. Probably a good thing I didn’t :-)
I powered up the plane, let it finish it’s initialization, GPS, etc, and verified that it was working OK in manual and stabilized mode. Next, I turned on the XBee close to the UDB. All was still fine in manual, but when I turned on the stabilization mode, I found the elevator down, and ailerons right. When I turned off the XBee, the ailerons slowly went left, and the elevator up, then over the course of a minute or two, finally came back came back to neutral. This was strange, but repeatable. I also tried a 500mw 900MHz video transmitter, with the same result.
If you leave the UDB in stabilization mode, then turn on the XBee, I hear a “ticking” sound from the servos, but it’s the sound of them slowly moving as they drift. They will go almost full throw one way, then maybe back the other part of the way, but all very slowly. During this time, the stabilization controls still deflect if you move the aircraft.
In my tests, there’s no electrical connection between the XBee and aircraft, so it’s certainly going to be radiated RF getting into something, and my guess is something on the UDB. I think the manual mode would have problems if it were getting into the receiver, and I’ve used these Futaba FASST receivers with the 500 mw video TX lots of times, with no issues like this. Really cheap servos will jitter, but I’ve never seen on drift.
In case there’s a betting pool going, my guess is going to be that the RF is somehow making the ACC offset change. That’s just a SWAG, and I fear I won’t be able to resist looking at this more on the bench.
Cheers,
Rusty (I hate RF)
Bill,
I set up the spare board on the workbench, just like the one in the plane, and can easily make the problem occur. I used the XBee with a small rubber ducky antenna, and probed around as best I could. While this is far from conclusive, my current thought is that the gyros are likely the guilty party. Moving the antenna near the gyros one at a time, you can make one servo at a time act up. No amount of probing around at the receiver outputs caused any noticeable problem. Of course you can’t scope anything, without the risk of ruining the results by turning the probe into yet another antenna, so this may have to be solved via software troubleshooting.
I agree that eliminating the receiver inputs in software is a great test. I assume it’s also possible to fake the gyro or acc values in software, so you can disable those inputs to the PIC? If so, that’s going to be another good test. I’m software challenged, but if someone can modify the software, I’ll be happy to test it.
Rusty
From: uavde...@googlegroups.com [mailto:uavde...@googlegroups.com] On Behalf Of prem...@nycap.rr.com
Sent: Friday, October 30, 2009 3:16 PM
To: uavde...@googlegroups.com
Come to think of it, you could also test by turning off the
transmitter after gps lock, if you're set up to recognize a loss of
signal.
I wish I could test this more right now, but work exploded, and will
probably keep me from playing much for a couple weeks...
Ben
Guys,
Just to give you some inputs. I do not know what UDB is but thought this will help. I have used 2.4 Ghz video Tx (500 mW) and 434/444 MHz UHF RC link with Red board successfully in all modes. I have not tried 900 MHz video TX but I do have; I will test the same and will let you know the results. Hope it helps.
Regards
SID
Greetings all. I’m going to try to mix all the replies in one message, so I don’t get flagged by the spam filters :-)
I'm unfortunately way out of my league with RF, but I'm curious if the same behavior happens with the XBee 'wire' antennas?
Adam, I’m no RF expert, though I’m learning more all the time, mostly out of desperation. RF is just evil. As for the antenna type, I can’t imagine it will matter. I get my XBees in the U.FL connector variety, so I can use most any antenna. I think any antenna that transmits the power relatively efficiently, will cause the same problem.
As for the programming offer, stand by for now, and I’ll try the NORADIO option in Ben’s software to eliminate the receiver, and probably more importantly, the wiring from the receiver to the UDB.
---------------------------------
Note that this is untested, and wasn't really meant to work while actually connected to a receiver. :) But it might work!
Come to think of it, you could also test by turning off the transmitter after gps lock, if you're set up to recognize a loss of signal.
Ben, I saw this option yesterday, but of course didn’t try it. There are a few other settings in the new options.h file that I wasn’t sure how to set, but we’ll save that for another discussion. As for the NORADIO setting, I’ll try it tomorrow when I get a chance, and see if it seems to work. I presume it’s fixed in the waypoint mode, since there’s no radio connected?
Turning off the TX won’t work for me, because the Futaba FASST will hold the last signal, or give the failsafe value, so it never appears to lose signal. I did try unplugging channels 1 and 2 from the UDB after it was up and running. It seems like that still had the same problem, but I’d have to try it again to make sure.
------------------------------
Just to give you some inputs. I do not know what UDB is but thought this will help. I have used 2.4 Ghz video Tx (500 mW) and 434/444 MHz UHF RC link with Red board successfully in all modes. I have not tried 900 MHz video TX but I do have; I will test the same and will let you know the results. Hope it helps.
Sid, UDB is UavDevBoard. I’ll be interested to hear what your 900 MHz video does, but it almost has to cause the same problem.
------------------------------
(Speaking of which, I am presently working with SparkFun on the next design. Should we test it for interference resistance?)
Bill, Sounds like maybe we should, though I’m not sure how the best way to test it would be. It’s still sort of hard to imagine that this could be causing a problem with gyros, or ACC, since I’ve never seen that before. I fly mostly quadrocopters, and often have a 500mw 900MHz video transmitter within inches of the flight control board. Of all the problems I’ve had (GPS interference mostly), I’ve never seen any hint of a problem with the RF getting into the sensors on the board, so I’m not sure why it would be doing it here.
If the problem is that the Xbee is interfering with the UDB power supply by dragging the voltage below 3.3 volts (that would certainly cause a problem), then the solution would be to provide a separate power supply for the Xbee.
For my particular test, the XBee has its own power supply, as did the 900 MHz video TX. The XBee’s do pull about 180ma average when transmitting steadily, and they really strain that SF “regulated” board’s 150ma regulator, so it’s something to consider when deciding how to power it.
Finally, distance is your friend, and with airplanes, there’s at least some room to relocate items for some separation. If I get desperate, there’s always the copper tape :-)
Rusty
Greetings,
Very quick update- I loaded Ben’s code, with the NORADIO set, and fired it up with no receiver connections. It seems to function, and after a few minutes, the red LED starts flashing, the aileron assumes the position, and both aileron and elevator servos respond to pitch and roll of the board.
Next, I tried the XBee, and the video TX, and I’d have to say that the problem is unchanged, pretty much as we expected. I’m still guessing it’s the gyros, but probing around with the end of an antenna is like soldering SMD components with a flame thrower, so it’s hard to know for sure.
If we can get a version of software with the gyros, and/or the acc sensors locked, I’m still interested in knowing which is it, though I’m not sure it matters much. I wasn’t kidding about the copper tape either :-)
Rusty
Hi Adam,
The version probably doesn’t matter I guess, but it might be better to use Aileron Assist 8b since that’s what I have in the plane for comparison.
Yes, for the copper tape, I’d be trying to wrap the whole board, but I don’t know if I’d do that for more than just a test.
Separating the antennas will absolutely cure the problem, assuming you can get far enough away, and haven’t angered any of the RF spirits. Even with the 100mw XBee, I only have to move it about 6 inches away on the bench, and the 500 mw video TX doesn’t have to move much farther than that. I’m sure the reasonable solution to this will be separation.
Have fun.
Rusty
From:
uavde...@googlegroups.com [mailto:uavde...@googlegroups.com] On Behalf
Of Adam Barrow
Sent: Saturday, October 31, 2009 6:03 PM
To: uavde...@googlegroups.com
Subject: Re: XBee transmissions causing servo glitching
Rusty,
Greetings,
While I was waiting for my main computer to finish a bunch of housekeeping activities, I went out to the garage and poked around in the software a bit to see if I could figure out how to set the gyros and acc to fixed numbers. What I found was the following section at the bottom of analog2digital.c
// perform just a little bit of filtering to improve signal to noise
xaccel.value = xaccel.value + (( (xaccel.input>>1) - (xaccel.value>>1) )>> FILTERSHIFT ) ;
xrate.value = xrate.value + (( (xrate.input>>1) - (xrate.value>>1) )>> FILTERSHIFT ) ;
yaccel.value = yaccel.value + (( ( yaccel.input>>1) - (yaccel.value>>1) )>> FILTERSHIFT ) ;
yrate.value = yrate.value + (( (yrate.input>>1) - (yrate.value>>1) )>> FILTERSHIFT ) ;
zaccel.value = zaccel.value + (( (zaccel.input>>1) - (zaccel.value>>1) )>> FILTERSHIFT ) ;
zrate.value = zrate.value + ((( zrate.input>>1) - (zrate.value>>1) )>> FILTERSHIFT ) ;
I have no idea what a normal number would be, but I first set the xrate, yrate, and zrate to 100. This (amazingly) seemed to work, and the board seems to initialize, and the red light starts flashing. When I tilt the board, the aileron and elevator servos very slowly move, rather than moving quickly. Since I believe ACC values are typically used as long term corrections, this seems to be about what I’d expect.
For these tests, I’m still using Ben’s code, with the NORADIO option turned on. With the rates set to 100, I can move the XBee, and even the 500mw video TX all around the board, and nothing happens. This would seem to be pretty strong evidence that the gyros are indeed the problem, and I wonder if someone could try one of the green boards?
For fun, I also tried leaving the rate lines alone, and setting the accel values all to 100. That initialized OK, and moves more normally when tilting the board. Bringing the XBee or video TX close to it causes the same problems as before.
From what I can see, I’d say the gyros are the source of the interference.
Rusty
Hi Adam,
Our messages crossed paths on the send/receive. I’ll take a look at what you changed, since I’m curious if I did it right. I’m really lousy at programming, but I’m trying to learn.
Hi Bill,
I tried Adam Barrow’s version as well, to see if there was any difference in how the board behaved, and to add the live receiver to the test. The results were the same, so it would seem the problem is only with the gyros.
This of course begs the question of whether the gyros are especially sensitive to 900 MHz. I’m planning to convert all my video to 1280 MHz as soon as the boat from China arrives, and I’ll be interested to see if that interferes with the gyros as well. Didn’t someone say they used 2.4 GHz video transmitters around the UDB without a problem? If so, then 2.4 GHz XBees would surely be OK, assuming you’re not using a 2.4 GHz radio.
I just ran a test using the 900 MHz XBee (100mw XSC version) and the 900 MHz 500mw video TX. The first sign of movement from the servos comes when I’m 8-10 inches away with the XBee, and about 24 inches with the video TX. Proximity of other metal, such as pushrods, wires, etc could change these distances, and sharing the power between the 900 MHz source and the UDB could add to the problem as well. The best suggestion would be to try to keep it as far away as possible, and test it in stabilization mode (on the ground) to see if it seems to cause a problem.
As for testing the next version, I’d be honored to blast it with any RF I can lay my hands on, except for the 30kw RF amplifiers on our MRI scanners :-)
Rusty
From: uavde...@googlegroups.com [mailto:uavde...@googlegroups.com] On Behalf Of prem...@nycap.rr.com
Sent: Sunday, November 01, 2009 12:03 PM
To: uavde...@googlegroups.com
Rusty,
From your description, I think we both made essentially the same change. The
way I did it (by commenting out certain lines) will just keep the values at whatever
they were initialized to, where your aproach sets them to 100 specifically.
Adam Barrow
Adam,
Your way was the smarter way to do it. I just got lucky :-)
We crossed paths on the send/receive again, but you’ll see in my other message that I tried your version as well.
Thank,
Rusty
Hi Adam,
If I tried the copper tape, that’s how I would do it. You’d have to put the board in a non-conductive bag, then wrap the tape around that, and ground a spot on the tape. As for the power supply, I simply don’t know if it would make a difference or not. The primary thing I know about RF is that I can’t predict what will or won’t work, so I’m afraid you’d just have to try it to find out.
The distance you describe will almost certainly be OK. Probably the easiest way to see the problem is to have the plane held level and still, then turn everything on but the XBee. Once it’s ready to go, you should be able to turn the switch from manual mode to stabilized mode, and not see anything happen on the plane. Turn the XBee on when in manual mode, and wait a couple minutes. Now flip the switch to stabilized mode. If you’re getting interference, you’ll see the servos move. You can also just leave it in stabilized mode, and watch them slowly creep.
Another factor might be the amount of transmitting that the XBee is doing. Mine is set up with a GPS, and is sending data 5 times per second, so that would likely be worse than if you were sending only once per second. Also remember that the 900 Pro is only 50mw, not 100mw like my XSC version. I have the Pro version as well, but it’s not set up with the GPS tracker gizmo.
Cheers,
Rusty
---------------------------------
Hi Pete,
I’m using that same area in the TwinStar for the UDB, only mine is accessed from the top. I cut a fairly large rectangle on the top of the fuselage, just behind the wing, and have that whole (enormous) section open. When I don’t have an AP in there, I can carry a sandwich :-)
As for the XBee, it would be interesting to know if the 2.4 GHz XBee could cause a problem. If you ever have the opportunity, you could move the XBee canopy to the fuselage where the UDB is, and see if it causes a problem.
Rusty
From:
uavde...@googlegroups.com [mailto:uavde...@googlegroups.com] On Behalf
Of Peter Hollands
Sent: Sunday, November 01, 2009 4:41 PM
To: uavde...@googlegroups.com
Subject: Re: XBee transmissions causing servo glitching
Russel:
I moved the XBee further from the UDB (~10 inches away instead of
about 3). This seemed to help slightly, but just a little.
I then tried adding a decent sized capacitor between +3.3V and GND on
the XBEE regulated board, and then between +5 and GND. Neither seemed
to make much difference. (Moving the position my arms near the plane
made more of a difference!)
I then tried powering the XBee from a separate source, while still
connecting the IO pins to the UDB. I also connected the ground of the
UDB to the ground of the external power source for the XBee. When set
up like this, and with the XBee still separated from the UDB by about
10 inches, this interference seems to be gone!
So now I'm wondering if the problem is sharing the power source, or if
it's having unshielded power lines for the XBee running right past the
gyros. :) I think I'll try to rig up a similar grounded cable to
what Pete made, and also pull power from the receiver instead of from
the pins next to the UDB's serial IO pins, since the power for those
pins runs right under the gyros.
I'm really hoping to avoid needing a 2nd battery on board!
Thanks for all the great help!
Ben
Hi Adam,
The main concern I’d have is the current capacity of the 3.3V regulator on the UDB. The schematic isn’t really that complete, and doesn’t give the actual component, so we’d have to look at a board to figure out what it is, then check the datasheet. The XBee module pulls about 180 ma, which is actually higher than the 150ma “guaranteed” rating of the regulator on the Sparkfun explorer board. I’ve never had a problem using the Sparkfun regulator, so clearly it’s capable of a bit more than 150ma.
The secondary concern (pretty close second) would be that the XBee’s large, rapid current draws would affect the 3.3V supply on the UDB, and make it vary. Since it’s used for gyros, ACC sensors, and the CPU, that might not be a good idea.
Rusty
I also thought on connecting the xbee directly to the GPS's tx pin,
working at 4800 baud, 8bits, non parity, 1stop bit. i do get an output
and i can see some data off the xbee in my pc but the data I see is
all BS, doesnt make any sense. Any ideas? i tried all baud rates.
anyways i know my GPS. if im not wrong im supposed to obtain pure NMEA
off the GPS...
I would really appreciate your help... if you need more information
let me know! Thanks!!
On Feb 1, 6:25 pm, Riccardo Kuebler <kueb...@ticino.com> wrote:
> John,
>
> yes, you will find a very interesting discussion about this in the precedent
> posts of this thread.
> It seems that the SF regulated board for Xbee has problems feeding Xbee. It
> is rated for 150mAh.
> Adafruit is rated 250mAh.
>
> Strange is that Xbee 2.4GHz transmission consumption is rated 215mAh and
> 900MHz is 210mAh.
> Transmit mode is different: 2.4GHz is DSSS and 900MHz is FHSS.
> Could it be that FHSS needed transmission current is higher than DSSS and
> its real consumption higher then too?
>
> Cheers,
>
> Ric
>
> 2010/2/1 John McClelland <mcclelland.j...@gmail.com>
>
>
>
> > Ric
>
> > I didn't quite understand what you were saying in the second sentence
> > referring to the 2.4 GHz and 900 MHz units. Was there a problem with the
> > 900 MHz?
>
> > Best,
> > John
>
> > ----- Original Message -----
> > *From:* Riccardo Kuebler <kueb...@ticino.com>
> > *To:* uavde...@googlegroups.com
> > *Sent:* Monday, February 01, 2010 12:45 PM
> > *Subject:* Re: XBee transmissions causing servo glitching
>
> > Hi,
>
> > if that could be of general interest I just had the same feeding problem.
>
> > What I noticed is that with SF regulated unmodified adapter 2.4GHz Xbee
> > works well and 900MHz only output points.
>
> > I tryied this<http://www.adafruit.com/index.php?main_page=product_info&cPath=29&pro...>adapter from Adafruit and it works well with both. It is rated 250mAh.
> > Probabily is for that that Jordi recommend this unit for Ardupilot
> > telemetry.
>
> > Xbee were flashed with XBP09-DM, as recommended by Ben.
>
> > I verified the gyro interference too and noticed that my homemade antenna
> > only cause important glitch when at less than 7-8 cm. The worst case is if
> > antenna is put at 45° between gyros. At 90° it is only noticeable.
>
> > Anyway coaxial antenna cable is 46cm long. Antenna is then in the rear of
> > the plane far away from UDB and RC rx.
>
> > Best regards,
>
> > Ric
>
> > 2009/12/7 ben levitt <ben...@gmail.com>
>
> >> Here are my module configurations for ground and plane. (You'll need
> >> to have the correct firmware installed before you can apply my
> >> configurations.)
>
> >> Ben
>
> >> On Sun, Dec 6, 2009 at 12:48 PM, Adam Barrow <adam.bar...@gmail.com>
> >> >> > On Sun, Dec 6, 2009 at 1:45 AM, Adam Barrow <adam.bar...@gmail.com>
> ...
>
> read more »