ACD input resets Picaxe

Asimov

Member
Help !

In brief, I have an 18M2 with a 10K linear POT providing an input to an ADC pin on the 18M2. Several readadc values are taken to average out the input. A value of 0-255 is then sent to an OLED display, nice and stable, no problems so far.

I then hoped to use that value to operate a pwm pin connected to a L293D. I get an appropriate voltage output from the L293D but when I connect a motor and operate the POT the Picaxe resets.

If I take the POT out of the circuit and operate the motor via the serial window with appropriate code, I can operate the motor without issue.

I am sure there is something fundamental I am missing.

Any suggestions welcome
 

hippy

Ex-Staff (retired)
I would suggest disconnecting the motor but operating it as if it had the motor connected; does it still reset ?

If it works okay without the motor but doesn't with the motor connected it would seem it is motor related, perhaps electromagnetic noise or collapsing the power supply. If it resets without the motor connected then it's perhaps something else.

It would help if you could post your full circuit diagram and your source code.
 
Top