1
0
mirror of https://github.com/MarlinFirmware/Marlin.git synced 2024-11-23 20:18:52 +00:00

Show ADC values inline rather than after

This commit is contained in:
Scott Lahteine 2016-07-28 16:02:54 -07:00
parent c677d2ac56
commit 74df828acc

View File

@ -4459,12 +4459,20 @@ inline void gcode_M104() {
SERIAL_PROTOCOL_F(thermalManager.degHotend(target_extruder), 1);
SERIAL_PROTOCOLPGM(" /");
SERIAL_PROTOCOL_F(thermalManager.degTargetHotend(target_extruder), 1);
#if ENABLED(SHOW_TEMP_ADC_VALUES)
SERIAL_PROTOCOLPAIR(" (", thermalManager.current_temperature_raw[target_extruder] / OVERSAMPLENR);
SERIAL_CHAR(')')
#endif
#endif
#if HAS_TEMP_BED
SERIAL_PROTOCOLPGM(" B:");
SERIAL_PROTOCOL_F(thermalManager.degBed(), 1);
SERIAL_PROTOCOLPGM(" /");
SERIAL_PROTOCOL_F(thermalManager.degTargetBed(), 1);
#if ENABLED(SHOW_TEMP_ADC_VALUES)
SERIAL_PROTOCOLPAIR(" (", thermalManager.current_temperature_bed_raw / OVERSAMPLENR);
SERIAL_CHAR(')')
#endif
#endif
#if HOTENDS > 1
HOTEND_LOOP() {
@ -4473,6 +4481,10 @@ inline void gcode_M104() {
SERIAL_PROTOCOL_F(thermalManager.degHotend(e), 1);
SERIAL_PROTOCOLPGM(" /");
SERIAL_PROTOCOL_F(thermalManager.degTargetHotend(e), 1);
#if ENABLED(SHOW_TEMP_ADC_VALUES)
SERIAL_PROTOCOLPAIR(" (", thermalManager.current_temperature_raw[e] / OVERSAMPLENR);
SERIAL_CHAR(')')
#endif
}
#endif
#if HAS_TEMP_BED
@ -4503,17 +4515,6 @@ inline void gcode_M104() {
#endif
}
#endif
#if ENABLED(SHOW_TEMP_ADC_VALUES)
#if HAS_TEMP_BED
SERIAL_PROTOCOLPAIR(" ADC B:", thermalManager.current_temperature_bed_raw / OVERSAMPLENR);
#endif
HOTEND_LOOP() {
SERIAL_PROTOCOLPAIR(" T", e);
SERIAL_PROTOCOLCHAR(':');
SERIAL_PROTOCOL(thermalManager.current_temperature_raw[e] / OVERSAMPLENR);
}
#endif
SERIAL_EOL;
}
#endif