low pass filter? integrator? de-coupling?

Well I have been reading and not making much headway. Here is the problem:

90v dc motor driven with a KB electronics KBWS drive, controlled by the Arduino. This is working great.

Incremental optical encoder used to sense position. Was working great till I hooked up the motor. Max pulse frequency is under 500hz.

The KB drive is a PWM drive that runs at 20khz. Must not have good filtering on it as it makes all kinds of radio noise. This noise is interfering with my encoder signal. I get LOTS of random counts as soon as I power the motor drive up.

The cable from the encoder is shielded but it seems I need to add some filtering to get rid of the noise. How?

My initial thought was to add some decoupling capacitors to the encoder power lines and a low pass filter to the signal lines but I am having trouble calculating the proper values for the components.

I have turned on the pull up resisters on the Arduino input lines so I am thinking that perhaps I have a 20k input impedance. The encoder has TTL level outputs and seems I remember that has a drive current around 20 mill amps.

So, what would you do to your signal lines? Simple de-coupling capacitor to ground or a low pass filter series resistor and capacitor? If so, what values?

Keshka

You want to decouple the supply rather than the signal lines. http://www.thebox.myzen.co.uk/Tutorial/De-coupling.html

However, I think this is a case for isolating the motor circuit from the control circuit so you do not have a common ground between the two systems. Do this with an opto isolator between the arduino and the DC control circuit.

You could also filter the signal lines (not decoupling) with perhaps a low value R and small C. Say 47R and 220pF for a start. I would also add some protection:- http://www.thebox.myzen.co.uk/Tutorial/Protection.html to the lines that are being affected. The other line of attack would be to use ferrite beads and small chokes as small inductors.

Best of luck.

Thank you GM, Good words for sure! I will follow your advice and add several decoupling caps and the filters to the encoder lines.

When I wrote yesterday I had already isolated the drive and motor as best I could. I moved the drive as close to the motor as physically possable, cut my motor leads short and isolated the motor and drive from frame ground. These, especially the last seemed to help a great deal. The signal lines are also opto isolated at the drive (always have been).

Things I have not done yet:

ground the motor to the drive. Do you think that would make any diffrence? As mentioned above, they are both currently isolated from both frame and signal ground.

My partner thinks we will be required to ground the motor to pass electrical code. I am fighting that battle as the carrage frame just give the motor a bigger "antenna" to transmit with. Currently the carrage is tied to utility/earth ground.

I looked into ferrite beads and the specs seemed to indicate they only provided help above 1 Mhz and would not do much good against the 20khz PWM noise from the drive. Is that a good assumption or do you think they would still help?

Thanks! Keshka

I looked into ferrite beads and the specs seemed to indicate they only provided help above 1 Mhz

Yes but remember the edges of the spikes have energy in the higher harmonics.

I would also look a differential chokes and capacitors for filtering the AC. This sort of thing:- http://uk.farnell.com/jsp/search/browse.jsp?N=500006+1002392&Ntk=gensearch_001&Ntt=choak&Ntx=mode+matchallpartial

Currently the carrage is tied to utility/earth ground.

Yes that is good.

My partner thinks we will be required to ground the motor to pass electrical code

:o wow my partner thinks nothing at all along these lines. Maybe only I am wasting my time on electronics again. ;) However, I am not sure what you want to ground here.

The signal lines are also opto isolated at the drive (always have been).

That's good but without breaking the ground between arduino and motor it is less effective.

These sort of things can be tricky, you might look into if all the elements of the frame have a solid connection, sometimes you have to scrape paint or surface finish off elements of metal work to get it electrically together.