Hey all!
I'm working on a circuit that uses an MSP430F5529 microcontroller to control a stepper motor and 4x 40W fluorescent lamps. Here's a link to my circuit schematic.
https://drive.google.com/file/d/1XfEEVYC24WPUxfFD6geXqGXVXRaZSKL3/view?usp=sharing
I am using I2C to control a 16x2 LCD, a TB6600 stepper driver for the stepper motor, and then GPIO-controlled optoisolator(MOC3041)/triac (BT136) combo to supply power from an electronic ballast to the set of lamps. The I2C lines and push button are on 3 ft wires because my application requires it. I have an audio player on the device too (with button controls, also on 3ft wire), but I've had it disconnected for troubleshooting. I have a AC/DC adapter supplying 12V to my stepper driver, and a 12V-5V converter to power my uController.
The device goes between an idle state (motor and lamps off) and then a run state (motor and lamps are on) from a push button. My issue is when I press the button to go into its run state and the stepper/lamps come on, after a few seconds, sometimes immediate, it switches to idle state without button press (as if the button was pressed). This happens about half the time, and works just fine the other times. When the lamps are disconnected (motor still connected), the circuit works 100% of the time. The issue still occurs when lamps are connected and motor is disconnected.
My current guess is that in-rush current or noise on the line from the lamps is causing my button to trip. When the fail happens, I can see on my scope that the I2C signal is sent, so I'm guessing something is making the uC send the signal. I figured there was EMI getting picked up by my button or its wires, but I don't see anything weird when I probe the button output. Am I neglecting any decoupling caps anywhere? Playing with the capacitors of the triac snubber changes the frequency/speed at which it fails, does the capacitor type I use matter? What about troubleshooting on the triac, any suggestion for how to determine if it's operating correctly?
Any help would be appreciated!
I'm working on a circuit that uses an MSP430F5529 microcontroller to control a stepper motor and 4x 40W fluorescent lamps. Here's a link to my circuit schematic.
https://drive.google.com/file/d/1XfEEVYC24WPUxfFD6geXqGXVXRaZSKL3/view?usp=sharing
I am using I2C to control a 16x2 LCD, a TB6600 stepper driver for the stepper motor, and then GPIO-controlled optoisolator(MOC3041)/triac (BT136) combo to supply power from an electronic ballast to the set of lamps. The I2C lines and push button are on 3 ft wires because my application requires it. I have an audio player on the device too (with button controls, also on 3ft wire), but I've had it disconnected for troubleshooting. I have a AC/DC adapter supplying 12V to my stepper driver, and a 12V-5V converter to power my uController.
The device goes between an idle state (motor and lamps off) and then a run state (motor and lamps are on) from a push button. My issue is when I press the button to go into its run state and the stepper/lamps come on, after a few seconds, sometimes immediate, it switches to idle state without button press (as if the button was pressed). This happens about half the time, and works just fine the other times. When the lamps are disconnected (motor still connected), the circuit works 100% of the time. The issue still occurs when lamps are connected and motor is disconnected.
My current guess is that in-rush current or noise on the line from the lamps is causing my button to trip. When the fail happens, I can see on my scope that the I2C signal is sent, so I'm guessing something is making the uC send the signal. I figured there was EMI getting picked up by my button or its wires, but I don't see anything weird when I probe the button output. Am I neglecting any decoupling caps anywhere? Playing with the capacitors of the triac snubber changes the frequency/speed at which it fails, does the capacitor type I use matter? What about troubleshooting on the triac, any suggestion for how to determine if it's operating correctly?
Any help would be appreciated!