Shop OBEX P1 Docs P2 Docs Learn Events
Electric motor causes SX to crash — Parallax Forums

Electric motor causes SX to crash

LightfootLightfoot Posts: 228
edited 2007-07-16 15:25 in General Discussion
I am using two SX chips. One receives serial data and converts it to parallel. The other takes the parallel data and turns it into a PWM frequency. My application requires the circuit board to be adjacent to the motor and the SX's need to be supplied from the same power source as the motor (optoisolation will not work). Right now the circuit is on the breadboard and emf does not seem to be the problem. I moved it a foot or so away from the motor and same problem. I think the noise is caused by the motor interfering with the SX's power, clock, or the signal. The serin SX used an external resonator and each sx has an 10000pf cap accross the power pins. How do I make those SX's immune to the motor noise.

Thanks

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔

Comments

  • BeanBean Posts: 8,129
    edited 2007-07-14 00:20
    Can you post a schematic ?

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Teacher: What is the difference between ignorance and apathy ?
    Student: I don't know and I don't care
    Teacher: Correct !
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    www.hittconsulting.com
    ·
  • LightfootLightfoot Posts: 228
    edited 2007-07-14 00:25
    heres the schematic

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    612 x 527 - 98K
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2007-07-14 14:40
    Looks and sounds like motor noise [noparse][[/noparse]which can be quite high frequency] from the brushes.

    You might consider setting up a low pass filter [noparse][[/noparse]under 1000 Hz or so] with 1 amp capacity on the input side of the LM7805.
    Or, you might add a 1000uf cap on the input side.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Everything in the world is purchased by labour; and our passions are the only causes of labor." -- David·Hume (1711-76)········
    ···················· Tropically,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan
  • Guenther DaubachGuenther Daubach Posts: 1,321
    edited 2007-07-14 17:56
    Large capacitors (especially electrolytic types) do nor really help filtering high frequency noise. Because of their large internal or parasitic inductance the filtering effect is almost zero for higher frequencies.

    The 7805 data sheets highly recommend to add a 0.33 µF cap between input and ground, and a 0.1 µF cap between output and ground, both with leads as short as possible. This makes sure that the 7805 does not oscillate.

    When the sum of the output capacitors is greater than the sum of input capacitors, it may happen that the output capacitors discharge through the 7805 from the output to the input when you turn off power. This can destroy the 7805. Therefore, it is a good idea to place a diode (1N400x) between input and output with the cathode pointing to the input side.

    I have built some projects with SXes for PWM-controlling DC motors up to 24V/25A without having trouble. In all cases, I used PCBs that were designed to minimize EMI, i.e. to reduce the electro magnetic interference generated by the SX. But what works in one direction also works in the other. So, an EMI-proof design also protects the SX from external noise.

    Sometimes, it is hard to determine what the source for trouble is. In your case, it is most likely the DC motor. So I would try to minimize noise at the location where it is generated, i.e. at the motor. Maybe, a varistor across the motor can help to reduce "spikes". In one project, throttle coils in series with the motor leads helped a lot. Another option would be to run the motor leads through a ferrite. There are snap-on ferrites available, or toroid-shaped ones.

    Often, there is a lot of "black magic" and "crystal ball reading" necessary to find the best solution smile.gif .

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Greetings from Germany,

    Günther
  • Beau SchwabeBeau Schwabe Posts: 6,547
    edited 2007-07-14 17:59
    Something like this might help if you truly have noisy lines, but I suspect that your motors might "surge" the voltage down below brownout if the power supply is inadequate for the initial demand.

    http://forums.parallax.com/attachment.php?attachmentid=39280

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2007-07-15 15:15
    Both Guenther and Beau have good points.
    Generally with 78xx regulators, if you have over 10uf filtering on the output, you need a diode setup to avoid damage [noparse][[/noparse]read the product PDF] when the power is shut down.

    Guenther really has a saner approach to regulators. Let the regulator flatten out the low frequency ripple without the aid of large filter caps and used small caps to clip high frequency spikes. I guess I still return to 'bigger is better' thinking.

    And Beau may have recognized a brownout condition that wasn't considered. If that is the case, my suggestion of a larger capacitor on the input side might prevent the brownout from affecting the SXes.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Everything in the world is purchased by labour; and our passions are the only causes of labor." -- David·Hume (1711-76)········
    ···················· Tropically,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan
  • Beau SchwabeBeau Schwabe Posts: 6,547
    edited 2007-07-15 17:32
    Kramer,

    The brownout condition is a common problem with myoelectric prosthetic hands where usually you only have one portable power source (around 6V) and not much voltage overhead during surge conditions to keep the micro processor "alive". The circuit I provided can help take care of this, at least allowing the micro processor time to recognize the situation and power down the motor appropriately.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • jb1311jb1311 Posts: 20
    edited 2007-07-15 18:01
    If you think it is a brownout, try a diode between the 15v supply and the input of the regulator. That will keep the motor from draining the input capacitor.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2007-07-16 15:01
    Beau,
    Excuse me as I initially only glanced at your schematic and thought it was the same as the manufacturers. Now I see it is quite different and quite potentially useful. I'll have to take a closer look at it as it certainly offers a neat alternative for one battery robotics.·


    Is that really 5volts output from a 7805?· I am a bit confused how the diode between the ground and the regulator might·affect the output voltage.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Everything in the world is purchased by labour; and our passions are the only causes of labor." -- David·Hume (1711-76)········
    ···················· Tropically,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan

    Post Edited (Kramer) : 7/16/2007 3:08:06 PM GMT
  • Beau SchwabeBeau Schwabe Posts: 6,547
    edited 2007-07-16 15:25
    Kramer,

    "Is that really 5volts output from a 7805? I am a bit confused how the diode between the ground and the regulator might affect the output voltage."

    Yes, going from left to right, the first diode and capacitor combination off of the INPUT terminal to the regulator form a first stage "diode/capacitor filter". The second diode connected to the regulators GND terminal shifts the Ground reference by 1 diode (.6V) in preparation for the third diode. The third diode connected to the regulators OUTPUT forms a second stage "diode/capacitor filter". Since the third diode creates a diode voltage drop of .6V it is necessary to compensate that with the use of the second diode to shift the voltage up by .6V so that the net output is 5V.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
Sign In or Register to comment.