I have a weird problem that started the last time I was using my DIY CNC. I have a raspberry Pi controlled machine and a PWM to analog 0-10v gizmo. Last night at the workshop the spindle didn't completely shut down when I sent M3S0. Then about an hour later it did't even slow down, instead it is blasting at 18000 rpm untill I shut down the enable switch.

I suspected my DIY pwm to analog circuit has failed, but no. It still deliveres what it shoud, 0-10 volts.

I didn't touch the electronics when this started, just used the machine normally through BCNC.

Any ideas where to look for the problem?