Hi,
I'm working on precise automatic speed regulation for the 24 V DC motor (aprox. 50 W) which drives a 8 mm film projector. I'm using Arduino Uno and L298N module.
The DC motor can be regulated via a transistor system with a potentiometer, that is original and built into the projector. However, it doesn't offer precise enough regulation and the speed of the projector changes slightly with time and with the imperfections on the film perforation. But exact frames per second are crucial to conversion using a DSLR thus the usage of arduino and PWM for powering the motor.
I've also installed a speed sensor (for the shutter disc) which will be essential to the speed regulation. Next step will be automatic a PID regulation.
So far the system measures speed and powers the projector with manually set speed by hardware PWM signal sent from arduino Pin 5 to ENA input of the L298N. Arduino is powered from USB or 9V adapter. But there's a slight problem.
The DC motor of the projector has 4 cables - two are for energising (armature or something I guess) and the voltage between them is stable 24 volts (whatever the speed of the motor). Those I left connected as they were. Two other cables have a voltage of 10 to 24 volts according to the position of the potentiometer - that's how it changes speed. Their polarity reverses via a mechanical switch - that's how it changes direction. But I'm using only one direction, so I don't send the wrong voltage to the L298N.
The power to the second pair now goes from the projector to the Vcc and GND inputs of the L298N module which is then connected to arduino pins 5 (ENA - PWM), 7 (In 1 - HIGH) and 9 (In 2 - LOW). Then the motor is connected to the L298N output via port 1 (HIGH) and 2 (LOW). The arduino, L298N module and the DC motor have the same ground and are connected to one of the motor cables (the one with lower potential, so I guess it's the ground).
The projector can now be regulated via the potentiometer (voltage change) and by PWM as well. By sending AnalogWrite (PWM) signal to EN1 (interval of 140 to 255 seems to work) I can regulate the speed of the motor.
Now if I don't touch anything, it works like it should. But if I touch the cable (just the rubber isolation, basically anywhere) that goes from PIN 9 to In2 of the L298N module, the speed of the motor decreases significantly. The only thing that I think could be the problem is, that the ground of the projector is of different electric potential than the ground of the rest. This is probably due to the armature ground being different to the rest of the motor. But I can't connect them together, because it may damage something in the transistor regulation circuit of the projector and I would lose the option to reverse the motor direction via the mechanical switch on the projector.
Any ideas what could cause the speed decrease when touching the cable?
Thank you in advance.
With regards
Daniel Krnac