From 3161740df9b952f627fd9ad1e132e7eaf723fc0e Mon Sep 17 00:00:00 2001 From: Nutz95 Date: Sun, 13 Apr 2014 17:03:20 +0200 Subject: [PATCH 1/2] This table is made for thermistor 3950 (can be found on ebay for cheap) it's caracteristics are : MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit R25℃ ;100KΩ±1% B Value(R25/50℃):3990K 1% Dissipation Factor(mW/℃):1.1~1.6 In still Air Thermal Time Constant(S):10~17 In Still Air Operating temperature range: (-50~+260°C) Dimension: 1.8mm Dia X4.1mm Lead Length :30mm This table was found on the following blogs: http://cae2100.wordpress.com/2014/03/08/beta3950-thermistor-table-for-marlin/ and http://microfabricator.com/articles/view/id/531ad7e59aad9d3131000000/beta-3950-thermistor-table-for-marlin --- Marlin/Configuration.h | 1 + Marlin/thermistortables.h | 198 ++++++++++++++++++++++++-------------- 2 files changed, 127 insertions(+), 72 deletions(-) diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h index 32ce5b7db..f169f8e41 100644 --- a/Marlin/Configuration.h +++ b/Marlin/Configuration.h @@ -115,6 +115,7 @@ // 8 is 100k 0603 SMD Vishay NTCS0603E3104FXT (4.7k pullup) // 9 is 100k GE Sensing AL03006-58.2K-97-G1 (4.7k pullup) // 10 is 100k RS thermistor 198-961 (4.7k pullup) +// 11 is 100k beta 3950 1% thermistor (4.7k pullup) // 20 is the PT100 circuit found in the Ultimainboard V2.x // 60 is 100k Maker's Tool Works Kapton Bed Thermistor beta=3950 // diff --git a/Marlin/thermistortables.h b/Marlin/thermistortables.h index 6120923f1..db8359ef7 100644 --- a/Marlin/thermistortables.h +++ b/Marlin/thermistortables.h @@ -563,78 +563,132 @@ const short temptable_10[][2] PROGMEM = { {1016*OVERSAMPLENR, 0} }; #endif - -#if (THERMISTORHEATER_0 == 20) || (THERMISTORHEATER_1 == 20) || (THERMISTORHEATER_2 == 20) || (THERMISTORBED == 20) // PT100 with INA826 amp on Ultimaker v2.0 electronics -/* The PT100 in the Ultimaker v2.0 electronics has a high sample value for a high temperature. -This does not match the normal thermistor behaviour so we need to set the following defines */ -#if (THERMISTORHEATER_0 == 20) -# define HEATER_0_RAW_HI_TEMP 16383 -# define HEATER_0_RAW_LO_TEMP 0 -#endif -#if (THERMISTORHEATER_1 == 20) -# define HEATER_1_RAW_HI_TEMP 16383 -# define HEATER_1_RAW_LO_TEMP 0 -#endif -#if (THERMISTORHEATER_2 == 20) -# define HEATER_2_RAW_HI_TEMP 16383 -# define HEATER_2_RAW_LO_TEMP 0 -#endif -#if (THERMISTORBED == 20) -# define HEATER_BED_RAW_HI_TEMP 16383 -# define HEATER_BED_RAW_LO_TEMP 0 -#endif -const short temptable_20[][2] PROGMEM = { -{ 0*OVERSAMPLENR , 0 }, -{ 227*OVERSAMPLENR , 1 }, -{ 236*OVERSAMPLENR , 10 }, -{ 245*OVERSAMPLENR , 20 }, -{ 253*OVERSAMPLENR , 30 }, -{ 262*OVERSAMPLENR , 40 }, -{ 270*OVERSAMPLENR , 50 }, -{ 279*OVERSAMPLENR , 60 }, -{ 287*OVERSAMPLENR , 70 }, -{ 295*OVERSAMPLENR , 80 }, -{ 304*OVERSAMPLENR , 90 }, -{ 312*OVERSAMPLENR , 100 }, -{ 320*OVERSAMPLENR , 110 }, -{ 329*OVERSAMPLENR , 120 }, -{ 337*OVERSAMPLENR , 130 }, -{ 345*OVERSAMPLENR , 140 }, -{ 353*OVERSAMPLENR , 150 }, -{ 361*OVERSAMPLENR , 160 }, -{ 369*OVERSAMPLENR , 170 }, -{ 377*OVERSAMPLENR , 180 }, -{ 385*OVERSAMPLENR , 190 }, -{ 393*OVERSAMPLENR , 200 }, -{ 401*OVERSAMPLENR , 210 }, -{ 409*OVERSAMPLENR , 220 }, -{ 417*OVERSAMPLENR , 230 }, -{ 424*OVERSAMPLENR , 240 }, -{ 432*OVERSAMPLENR , 250 }, -{ 440*OVERSAMPLENR , 260 }, -{ 447*OVERSAMPLENR , 270 }, -{ 455*OVERSAMPLENR , 280 }, -{ 463*OVERSAMPLENR , 290 }, -{ 470*OVERSAMPLENR , 300 }, -{ 478*OVERSAMPLENR , 310 }, -{ 485*OVERSAMPLENR , 320 }, -{ 493*OVERSAMPLENR , 330 }, -{ 500*OVERSAMPLENR , 340 }, -{ 507*OVERSAMPLENR , 350 }, -{ 515*OVERSAMPLENR , 360 }, -{ 522*OVERSAMPLENR , 370 }, -{ 529*OVERSAMPLENR , 380 }, -{ 537*OVERSAMPLENR , 390 }, -{ 544*OVERSAMPLENR , 400 }, -{ 614*OVERSAMPLENR , 500 }, -{ 681*OVERSAMPLENR , 600 }, -{ 744*OVERSAMPLENR , 700 }, -{ 805*OVERSAMPLENR , 800 }, -{ 862*OVERSAMPLENR , 900 }, -{ 917*OVERSAMPLENR , 1000 }, -{ 968*OVERSAMPLENR , 1100 } -}; -#endif +#if (THERMISTORHEATER_0 == 11) || (THERMISTORHEATER_1 == 11) || (THERMISTORHEATER_2 == 11) || (THERMISTORBED == 11) // QU-BD silicone bed QWG-104F-3950 thermistor +const short temptable_8[][2] PROGMEM = { + {1*OVERSAMPLENR, 938}, + {31*OVERSAMPLENR, 314}, + {41*OVERSAMPLENR, 290}, + {51*OVERSAMPLENR, 272}, + {61*OVERSAMPLENR, 258}, + {71*OVERSAMPLENR, 247}, + {81*OVERSAMPLENR, 237}, + {91*OVERSAMPLENR, 229}, + {101*OVERSAMPLENR, 221}, + {111*OVERSAMPLENR, 215}, + {121*OVERSAMPLENR, 209}, + {131*OVERSAMPLENR, 204}, + {141*OVERSAMPLENR, 199}, + {151*OVERSAMPLENR, 195}, + {161*OVERSAMPLENR, 190}, + {171*OVERSAMPLENR, 187}, + {181*OVERSAMPLENR, 183}, + {191*OVERSAMPLENR, 179}, + {201*OVERSAMPLENR, 176}, + {221*OVERSAMPLENR, 170}, + {241*OVERSAMPLENR, 165}, + {261*OVERSAMPLENR, 160}, + {281*OVERSAMPLENR, 155}, + {301*OVERSAMPLENR, 150}, + {331*OVERSAMPLENR, 144}, + {361*OVERSAMPLENR, 139}, + {391*OVERSAMPLENR, 133}, + {421*OVERSAMPLENR, 128}, + {451*OVERSAMPLENR, 123}, + {491*OVERSAMPLENR, 117}, + {531*OVERSAMPLENR, 111}, + {571*OVERSAMPLENR, 105}, + {611*OVERSAMPLENR, 100}, + {641*OVERSAMPLENR, 95}, + {681*OVERSAMPLENR, 90}, + {711*OVERSAMPLENR, 85}, + {751*OVERSAMPLENR, 79}, + {791*OVERSAMPLENR, 72}, + {811*OVERSAMPLENR, 69}, + {831*OVERSAMPLENR, 65}, + {871*OVERSAMPLENR, 57}, + {881*OVERSAMPLENR, 55}, + {901*OVERSAMPLENR, 51}, + {921*OVERSAMPLENR, 45}, + {941*OVERSAMPLENR, 39}, + {971*OVERSAMPLENR, 28}, + {981*OVERSAMPLENR, 23}, + {991*OVERSAMPLENR, 17}, + {1001*OVERSAMPLENR, 9}, + {1021*OVERSAMPLENR, -27} +}; +#endif + +#if (THERMISTORHEATER_0 == 20) || (THERMISTORHEATER_1 == 20) || (THERMISTORHEATER_2 == 20) || (THERMISTORBED == 20) // PT100 with INA826 amp on Ultimaker v2.0 electronics +/* The PT100 in the Ultimaker v2.0 electronics has a high sample value for a high temperature. +This does not match the normal thermistor behaviour so we need to set the following defines */ +#if (THERMISTORHEATER_0 == 20) +# define HEATER_0_RAW_HI_TEMP 16383 +# define HEATER_0_RAW_LO_TEMP 0 +#endif +#if (THERMISTORHEATER_1 == 20) +# define HEATER_1_RAW_HI_TEMP 16383 +# define HEATER_1_RAW_LO_TEMP 0 +#endif +#if (THERMISTORHEATER_2 == 20) +# define HEATER_2_RAW_HI_TEMP 16383 +# define HEATER_2_RAW_LO_TEMP 0 +#endif +#if (THERMISTORBED == 20) +# define HEATER_BED_RAW_HI_TEMP 16383 +# define HEATER_BED_RAW_LO_TEMP 0 +#endif +const short temptable_20[][2] PROGMEM = { +{ 0*OVERSAMPLENR , 0 }, +{ 227*OVERSAMPLENR , 1 }, +{ 236*OVERSAMPLENR , 10 }, +{ 245*OVERSAMPLENR , 20 }, +{ 253*OVERSAMPLENR , 30 }, +{ 262*OVERSAMPLENR , 40 }, +{ 270*OVERSAMPLENR , 50 }, +{ 279*OVERSAMPLENR , 60 }, +{ 287*OVERSAMPLENR , 70 }, +{ 295*OVERSAMPLENR , 80 }, +{ 304*OVERSAMPLENR , 90 }, +{ 312*OVERSAMPLENR , 100 }, +{ 320*OVERSAMPLENR , 110 }, +{ 329*OVERSAMPLENR , 120 }, +{ 337*OVERSAMPLENR , 130 }, +{ 345*OVERSAMPLENR , 140 }, +{ 353*OVERSAMPLENR , 150 }, +{ 361*OVERSAMPLENR , 160 }, +{ 369*OVERSAMPLENR , 170 }, +{ 377*OVERSAMPLENR , 180 }, +{ 385*OVERSAMPLENR , 190 }, +{ 393*OVERSAMPLENR , 200 }, +{ 401*OVERSAMPLENR , 210 }, +{ 409*OVERSAMPLENR , 220 }, +{ 417*OVERSAMPLENR , 230 }, +{ 424*OVERSAMPLENR , 240 }, +{ 432*OVERSAMPLENR , 250 }, +{ 440*OVERSAMPLENR , 260 }, +{ 447*OVERSAMPLENR , 270 }, +{ 455*OVERSAMPLENR , 280 }, +{ 463*OVERSAMPLENR , 290 }, +{ 470*OVERSAMPLENR , 300 }, +{ 478*OVERSAMPLENR , 310 }, +{ 485*OVERSAMPLENR , 320 }, +{ 493*OVERSAMPLENR , 330 }, +{ 500*OVERSAMPLENR , 340 }, +{ 507*OVERSAMPLENR , 350 }, +{ 515*OVERSAMPLENR , 360 }, +{ 522*OVERSAMPLENR , 370 }, +{ 529*OVERSAMPLENR , 380 }, +{ 537*OVERSAMPLENR , 390 }, +{ 544*OVERSAMPLENR , 400 }, +{ 614*OVERSAMPLENR , 500 }, +{ 681*OVERSAMPLENR , 600 }, +{ 744*OVERSAMPLENR , 700 }, +{ 805*OVERSAMPLENR , 800 }, +{ 862*OVERSAMPLENR , 900 }, +{ 917*OVERSAMPLENR , 1000 }, +{ 968*OVERSAMPLENR , 1100 } +}; +#endif #if (THERMISTORHEATER_0 == 51) || (THERMISTORHEATER_1 == 51) || (THERMISTORHEATER_2 == 51) || (THERMISTORBED == 51) // 100k EPCOS (WITH 1kohm RESISTOR FOR PULLUP, R9 ON SANGUINOLOLU! NOT FOR 4.7kohm PULLUP! THIS IS NOT NORMAL!) From ed6f4a71c5fc26dbcee7da77ae75fa357a2b71c5 Mon Sep 17 00:00:00 2001 From: Nutz95 Date: Sun, 13 Apr 2014 18:00:55 +0200 Subject: [PATCH 2/2] fix wrong temptable index --- Marlin/thermistortables.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Marlin/thermistortables.h b/Marlin/thermistortables.h index db8359ef7..0a80e77b6 100644 --- a/Marlin/thermistortables.h +++ b/Marlin/thermistortables.h @@ -563,8 +563,11 @@ const short temptable_10[][2] PROGMEM = { {1016*OVERSAMPLENR, 0} }; #endif -#if (THERMISTORHEATER_0 == 11) || (THERMISTORHEATER_1 == 11) || (THERMISTORHEATER_2 == 11) || (THERMISTORBED == 11) // QU-BD silicone bed QWG-104F-3950 thermistor -const short temptable_8[][2] PROGMEM = { + +#if (THERMISTORHEATER_0 == 11) || (THERMISTORHEATER_1 == 11) || (THERMISTORHEATER_2 == 11) || (THERMISTORBED == 11) +// QU-BD silicone bed QWG-104F-3950 thermistor + +const short temptable_11[][2] PROGMEM = { {1*OVERSAMPLENR, 938}, {31*OVERSAMPLENR, 314}, {41*OVERSAMPLENR, 290},