I've made a MOSFET H bridge circuit to drive model railway trains.
I'm using a 18M2+ to generate PWM pulses to drive the bridge transistors via 74 series logic chips. The form of the program is to perform some initial setup and then go into an infinite loop generating the PWM pulses.
The first circuit I built works OK, but then I built another, apparently identical, and it misbehaves. It runs for a short time (mostly less than a second) and then the program restarts.
I should add that it works fine when I use it to drive another small brushed DC motor, so maybe that points to something to do with the inevitable poor connection between model train wheels and track?
I've tried swapping PICAXE chips - no difference.
The only reason I know for the PICAXE to restart like this is loss of power, but I've looked at the 5V supply to pin 14 and it looks rock steady.
Has anybody any ideas for what can cause this behaviour?
I'm using a 18M2+ to generate PWM pulses to drive the bridge transistors via 74 series logic chips. The form of the program is to perform some initial setup and then go into an infinite loop generating the PWM pulses.
The first circuit I built works OK, but then I built another, apparently identical, and it misbehaves. It runs for a short time (mostly less than a second) and then the program restarts.
I should add that it works fine when I use it to drive another small brushed DC motor, so maybe that points to something to do with the inevitable poor connection between model train wheels and track?
I've tried swapping PICAXE chips - no difference.
The only reason I know for the PICAXE to restart like this is loss of power, but I've looked at the 5V supply to pin 14 and it looks rock steady.
Has anybody any ideas for what can cause this behaviour?