Intermittent motor control and singing motors
Forums:
Just got my Picoborg Reverse wired in to the PI using the supplied cables. I have a 6v DC supply courtesy of 4AA batteries plugged into the board, with the correct polarity.
I have followed the instructions, enabled I2C and installed the software.
Running the desktop program with the 2 sliders does allow both M1 and M2 to turn, and reverse.
However, M1 is intermittent. Sometimes it will not move at all. Leave it for a while to "cool down" and then it works for a short time.
Also, it doesn't work as it says, in that the further you push the slider the faster the motor rotates (ie more voltage applied). What happens is that between 1 and 39 the motor does turn slowly, with a strange singing sound. After 39 the motor does not turn, and the pitch of the "singing" increases.
I am no expert, but I suspect the output to the motors is not strictly DC, and there may be some sort of wave form at play here.
Can you advise what I should be checking to ensure a pure DC signal to my DC Motors, and why M1 is intermittent?
Thanks in advance.
piborg
Sat, 01/16/2016 - 16:54
Permalink
Motor trouble
The speed control is performed using a technique called Pulse Width Modulation (PWM)
In simple terms PWM works by turning the output on and off at a fast rate, simulating a reduced voltage.
If you want a better explanation of PWM check out this video: Circuit Skills: PWM.
For a detailed explanation see the Pulse Width Modulation Wikipedia page.
Under most circumstances the motor itself provides enough smoothing to the PWM signal that it would behave the same as the equivalent DC level.
You can use a capacitor to smooth the PWM out to a DC level, but it should not really be necessary here.
See this blog post for a guide to getting a DC level from a PWM output: Converting PWM to a Voltage.
Based on your previous posts I am presuming that you are trying to control the yellow motors which come with a PiCy kit.
If that is the case they are really intended for 3V operation, which would be 50% of the 6V input.
They will work fine at 6V, but it will shorten the lifespan of the motor, particularly the gearbox.
As for the actual problem the screeching / singing suggests three likely candidates:
This is causing it to briefly "shut down" when the motors try to draw power
If you could check the following and tell us what happens it will help narrow the problem down:
If so rechargeable AAs are rated at 1.2V, which would only supply 4.8V, not enough to run PicoBorg Reverse
While the PicoBorg Reverse should work with a 6V supply we would recommend a minimum of 7.2V
Suityou01
Sat, 01/16/2016 - 18:53
Permalink
Thank you very much for such
Thank you very much for such a detailed response at such short notice. And on a Saturday as well!
Firstly, following you're advice, it is now working famously. :)
Now some answers to your questions :
Yes it is indeed the yellow motors.
The power to the board was provided by 4AA non-rechargeable batteries, of questionable origin. The PD was <6v, so this was swapped out for a PP3 borrowed from the smoke alarm. This had a profound difference, no more singing and it was possible to put the motors to "full chat" briefly, while understanding that the lifespan at 9v would be even more reduced!
The singing noise was coming from the motor.
I have not noticed any of the chips getting hot.
Both motors were singing with the weak <6v power source.
I didn't need to swap the motors as the PP3 fixed the problem.