With timing fixed, I tried the power relay. It clicked — for a fraction of a second — then dropped, even though my code was holding the pin steady for a full 3-second test.
Then I remembered the arming circuit from Log 1. The relay's driver chain runs off a 1 µF capacitor that's AC-coupled to the MCU pin. A steady level charges it once through the coupling cap, and then it drains. To hold the relay you have to keep feeding it edges.
The fix is almost funny: toggle the arm pin every millisecond — a ~500 Hz charge pump — for the entire time the relay must stay closed. Do that and the capacitor stays topped up and the relay holds rock-solid. Stop toggling and it drops within a second. Which is, of course, exactly the safety behavior the original designers built in: a hung MCU can't hold mains power to the transformer.
While I was at it I made the trigger hold-to-fire: the button has to stay held for the whole weld cycle, and releasing it ends the cycle immediately. Combined with the door-switch interlock in the AC path, that's three independent things that all have to be true for current to flow.
wichers
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.