MUFF WIGGLER Forum Index
 FAQ & Terms of UseFAQ & Terms Of Use   Wiggler RadioMW Radio   Muff Wiggler TwitterTwitter   Support the site @ PatreonPatreon 
 SearchSearch   RegisterSign up   Log inLog in 
WIGGLING 'LITE' IN GUEST MODE

filter PWM noise from motor
MUFF WIGGLER Forum Index -> Music Tech DIY  
Author filter PWM noise from motor
das_Produkt
Hi.

I had the idea for a crude voltage controlled walkman.

The motor speed is controlled by PWM from a microcontroller pin. The pickup is adapted from the Music Thing Magnetophone.

I regulate the 12V supply (MFOS wallwart supply with LM7812 and 1,5 A wallwart) with a L78S05 down to 5V for the motor.



My problem is the power supply. The motor puts a lot of noise on the power supply line and I can hear the ~500 Hz PWM frequency on the output. Is there a way to filter the noise from the supply?
guest
can you increase the pwm frequency? if not, put an inductor and capacitor from the 5V line to the transistor.
das_Produkt
Increasing the frequency seems like a good idea and I tried it after your suggestion.

I'm using an arduino for prototyping so I can set the pwm frequency to 31kHz.

But, unfortunally, the motor loses a lot of torque at higher frequencies and is unusable at 31kHz. I have to research inductors, because i never used them before.

------------ Edit, some hours later... ----------------------------

Actually, high PWM frequencies work, even 60kHz.

I just forgot the pull down resistor... (And changed some other stuff, but the pull down was the problem)



The PWM frequency can still be measured at the output, obviously.

Could someone help me find out what kind of inductor I should use? I think it should be some kind of LC-Filter? I'm not even sure where to start my search.
guest
the LC filter should be well below your PWM frequency: f=1/[2*pi*(L*C)^0.5]. so lets say we set it down at 1kHz, and use a 100uF capacitor, that gives L = 300uH. and since youre driving a high current load, lets assume 1A, you want a low voltage drop, so less than 0.1ohm resistance in the inductor. so something like this would work:

https://www.digikey.com/product-detail/en/wurth-electronics-inc/744156  /732-2286-ND/2208862

although thats a bit expensive, and probably overkill. if you stick a big capacitor right at the motor, and run a seperate wire right from your powersupply to the motor, it migh be ok.
Graham Hinton
das_Produkt wrote:
Is there a way to filter the noise from the supply?


You can't filter the current you are injecting into the 0V or the common impedance coupling you are causing by regulating from the analogue +12V. It is better not to have either there in the first place.

A separate +5V supply, referenced to the analogue 0V, but not sharing the motor current paths with it is what you need.

btw, CV-ing the speed of a walkman is a good way of chewing up tapes unless you limit the rate of change.
elektrouwe
das_Produkt wrote:

I regulate the 12V supply (MFOS wallwart supply with LM7812 and 1,5 A wallwart) with a L78S05 down to 5V for the motor.

Instead of burning down 12V to (estimated) 1..5V for the motor I would suggest using a buck converter, e.g. a cheap chinese adjustable DC/DC module, and voltage control this via smoothed (LP-filtered) PWM.
DC operation keeps the motor quiet and the DC/DC module saves you a heatsink.
Voltage control of most buck converters can easily be done by connecting a 3rd resistor to the feedback pin and applying CV to this resistor: The feedback pin is kept @ Vref- e.g. 1.2V for an LM2596ADJ . If CV is > Vref, then the output voltage is reduced, because the regulation loop keeps the feedback pin @ Vref.
Upper motor voltage is defined by the 2 voltage divider resistors connected between Vout, feedback and GND, while CV is 1.2V.
Lower motor voltage is defined by the 3rd CV resistor and CV=5V.

I use this simple and cheap method often for Arduino controlled power supplies.
das_Produkt
guest wrote:
the LC filter should be well below your PWM frequency[...]


Thank you for your thorough explanation, that was really helpful. But you are right, it's a bit overkill. That part costs more than the rest of the parts combined, including the walkman... But I think, now I know enough to search for a cheaper, "good enough" part.
But, as I write down below, I have to try some other ideas first.

