Beginners: please read this post and this post before posting to the forum.
0 Members and 1 Guest are viewing this topic.
Shielding sensitive electronics with aluminium foil also helps.
putting some distance between the sensor and the motors is the best solution.many robot applications using Digital Compass put the sensor at the top of a long mast. ugly but practical.
current flowing through a wire creates a magnetic field as wellso keeping any wires carrying high current as short as possible and keeping the compass away from those will help a lot.
do the motors provide a predictable deflection in the compass readings or is it just random noise?if the readings are stable when the robot is not turning and the motors are running you might try a software filter.
Brushed motors benefit from having suppressors/capacitors fitted.....have got them fitted on your motors ?
Also check your earthing. make sure that everything that could be grounded is.
Also consider using Schottky diodeshttp://en.wikipedia.org/wiki/Schottky_diodehttp://en.wikipedia.org/wiki/Inrush_current_limiterI used Inrush curret limiters on one of my projects, not sure if they are suited to yours. They mop up current going to the motors at start up. Once they heat up current flows more freely. On a second start they are allready warm and the motors spool up a little quicker. ( I even used a bunch of them as a bullet proof speed controller )http://en.wikipedia.org/wiki/Varistorhttp://en.wikipedia.org/wiki/Transient_voltage_suppression_diodeI had a lot of problems with my high performance RC models. all that current and arcing caused a big headacheall sorts of electrical and magnetic Fields are generateed, hi current motors are really bad for this. I'm not expert on electronics, I'm sure someone here can give you finer advice on these matters & help you solve your problem, sorry i cant help more than this
Hi,Quote from: azy on November 14, 2010, 05:50:14 AMShielding sensitive electronics with aluminium foil also helps. Aluminum doesn't do much good stopping magnetic interference, iron plate does.If it were a stable offset, which I doubt though, a permanent magnet could be used to bias the compass. An electronic bias is possible too, but only with a steady offset.Mounting inductors at different angles relative to the compass, to keep their fields away from it will help too, but the motors will likely be the worst problem, so that should be the first thing to attack.Twisting the motors power wires and if possible, mount them in an iron tube for as long a bit of their run as possible. Shield the motors with iron plate (but make sure they can still get rid of heat).
Changing the PWM frequency (experiment) might help and (shielded) LC filters will ensure a "soft" waveform to the motors, eliminating some magnetic emission as well.And, as dunk suggests, distance is the ultimate tool for getting what's left, as magnetism, like light, gets weaker by the square of the distance.
I'm assuming the ally foil (ive seen in a number of applications) helps shields from em radiation...radio waves...like a faraday cage ?
Steel wrapped round the motor casing helps contain the magnetic feild.
Quote from: dunk on November 14, 2010, 04:20:52 AMputting some distance between the sensor and the motors is the best solution.many robot applications using Digital Compass put the sensor at the top of a long mast. ugly but practical.Does this long mast have to be relatively tall? It wouldn't be very easy to mount it more than a few inches up, for balance issues.
Quote from: dunk on November 14, 2010, 04:20:52 AMcurrent flowing through a wire creates a magnetic field as wellso keeping any wires carrying high current as short as possible and keeping the compass away from those will help a lot.I noticed that readings start screwing up a little around high frequency I2C and USART lines... Do I need those to be shorter or something?
Quote from: azy on November 14, 2010, 10:09:40 AMSteel wrapped round the motor casing helps contain the magnetic feild. Yes somewhat, but soft iron is much better.A dual layer of iron plate, separated by a small distance, is a very good screen and the inbetween-material can be foam or massive plastic of sorts.
Quote from: rbtying on November 14, 2010, 11:43:24 AMQuote from: dunk on November 14, 2010, 04:20:52 AMputting some distance between the sensor and the motors is the best solution.many robot applications using Digital Compass put the sensor at the top of a long mast. ugly but practical.Does this long mast have to be relatively tall? It wouldn't be very easy to mount it more than a few inches up, for balance issues. yea. probably. rather than researching the way to calculate the exact distance it's probably easier to work it out experimentally.Quote from: rbtying on November 14, 2010, 11:43:24 AMQuote from: dunk on November 14, 2010, 04:20:52 AMcurrent flowing through a wire creates a magnetic field as wellso keeping any wires carrying high current as short as possible and keeping the compass away from those will help a lot.I noticed that readings start screwing up a little around high frequency I2C and USART lines... Do I need those to be shorter or something?so I2C and USART lines should be fairly low current so they shouldn't make too much difference. but yes, keep any wires that run close to your compass as short as possible.dunk.
How thick would the plates need to be, and how far apart? (1cm?) and HDPE works in between, right?