Heated bed PWM

I'd have thought this would come up more often, but I only saw an answer from an old version of the firmware, and I never took a control systems course which would probably make this a bit more obvious!


Anyhow, got a RADDS board on a DUE.  PWM Timer ISR comment says its called 3906x/sec, so I would guess the maximum PWM would be 3906 Hz, but I suspect theres another divider in there.  Old post said 15 Hz with some decimal places.  I bought a lovely 120VAC heater for my bed and just figured this would be common.  I'd like to run it in PID since it doesn't take a control systems class to know its better, and understand it tends to have some tighter oscillations (always going to have some though).  So I need an SSR.  If it is a low speed PWM like it was, as the post before I read said any standard 0 crossing SSR will handle it close enough and may just require some tuning to adjust for the 0 crossing, though its not likely even that is necessary.  If its well above the 60Hz mains in the US, I'd have to see about getting a proportional SSR, and those all take analog voltages so I'd need to know the PWM frequency to build a proper filter to convert to a DC Analog voltage!

Still trying to find it.figure it out, but I think I'm done for the night (2:00am).  Heres hoping theres an answer in the morning :)

Comments

  • Duh, ok, I am tired. Couldn't even focus my eyes tired, so I got ready for bed and figured it out. 256 widths (8 bits of modulation) and a 3906 timer...3906/256=~15.2. So all I need to do is confirm the timer code setting it up and verify its still 3906 as the comment indicates. Guessing it wasn't broke so it wasn't "fixed" and therefore still the same frequency...ordered a regular 0 crossing ssr. I have one but I'm not sure what it's input range is. It's for a standalone pid temp controller I used to have running a heat treating furnace :). I'll just chalk this one up to fatigue....or perhaps rubber duck debugging if I want to sound interesting :).
  • Yes, it is 3906 with 256 values resulting in 15 Hz in normal mode. There is also a delayed bang bang which even works for mechanical relays. There you can set the switching frequency to a second or 5. For a bed this is normally enough with long latencies.
Sign In or Register to comment.