My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

thermistortables.h 13KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410
  1. #ifndef THERMISTORTABLES_H_
  2. #define THERMISTORTABLES_H_
  3. #define OVERSAMPLENR 16
  4. #if (THERMISTORHEATER_0 == 1) || (THERMISTORHEATER_1 == 1) || (THERMISTORBED == 1) //100k bed thermistor
  5. #define NUMTEMPS_1 61
  6. const short temptable_1[NUMTEMPS_1][2] = {
  7. { 23*OVERSAMPLENR , 300 },
  8. { 25*OVERSAMPLENR , 295 },
  9. { 27*OVERSAMPLENR , 290 },
  10. { 28*OVERSAMPLENR , 285 },
  11. { 31*OVERSAMPLENR , 280 },
  12. { 33*OVERSAMPLENR , 275 },
  13. { 35*OVERSAMPLENR , 270 },
  14. { 38*OVERSAMPLENR , 265 },
  15. { 41*OVERSAMPLENR , 260 },
  16. { 44*OVERSAMPLENR , 255 },
  17. { 48*OVERSAMPLENR , 250 },
  18. { 52*OVERSAMPLENR , 245 },
  19. { 56*OVERSAMPLENR , 240 },
  20. { 61*OVERSAMPLENR , 235 },
  21. { 66*OVERSAMPLENR , 230 },
  22. { 71*OVERSAMPLENR , 225 },
  23. { 78*OVERSAMPLENR , 220 },
  24. { 84*OVERSAMPLENR , 215 },
  25. { 92*OVERSAMPLENR , 210 },
  26. { 100*OVERSAMPLENR , 205 },
  27. { 109*OVERSAMPLENR , 200 },
  28. { 120*OVERSAMPLENR , 195 },
  29. { 131*OVERSAMPLENR , 190 },
  30. { 143*OVERSAMPLENR , 185 },
  31. { 156*OVERSAMPLENR , 180 },
  32. { 171*OVERSAMPLENR , 175 },
  33. { 187*OVERSAMPLENR , 170 },
  34. { 205*OVERSAMPLENR , 165 },
  35. { 224*OVERSAMPLENR , 160 },
  36. { 245*OVERSAMPLENR , 155 },
  37. { 268*OVERSAMPLENR , 150 },
  38. { 293*OVERSAMPLENR , 145 },
  39. { 320*OVERSAMPLENR , 140 },
  40. { 348*OVERSAMPLENR , 135 },
  41. { 379*OVERSAMPLENR , 130 },
  42. { 411*OVERSAMPLENR , 125 },
  43. { 445*OVERSAMPLENR , 120 },
  44. { 480*OVERSAMPLENR , 115 },
  45. { 516*OVERSAMPLENR , 110 },
  46. { 553*OVERSAMPLENR , 105 },
  47. { 591*OVERSAMPLENR , 100 },
  48. { 628*OVERSAMPLENR , 95 },
  49. { 665*OVERSAMPLENR , 90 },
  50. { 702*OVERSAMPLENR , 85 },
  51. { 737*OVERSAMPLENR , 80 },
  52. { 770*OVERSAMPLENR , 75 },
  53. { 801*OVERSAMPLENR , 70 },
  54. { 830*OVERSAMPLENR , 65 },
  55. { 857*OVERSAMPLENR , 60 },
  56. { 881*OVERSAMPLENR , 55 },
  57. { 903*OVERSAMPLENR , 50 },
  58. { 922*OVERSAMPLENR , 45 },
  59. { 939*OVERSAMPLENR , 40 },
  60. { 954*OVERSAMPLENR , 35 },
  61. { 966*OVERSAMPLENR , 30 },
  62. { 977*OVERSAMPLENR , 25 },
  63. { 985*OVERSAMPLENR , 20 },
  64. { 993*OVERSAMPLENR , 15 },
  65. { 999*OVERSAMPLENR , 10 },
  66. { 1004*OVERSAMPLENR , 5 },
  67. { 1008*OVERSAMPLENR , 0 } //safety
  68. };
  69. #endif
  70. #if (THERMISTORHEATER_0 == 2) || (THERMISTORHEATER_1 == 2) || (THERMISTORBED == 2) //200k bed thermistor
  71. #define NUMTEMPS_2 21
  72. const short temptable_2[NUMTEMPS_2][2] = {
  73. {1*OVERSAMPLENR, 848},
  74. {54*OVERSAMPLENR, 275},
  75. {107*OVERSAMPLENR, 228},
  76. {160*OVERSAMPLENR, 202},
  77. {213*OVERSAMPLENR, 185},
  78. {266*OVERSAMPLENR, 171},
  79. {319*OVERSAMPLENR, 160},
  80. {372*OVERSAMPLENR, 150},
  81. {425*OVERSAMPLENR, 141},
  82. {478*OVERSAMPLENR, 133},
  83. {531*OVERSAMPLENR, 125},
  84. {584*OVERSAMPLENR, 118},
  85. {637*OVERSAMPLENR, 110},
  86. {690*OVERSAMPLENR, 103},
  87. {743*OVERSAMPLENR, 95},
  88. {796*OVERSAMPLENR, 86},
  89. {849*OVERSAMPLENR, 77},
  90. {902*OVERSAMPLENR, 65},
  91. {955*OVERSAMPLENR, 49},
  92. {1008*OVERSAMPLENR, 17},
  93. {1020*OVERSAMPLENR, 0} //safety
  94. };
  95. #endif
  96. #if (THERMISTORHEATER_0 == 3) || (THERMISTORHEATER_1 == 3) || (THERMISTORBED == 3) //mendel-parts
  97. #define NUMTEMPS_3 28
  98. const short temptable_3[NUMTEMPS_3][2] = {
  99. {1*OVERSAMPLENR,864},
  100. {21*OVERSAMPLENR,300},
  101. {25*OVERSAMPLENR,290},
  102. {29*OVERSAMPLENR,280},
  103. {33*OVERSAMPLENR,270},
  104. {39*OVERSAMPLENR,260},
  105. {46*OVERSAMPLENR,250},
  106. {54*OVERSAMPLENR,240},
  107. {64*OVERSAMPLENR,230},
  108. {75*OVERSAMPLENR,220},
  109. {90*OVERSAMPLENR,210},
  110. {107*OVERSAMPLENR,200},
  111. {128*OVERSAMPLENR,190},
  112. {154*OVERSAMPLENR,180},
  113. {184*OVERSAMPLENR,170},
  114. {221*OVERSAMPLENR,160},
  115. {265*OVERSAMPLENR,150},
  116. {316*OVERSAMPLENR,140},
  117. {375*OVERSAMPLENR,130},
  118. {441*OVERSAMPLENR,120},
  119. {513*OVERSAMPLENR,110},
  120. {588*OVERSAMPLENR,100},
  121. {734*OVERSAMPLENR,80},
  122. {856*OVERSAMPLENR,60},
  123. {938*OVERSAMPLENR,40},
  124. {986*OVERSAMPLENR,20},
  125. {1008*OVERSAMPLENR,0},
  126. {1018*OVERSAMPLENR,-20}
  127. };
  128. #endif
  129. #if (THERMISTORHEATER_0 == 4) || (THERMISTORHEATER_1 == 4) || (THERMISTORBED == 4) //10k thermistor
  130. #define NUMTEMPS_4 20
  131. short temptable_4[NUMTEMPS_4][2] = {
  132. {1*OVERSAMPLENR, 430},
  133. {54*OVERSAMPLENR, 137},
  134. {107*OVERSAMPLENR, 107},
  135. {160*OVERSAMPLENR, 91},
  136. {213*OVERSAMPLENR, 80},
  137. {266*OVERSAMPLENR, 71},
  138. {319*OVERSAMPLENR, 64},
  139. {372*OVERSAMPLENR, 57},
  140. {425*OVERSAMPLENR, 51},
  141. {478*OVERSAMPLENR, 46},
  142. {531*OVERSAMPLENR, 41},
  143. {584*OVERSAMPLENR, 35},
  144. {637*OVERSAMPLENR, 30},
  145. {690*OVERSAMPLENR, 25},
  146. {743*OVERSAMPLENR, 20},
  147. {796*OVERSAMPLENR, 14},
  148. {849*OVERSAMPLENR, 7},
  149. {902*OVERSAMPLENR, 0},
  150. {955*OVERSAMPLENR, -11},
  151. {1008*OVERSAMPLENR, -35}
  152. };
  153. #endif
  154. #if (THERMISTORHEATER_0 == 5) || (THERMISTORHEATER_1 == 5) || (THERMISTORBED == 5) //100k ParCan thermistor (104GT-2)
  155. #define NUMTEMPS_5 61
  156. const short temptable_5[NUMTEMPS_5][2] = {
  157. {1*OVERSAMPLENR, 713},
  158. {18*OVERSAMPLENR, 316},
  159. {35*OVERSAMPLENR, 266},
  160. {52*OVERSAMPLENR, 239},
  161. {69*OVERSAMPLENR, 221},
  162. {86*OVERSAMPLENR, 208},
  163. {103*OVERSAMPLENR, 197},
  164. {120*OVERSAMPLENR, 188},
  165. {137*OVERSAMPLENR, 181},
  166. {154*OVERSAMPLENR, 174},
  167. {171*OVERSAMPLENR, 169},
  168. {188*OVERSAMPLENR, 163},
  169. {205*OVERSAMPLENR, 159},
  170. {222*OVERSAMPLENR, 154},
  171. {239*OVERSAMPLENR, 150},
  172. {256*OVERSAMPLENR, 147},
  173. {273*OVERSAMPLENR, 143},
  174. {290*OVERSAMPLENR, 140},
  175. {307*OVERSAMPLENR, 136},
  176. {324*OVERSAMPLENR, 133},
  177. {341*OVERSAMPLENR, 130},
  178. {358*OVERSAMPLENR, 128},
  179. {375*OVERSAMPLENR, 125},
  180. {392*OVERSAMPLENR, 122},
  181. {409*OVERSAMPLENR, 120},
  182. {426*OVERSAMPLENR, 117},
  183. {443*OVERSAMPLENR, 115},
  184. {460*OVERSAMPLENR, 112},
  185. {477*OVERSAMPLENR, 110},
  186. {494*OVERSAMPLENR, 108},
  187. {511*OVERSAMPLENR, 106},
  188. {528*OVERSAMPLENR, 103},
  189. {545*OVERSAMPLENR, 101},
  190. {562*OVERSAMPLENR, 99},
  191. {579*OVERSAMPLENR, 97},
  192. {596*OVERSAMPLENR, 95},
  193. {613*OVERSAMPLENR, 92},
  194. {630*OVERSAMPLENR, 90},
  195. {647*OVERSAMPLENR, 88},
  196. {664*OVERSAMPLENR, 86},
  197. {681*OVERSAMPLENR, 84},
  198. {698*OVERSAMPLENR, 81},
  199. {715*OVERSAMPLENR, 79},
  200. {732*OVERSAMPLENR, 77},
  201. {749*OVERSAMPLENR, 75},
  202. {766*OVERSAMPLENR, 72},
  203. {783*OVERSAMPLENR, 70},
  204. {800*OVERSAMPLENR, 67},
  205. {817*OVERSAMPLENR, 64},
  206. {834*OVERSAMPLENR, 61},
  207. {851*OVERSAMPLENR, 58},
  208. {868*OVERSAMPLENR, 55},
  209. {885*OVERSAMPLENR, 52},
  210. {902*OVERSAMPLENR, 48},
  211. {919*OVERSAMPLENR, 44},
  212. {936*OVERSAMPLENR, 40},
  213. {953*OVERSAMPLENR, 34},
  214. {970*OVERSAMPLENR, 28},
  215. {987*OVERSAMPLENR, 20},
  216. {1004*OVERSAMPLENR, 8},
  217. {1021*OVERSAMPLENR, 0}
  218. };
  219. #endif
  220. #if (THERMISTORHEATER_0 == 6) || (THERMISTORHEATER_1 == 6) || (THERMISTORBED == 6) // 100k Epcos thermistor
  221. #define NUMTEMPS_6 36
  222. const short temptable_6[NUMTEMPS_6][2] = {
  223. {28*OVERSAMPLENR, 250},
  224. {31*OVERSAMPLENR, 245},
  225. {35*OVERSAMPLENR, 240},
  226. {39*OVERSAMPLENR, 235},
  227. {42*OVERSAMPLENR, 230},
  228. {44*OVERSAMPLENR, 225},
  229. {49*OVERSAMPLENR, 220},
  230. {53*OVERSAMPLENR, 215},
  231. {62*OVERSAMPLENR, 210},
  232. {73*OVERSAMPLENR, 205},
  233. {72*OVERSAMPLENR, 200},
  234. {94*OVERSAMPLENR, 190},
  235. {102*OVERSAMPLENR, 185},
  236. {116*OVERSAMPLENR, 170},
  237. {143*OVERSAMPLENR, 160},
  238. {183*OVERSAMPLENR, 150},
  239. {223*OVERSAMPLENR, 140},
  240. {270*OVERSAMPLENR, 130},
  241. {318*OVERSAMPLENR, 120},
  242. {383*OVERSAMPLENR, 110},
  243. {413*OVERSAMPLENR, 105},
  244. {439*OVERSAMPLENR, 100},
  245. {484*OVERSAMPLENR, 95},
  246. {513*OVERSAMPLENR, 90},
  247. {607*OVERSAMPLENR, 80},
  248. {664*OVERSAMPLENR, 70},
  249. {781*OVERSAMPLENR, 60},
  250. {810*OVERSAMPLENR, 55},
  251. {849*OVERSAMPLENR, 50},
  252. {914*OVERSAMPLENR, 45},
  253. {914*OVERSAMPLENR, 40},
  254. {935*OVERSAMPLENR, 35},
  255. {954*OVERSAMPLENR, 30},
  256. {970*OVERSAMPLENR, 25},
  257. {978*OVERSAMPLENR, 22},
  258. {1008*OVERSAMPLENR, 3}
  259. };
  260. #endif
  261. #if (THERMISTORHEATER_0 == 7) || (THERMISTORHEATER_1 == 7) || (THERMISTORBED == 7) // 100k Honeywell 135-104LAG-J01
  262. #define NUMTEMPS_7 54
  263. const short temptable_7[NUMTEMPS_7][2] = {
  264. {46*OVERSAMPLENR, 270},
  265. {50*OVERSAMPLENR, 265},
  266. {54*OVERSAMPLENR, 260},
  267. {58*OVERSAMPLENR, 255},
  268. {62*OVERSAMPLENR, 250},
  269. {67*OVERSAMPLENR, 245},
  270. {72*OVERSAMPLENR, 240},
  271. {79*OVERSAMPLENR, 235},
  272. {85*OVERSAMPLENR, 230},
  273. {91*OVERSAMPLENR, 225},
  274. {99*OVERSAMPLENR, 220},
  275. {107*OVERSAMPLENR, 215},
  276. {116*OVERSAMPLENR, 210},
  277. {126*OVERSAMPLENR, 205},
  278. {136*OVERSAMPLENR, 200},
  279. {149*OVERSAMPLENR, 195},
  280. {160*OVERSAMPLENR, 190},
  281. {175*OVERSAMPLENR, 185},
  282. {191*OVERSAMPLENR, 180},
  283. {209*OVERSAMPLENR, 175},
  284. {224*OVERSAMPLENR, 170},
  285. {246*OVERSAMPLENR, 165},
  286. {267*OVERSAMPLENR, 160},
  287. {293*OVERSAMPLENR, 155},
  288. {316*OVERSAMPLENR, 150},
  289. {340*OVERSAMPLENR, 145},
  290. {364*OVERSAMPLENR, 140},
  291. {396*OVERSAMPLENR, 135},
  292. {425*OVERSAMPLENR, 130},
  293. {460*OVERSAMPLENR, 125},
  294. {489*OVERSAMPLENR, 120},
  295. {526*OVERSAMPLENR, 115},
  296. {558*OVERSAMPLENR, 110},
  297. {591*OVERSAMPLENR, 105},
  298. {628*OVERSAMPLENR, 100},
  299. {660*OVERSAMPLENR, 95},
  300. {696*OVERSAMPLENR, 90},
  301. {733*OVERSAMPLENR, 85},
  302. {761*OVERSAMPLENR, 80},
  303. {794*OVERSAMPLENR, 75},
  304. {819*OVERSAMPLENR, 70},
  305. {847*OVERSAMPLENR, 65},
  306. {870*OVERSAMPLENR, 60},
  307. {892*OVERSAMPLENR, 55},
  308. {911*OVERSAMPLENR, 50},
  309. {929*OVERSAMPLENR, 45},
  310. {944*OVERSAMPLENR, 40},
  311. {959*OVERSAMPLENR, 35},
  312. {971*OVERSAMPLENR, 30},
  313. {981*OVERSAMPLENR, 25},
  314. {989*OVERSAMPLENR, 20},
  315. {994*OVERSAMPLENR, 15},
  316. {1001*OVERSAMPLENR, 10},
  317. {1005*OVERSAMPLENR, 5}
  318. };
  319. #endif
  320. #if THERMISTORHEATER_0 == 1
  321. #define NUMTEMPS_HEATER_0 NUMTEMPS_1
  322. #define heater_0_temptable temptable_1
  323. #elif THERMISTORHEATER_0 == 2
  324. #define NUMTEMPS_HEATER_0 NUMTEMPS_2
  325. #define heater_0_temptable temptable_2
  326. #elif THERMISTORHEATER_0 == 3
  327. #define NUMTEMPS_HEATER_0 NUMTEMPS_3
  328. #define heater_0_temptable temptable_3
  329. #elif THERMISTORHEATER_0 == 4
  330. #define NUMTEMPS_HEATER_0 NUMTEMPS_4
  331. #define heater_0_temptable temptable_4
  332. #elif THERMISTORHEATER_0 == 5
  333. #define NUMTEMPS_HEATER_0 NUMTEMPS_5
  334. #define heater_0_temptable temptable_5
  335. #elif THERMISTORHEATER_0 == 6
  336. #define NUMTEMPS_HEATER_0 NUMTEMPS_6
  337. #define heater_0_temptable temptable_6
  338. #elif THERMISTORHEATER_0 == 7
  339. #define NUMTEMPS_HEATER_0 NUMTEMPS_7
  340. #define heater_0_temptable temptable_7
  341. #elif defined HEATER_0_USES_THERMISTOR
  342. #error No heater 0 thermistor table specified
  343. #endif
  344. #if THERMISTORHEATER_1 == 1
  345. #define NUMTEMPS_HEATER_1 NUMTEMPS_1
  346. #define heater_1_temptable temptable_1
  347. #elif THERMISTORHEATER_1 == 2
  348. #define NUMTEMPS_HEATER_1 NUMTEMPS_2
  349. #define heater_1_temptable temptable_2
  350. #elif THERMISTORHEATER_1 == 3
  351. #define NUMTEMPS_HEATER_1 NUMTEMPS_3
  352. #define heater_1_temptable temptable_3
  353. #elif THERMISTORHEATER_1 == 4
  354. #define NUMTEMPS_HEATER_1 NUMTEMPS_4
  355. #define heater_1_temptable temptable_4
  356. #elif THERMISTORHEATER_1 == 5
  357. #define NUMTEMPS_HEATER_1 NUMTEMPS_5
  358. #define heater_1_temptable temptable_5
  359. #elif THERMISTORHEATER_1 == 6
  360. #define NUMTEMPS_HEATER_1 NUMTEMPS_6
  361. #define heater_1_temptable temptable_6
  362. #elif THERMISTORHEATER_1 == 7
  363. #define NUMTEMPS_HEATER_1 NUMTEMPS_7
  364. #define heater_1_temptable temptable_7
  365. #elif defined HEATER_1_USES_THERMISTOR
  366. #error No heater 1 thermistor table specified
  367. #endif
  368. #if THERMISTORBED == 1
  369. #define BNUMTEMPS NUMTEMPS_1
  370. #define bedtemptable temptable_1
  371. #elif THERMISTORBED == 2
  372. #define BNUMTEMPS NUMTEMPS_2
  373. #define bedtemptable temptable_2
  374. #elif THERMISTORBED == 3
  375. #define BNUMTEMPS NUMTEMPS_3
  376. #define bedtemptable temptable_3
  377. #elif THERMISTORBED == 4
  378. #define BNUMTEMPS NUMTEMPS_4
  379. #define bedtemptable temptable_4
  380. #elif THERMISTORBED == 5
  381. #define BNUMTEMPS NUMTEMPS_5
  382. #define bedtemptable temptable_5
  383. #elif THERMISTORBED == 6
  384. #define BNUMTEMPS NUMTEMPS_6
  385. #define bedtemptable temptable_6
  386. #elif THERMISTORBED == 7
  387. #define BNUMTEMPS NUMTEMPS_7
  388. #define bedtemptable temptable_7
  389. #elif defined BED_USES_THERMISTOR
  390. #error No bed thermistor table specified
  391. #endif
  392. #endif //THERMISTORTABLES_H_