Переглянути джерело

Extend the idea of dummy temperature sensors.

Added a second sensor and made them configurable.
AnHardt 9 роки тому
джерело
коміт
c6d2ebe452
2 змінених файлів з 21 додано та 5 видалено
  1. 4
    1
      Marlin/Configuration.h
  2. 17
    4
      Marlin/thermistortables.h

+ 4
- 1
Marlin/Configuration.h Переглянути файл

@@ -118,7 +118,10 @@ Here are some standard links for getting your machine calibrated:
118 118
 // 1010 is Pt1000 with 1k pullup (non standard)
119 119
 // 147 is Pt100 with 4k7 pullup
120 120
 // 110 is Pt100 with 1k pullup (non standard)
121
-// 999 is a Dummy Table. It will ALWAYS read 25C.. Use it for Testing or Development purposes. NEVER for production machine.
121
+// 998 and 999 are Dummy Tables. They will ALWAYS read 25°C or the temperature defined below. 
122
+//     Use it for Testing or Development purposes. NEVER for production machine.
123
+//     #define DUMMY_THERMISTOR_998_VALUE 25
124
+//     #define DUMMY_THERMISTOR_999_VALUE 100
122 125
 
123 126
 #define TEMP_SENSOR_0 -1
124 127
 #define TEMP_SENSOR_1 -1

+ 17
- 4
Marlin/thermistortables.h Переглянути файл

@@ -1096,13 +1096,26 @@ const short temptable_1047[][2] PROGMEM = {
1096 1096
 #endif
1097 1097
 
1098 1098
 #if (THERMISTORHEATER_0 == 999) || (THERMISTORHEATER_1 == 999) || (THERMISTORHEATER_2 == 999) || (THERMISTORHEATER_3 == 999) || (THERMISTORBED == 999) //User defined table
1099
-// Dummy Thermistor table.. It will ALWAYS read 25C.
1100
-const short temptable_999[][2] PROGMEM = {
1101
-   {1*OVERSAMPLENR, 25},
1102
-   {1023*OVERSAMPLENR, 25}
1099
+  // Dummy Thermistor table.. It will ALWAYS read a fixed value.
1100
+  #ifndef DUMMY_THERMISTOR_999_VALUE
1101
+    #define DUMMY_THERMISTOR_999_VALUE 25
1102
+  #endif
1103
+  const short temptable_999[][2] PROGMEM = {
1104
+    {1*OVERSAMPLENR, DUMMY_THERMISTOR_999_VALUE},
1105
+    {1023*OVERSAMPLENR, DUMMY_THERMISTOR_999_VALUE}
1103 1106
 };
1104 1107
 #endif
1105 1108
 
1109
+#if (THERMISTORHEATER_0 == 998) || (THERMISTORHEATER_1 == 998) || (THERMISTORHEATER_2 == 998) || (THERMISTORHEATER_3 == 998) || (THERMISTORBED == 998) //User defined table
1110
+  // Dummy Thermistor table.. It will ALWAYS read a fixed value.
1111
+  #ifndef DUMMY_THERMISTOR_998_VALUE
1112
+    #define DUMMY_THERMISTOR_998_VALUE 25
1113
+  #endif
1114
+  const short temptable_998[][2] PROGMEM = {
1115
+    {1*OVERSAMPLENR, DUMMY_THERMISTOR_998_VALUE},
1116
+    {1023*OVERSAMPLENR, DUMMY_THERMISTOR_998_VALUE}
1117
+};
1118
+#endif
1106 1119
 
1107 1120
 
1108 1121
 #define _TT_NAME(_N) temptable_ ## _N

Завантаження…
Відмінити
Зберегти