elektrouwe wrote:
DC operation keeps the motor quiet

This made me wonder if the noise I'm hearing really is caused by the noise on the power supply. And it's not.
The cause is the PWM on the motor next to a magnetic pickup.
If I keep the circuit as it is and control another small motor, the output of the walkman is silent, until I move the other motor next to the walkman.

So I will try to control the motor with DC to see if it works better. Your tip with the LM2596 sounds interesting.

Graham Hinton wrote:
A separate +5V supply, referenced to the analogue 0V, but not sharing the motor current paths with it is what you need.


So the "professional way" (if any professional would ever do this) would be to use a separate supply? If this thing will ever work, I wanted to power it with a 12V DC wallwart. You would suggest I used a second Wallwart for the electromechanical part, just referenced to the analog 0V?

Graham Hinton wrote:
btw, CV-ing the speed of a walkman is a good way of chewing up tapes unless you limit the rate of change.

Actually, I'm not that concerned about my tapes. I want to use it mostly with selfmade tapeloops and found cassettes and if some of them get destroyed, it's not that big of a deal. Maybe the thing will even sound interesting while it eats my tapes.
Graham Hinton
das_Produkt wrote:

The cause is the PWM on the motor next to a magnetic pickup.
If I keep the circuit as it is and control another small motor, the output of the walkman is silent, until I move the other motor next to the walkman.
...
You would suggest I used a second Wallwart for the electromechanical part, just referenced to the analog 0V?


That isn't going to help now you have found the source of the problem is within the Walkman itself.
das_Produkt
Graham Hinton wrote:
[..]

That isn't going to help now you have found the source of the problem is within the Walkman itself.


Yeah, I found the reason for the noise on the output.

I started to write my my answer before I had the idea to test if the motor next to the pickup was the problem. Afterwards, I didn't think about if my question still made sense and forgot to delete it.

Sorry for that.
das_Produkt
Hi. It's me again.

After a long waiting period, I got some LM2596 boards from china.
(The first package was lost by the postal service. Or it was never send, who knows. After waiting for two months, I just ordered some from another seller.)

Like elektrouwe said, voltage control of them with lp-filtered pwm is easy.
But I didn't read his post careful enough... The output voltage can never be lower than the Vref, and in practice it's always >1.4V. Which is a bit to high for my use. I would like to get the voltage <1V for a really low pitch.

My new idea is using an op amp to supply the necessary current for the motor.
Is that a stupid idea? (Under the assumption, that this whole project is not.)

Would a L272 be usable for this? If I read the datasheet correctly, it should be usable: It's single supply, it works with a 5 V source, it can output 700mA (while I need 250mA max).
guest
yeah, the L272 should work. you wont get the full 5V, though, as the output cant go rail to rail. it gets a bit closer to the bottom rail than the top, so if you connect the motor to 5V (rather than ground) and the opamp output, you will get a slightly faster top speed. the limiting factor for this sort of thing is heat in the opamp, and you should be ok there if it draws 250mA max.
das_Produkt
Thank you.

Hmm, I knew there would be a problem. The faster top speed is no concern, 5V is to fast, anyway.
That the output can't reach 0V could be a problem, because it could mean that the motor can't be stopped.

How close to the bottom rail does the output go? I can't find this in the datasheet.
guest
youll be fine there, as the motor will present a very small resistance to ground, and will pull the output down. the one thing i cant find in the datasheet is the common mode input range, so youll probably want to set the opamp up as an inverting amplifier, so the input pins stay at a fixed voltage.
das_Produkt
The L272 came and I had to try it as soon as I had time.

I set the L272 as an inverting amplifier (combined with the inverting lpf) and it works great.
The output gets as low as 0.12 V and that is low enough for my purpose. The motor stops spinning at 1V.

Thank you again!
guest
glad to hear you got it working.
MUFF WIGGLER Forum Index -> Music Tech DIY  
Page 1 of 1
Powered by phpBB © phpBB Group