Use celsius_t for temperature accessors
This commit is contained in:
parent
795253a9d5
commit
58cc4b7043
|
@ -205,7 +205,7 @@ typedef struct {
|
||||||
layer_height = MESH_TEST_LAYER_HEIGHT,
|
layer_height = MESH_TEST_LAYER_HEIGHT,
|
||||||
prime_length = PRIME_LENGTH;
|
prime_length = PRIME_LENGTH;
|
||||||
|
|
||||||
int16_t bed_temp = MESH_TEST_BED_TEMP,
|
celsius_t bed_temp = MESH_TEST_BED_TEMP,
|
||||||
hotend_temp = MESH_TEST_HOTEND_TEMP;
|
hotend_temp = MESH_TEST_HOTEND_TEMP;
|
||||||
|
|
||||||
float nozzle = MESH_TEST_NOZZLE_SIZE,
|
float nozzle = MESH_TEST_NOZZLE_SIZE,
|
||||||
|
|
|
@ -631,7 +631,7 @@ class Temperature {
|
||||||
//inline so that there is no performance decrease.
|
//inline so that there is no performance decrease.
|
||||||
//deg=degreeCelsius
|
//deg=degreeCelsius
|
||||||
|
|
||||||
FORCE_INLINE static float degHotend(const uint8_t E_NAME) {
|
FORCE_INLINE static celsius_t degHotend(const uint8_t E_NAME) {
|
||||||
return TERN0(HAS_HOTEND, temp_hotend[HOTEND_INDEX].celsius);
|
return TERN0(HAS_HOTEND, temp_hotend[HOTEND_INDEX].celsius);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -736,7 +736,7 @@ class Temperature {
|
||||||
#if ENABLED(SHOW_TEMP_ADC_VALUES)
|
#if ENABLED(SHOW_TEMP_ADC_VALUES)
|
||||||
FORCE_INLINE static int16_t rawProbeTemp() { return temp_probe.raw; }
|
FORCE_INLINE static int16_t rawProbeTemp() { return temp_probe.raw; }
|
||||||
#endif
|
#endif
|
||||||
FORCE_INLINE static float degProbe() { return temp_probe.celsius; }
|
FORCE_INLINE static celsius_t degProbe() { return temp_probe.celsius; }
|
||||||
FORCE_INLINE static bool isProbeBelowTemp(const_float_t target_temp) { return temp_probe.celsius < target_temp; }
|
FORCE_INLINE static bool isProbeBelowTemp(const_float_t target_temp) { return temp_probe.celsius < target_temp; }
|
||||||
FORCE_INLINE static bool isProbeAboveTemp(const_float_t target_temp) { return temp_probe.celsius > target_temp; }
|
FORCE_INLINE static bool isProbeAboveTemp(const_float_t target_temp) { return temp_probe.celsius > target_temp; }
|
||||||
static bool wait_for_probe(const_float_t target_temp, bool no_wait_for_cooling=true);
|
static bool wait_for_probe(const_float_t target_temp, bool no_wait_for_cooling=true);
|
||||||
|
@ -752,7 +752,7 @@ class Temperature {
|
||||||
#if ENABLED(SHOW_TEMP_ADC_VALUES)
|
#if ENABLED(SHOW_TEMP_ADC_VALUES)
|
||||||
FORCE_INLINE static int16_t rawChamberTemp() { return temp_chamber.raw; }
|
FORCE_INLINE static int16_t rawChamberTemp() { return temp_chamber.raw; }
|
||||||
#endif
|
#endif
|
||||||
FORCE_INLINE static float degChamber() { return temp_chamber.celsius; }
|
FORCE_INLINE static celsius_t degChamber() { return temp_chamber.celsius; }
|
||||||
#if HAS_HEATED_CHAMBER
|
#if HAS_HEATED_CHAMBER
|
||||||
FORCE_INLINE static celsius_t degTargetChamber() { return temp_chamber.target; }
|
FORCE_INLINE static celsius_t degTargetChamber() { return temp_chamber.target; }
|
||||||
FORCE_INLINE static bool isHeatingChamber() { return temp_chamber.target > temp_chamber.celsius; }
|
FORCE_INLINE static bool isHeatingChamber() { return temp_chamber.target > temp_chamber.celsius; }
|
||||||
|
@ -778,7 +778,7 @@ class Temperature {
|
||||||
#if ENABLED(SHOW_TEMP_ADC_VALUES)
|
#if ENABLED(SHOW_TEMP_ADC_VALUES)
|
||||||
FORCE_INLINE static int16_t rawCoolerTemp() { return temp_cooler.raw; }
|
FORCE_INLINE static int16_t rawCoolerTemp() { return temp_cooler.raw; }
|
||||||
#endif
|
#endif
|
||||||
FORCE_INLINE static float degCooler() { return temp_cooler.celsius; }
|
FORCE_INLINE static celsius_t degCooler() { return temp_cooler.celsius; }
|
||||||
#if HAS_COOLER
|
#if HAS_COOLER
|
||||||
FORCE_INLINE static celsius_t degTargetCooler() { return temp_cooler.target; }
|
FORCE_INLINE static celsius_t degTargetCooler() { return temp_cooler.target; }
|
||||||
FORCE_INLINE static bool isLaserHeating() { return temp_cooler.target > temp_cooler.celsius; }
|
FORCE_INLINE static bool isLaserHeating() { return temp_cooler.target > temp_cooler.celsius; }
|
||||||
|
|
Loading…
Reference in a new issue