1

Topic: Can you PID tune a SSR controlled heat bed?

Just converted my SD2 to a SSR controlled heat bed.  I would like to PID tune it because I get a ~5-7 degree variance across the board, looks like a regular sawtooth wave.  I really don't think it's a major problem, but every small refinement helps a little.  I have read other places that because of the SSR you can't do this.  Is that so?

Thanx
Ski

Ender 3 Pro

2

Re: Can you PID tune a SSR controlled heat bed?

You can but it sounds more like you have bang-bang enabled in your firmware.  PID for bed heaters need to be changed through the firmware either way.  It isn't something you can change in EEPROM like for the Nozzle.  I would start by checking the in configuration.h first for bang-bang and then choose one of the heater options that more closely matches your set up.  The PID instructions are in that section.  I will dig up a screenshot.

Printit Industries Model 8.10 fully enclosed CoreXY, Chamber heat
3-SD3's & a Workbench all fully enclosed, RH-Slic3r Win7pro, E3D V6, Volcano & Cyclops Hot End
SSR/500W AC Heated Glass Bed, Linear bearings on SS rods. Direct Drive Y-axis, BulldogXL
Thanks to all for your contributions

3

Re: Can you PID tune a SSR controlled heat bed?

This section here is what you're looking for, the last line has the code you would use to test PID.



// Bed Temperature Control
// Select PID or bang-bang with PIDTEMPBED. If bang-bang, BED_LIMIT_SWITCHING will enable hysteresis
//
// Uncomment this to enable PID on the bed. It uses the same frequency PWM as the extruder.
// If your PID_dT above is the default, and correct for your hardware/configuration, that means 7.689Hz,
// which is fine for driving a square wave into a resistive load and does not significantly impact you FET heating.
// This also works fine on a Fotek SSR-10DA Solid State Relay into a 250W heater.
// If your configuration is significantly different than this and you don't understand the issues involved, you probably
// shouldn't use bed PID until someone else verifies your hardware works.
// If this is enabled, find your own PID constants below.
#define PIDTEMPBED
//
//#define BED_LIMIT_SWITCHING

// This sets the max power delivered to the bed, and replaces the HEATER_BED_DUTY_CYCLE_DIVIDER option.
// all forms of bed control obey this (PID, bang-bang, bang-bang with hysteresis)
// setting this to anything other than 255 enables a form of PWM to the bed just like HEATER_BED_DUTY_CYCLE_DIVIDER did,
// so you shouldn't use it unless you are OK with PWM on your bed.  (see the comment on enabling PIDTEMPBED)
#define MAX_BED_POWER 255 // limits duty cycle to bed; 255=full current

#ifdef PIDTEMPBED
//120v 500W silicone heater W/SSR (Bob's Bedheater)
//from pidautotune      
//    #define DEFAULT_bedKp 44.39
//    #define DEFAULT_bedKi 7.88
//    #define DEFAULT_bedKd 62.54
      
//120v 250W silicone heater into 4mm borosilicate (MendelMax 1.5+)
//from FOPDT model - kp=.39 Tp=405 Tdead=66, Tc set to 79.2, aggressive factor of .15 (vs .1, 1, 10)
//    #define  DEFAULT_bedKp 10.00
//    #define  DEFAULT_bedKi .023
//    #define  DEFAULT_bedKd 305.4

//120v 250W silicone heater into 4mm borosilicate (MendelMax 1.5+)
//from pidautotune
//    #define  DEFAULT_bedKp 97.1
//    #define  DEFAULT_bedKi 1.41
//    #define  DEFAULT_bedKd 1675.16
//Solidoodle3 Standard Bed //{SD Patch}
//from pidautotune //{SD Patch}
      #define  DEFAULT_bedKp 100.15 //{SD Patch}
      #define  DEFAULT_bedKi 7.65 //{SD Patch}
      #define  DEFAULT_bedKd 327.90 //{SD Patch}

//Replicator MK2B Heat Bed //{SD Patch}
//from pidautotune //{SD Patch}
//    #define  DEFAULT_bedKp 367.89 //{SD Patch}
//    #define  DEFAULT_bedKi 36.68 //{SD Patch}
//    #define  DEFAULT_bedKd 922.06 //{SD Patch}

//QU-BD Silicone Bed 200x200 Square //{SD Patch}
//from pidautotune //{SD Patch}
//    #define  DEFAULT_bedKp 304.87 //{SD Patch}
//    #define  DEFAULT_bedKi 47.49 //{SD Patch}
//    #define  DEFAULT_bedKd 489.67 //{SD Patch}


// FIND YOUR OWN: "M303 E-1 C8 S90" to run autotune on the bed at 90 degreesC for 8 cycles.
#endif // PIDTEMPBED
Printit Industries Model 8.10 fully enclosed CoreXY, Chamber heat
3-SD3's & a Workbench all fully enclosed, RH-Slic3r Win7pro, E3D V6, Volcano & Cyclops Hot End
SSR/500W AC Heated Glass Bed, Linear bearings on SS rods. Direct Drive Y-axis, BulldogXL
Thanks to all for your contributions

4

Re: Can you PID tune a SSR controlled heat bed?

Thanx
I will have to go digging around when I get a little time and look...

Thanx again. 

btw your SSR install drawing was worth it's weight in gold last weekend!

Ender 3 Pro