Browse Source

Add comments to lcd_control_temperature_menu

pull/1/head
Scott Lahteine 10 years ago
parent
commit
fcfd99c1ae
  1. 47
      Marlin/ultralcd.cpp

47
Marlin/ultralcd.cpp

@ -7,12 +7,11 @@
#include "stepper.h" #include "stepper.h"
#include "configuration_store.h" #include "configuration_store.h"
int8_t encoderDiff; /* encoderDiff is updated from interrupt context and added to encoderPosition every LCD update */ int8_t encoderDiff; // updated from interrupt context and added to encoderPosition every LCD update
bool encoderRateMultiplierEnabled; bool encoderRateMultiplierEnabled;
int32_t lastEncoderMovementMillis; int32_t lastEncoderMovementMillis;
/* Configuration settings */
int plaPreheatHotendTemp; int plaPreheatHotendTemp;
int plaPreheatHPBTemp; int plaPreheatHPBTemp;
int plaPreheatFanSpeed; int plaPreheatFanSpeed;
@ -25,9 +24,7 @@ int absPreheatFanSpeed;
millis_t previous_lcd_status_ms = 0; millis_t previous_lcd_status_ms = 0;
#endif #endif
/* !Configuration settings */ // Function pointer to menu functions.
//Function pointer to menu functions.
typedef void (*menuFunc_t)(); typedef void (*menuFunc_t)();
uint8_t lcd_status_message_level; uint8_t lcd_status_message_level;
@ -875,10 +872,17 @@ static void lcd_control_menu() {
* "Control" > "Temperature" submenu * "Control" > "Temperature" submenu
* *
*/ */
static void lcd_control_temperature_menu() { static void lcd_control_temperature_menu() {
START_MENU(); START_MENU();
//
// ^ Control
//
MENU_ITEM(back, MSG_CONTROL, lcd_control_menu); MENU_ITEM(back, MSG_CONTROL, lcd_control_menu);
//
// Nozzle, Nozzle 2, Nozzle 3, Nozzle 4
//
#if TEMP_SENSOR_0 != 0 #if TEMP_SENSOR_0 != 0
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_NOZZLE, &target_temperature[0], 0, HEATER_0_MAXTEMP - 15); MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_NOZZLE, &target_temperature[0], 0, HEATER_0_MAXTEMP - 15);
#endif #endif
@ -897,16 +901,32 @@ static void lcd_control_temperature_menu() {
#endif // EXTRUDERS > 3 #endif // EXTRUDERS > 3
#endif // EXTRUDERS > 2 #endif // EXTRUDERS > 2
#endif // EXTRUDERS > 1 #endif // EXTRUDERS > 1
//
// Bed
//
#if TEMP_SENSOR_BED != 0 #if TEMP_SENSOR_BED != 0
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_BED, &target_temperature_bed, 0, BED_MAXTEMP - 15); MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_BED, &target_temperature_bed, 0, BED_MAXTEMP - 15);
#endif #endif
//
// Fan Speed
//
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED, &fanSpeed, 0, 255); MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED, &fanSpeed, 0, 255);
//
// Autotemp, Min, Max, Fact
//
#if defined(AUTOTEMP) && (TEMP_SENSOR_0 != 0) #if defined(AUTOTEMP) && (TEMP_SENSOR_0 != 0)
MENU_ITEM_EDIT(bool, MSG_AUTOTEMP, &autotemp_enabled); MENU_ITEM_EDIT(bool, MSG_AUTOTEMP, &autotemp_enabled);
MENU_ITEM_EDIT(float3, MSG_MIN, &autotemp_min, 0, HEATER_0_MAXTEMP - 15); MENU_ITEM_EDIT(float3, MSG_MIN, &autotemp_min, 0, HEATER_0_MAXTEMP - 15);
MENU_ITEM_EDIT(float3, MSG_MAX, &autotemp_max, 0, HEATER_0_MAXTEMP - 15); MENU_ITEM_EDIT(float3, MSG_MAX, &autotemp_max, 0, HEATER_0_MAXTEMP - 15);
MENU_ITEM_EDIT(float32, MSG_FACTOR, &autotemp_factor, 0.0, 1.0); MENU_ITEM_EDIT(float32, MSG_FACTOR, &autotemp_factor, 0.0, 1.0);
#endif #endif
//
// PID-P, PID-I, PID-D, PID-C
//
#ifdef PIDTEMP #ifdef PIDTEMP
// set up temp variables - undo the default scaling // set up temp variables - undo the default scaling
raw_Ki = unscalePID_i(PID_PARAM(Ki,0)); raw_Ki = unscalePID_i(PID_PARAM(Ki,0));
@ -959,7 +979,15 @@ static void lcd_control_temperature_menu() {
#endif//EXTRUDERS > 1 #endif//EXTRUDERS > 1
#endif //PID_PARAMS_PER_EXTRUDER #endif //PID_PARAMS_PER_EXTRUDER
#endif//PIDTEMP #endif//PIDTEMP
//
// Preheat PLA conf
//
MENU_ITEM(submenu, MSG_PREHEAT_PLA_SETTINGS, lcd_control_temperature_preheat_pla_settings_menu); MENU_ITEM(submenu, MSG_PREHEAT_PLA_SETTINGS, lcd_control_temperature_preheat_pla_settings_menu);
//
// Preheat ABS conf
//
MENU_ITEM(submenu, MSG_PREHEAT_ABS_SETTINGS, lcd_control_temperature_preheat_abs_settings_menu); MENU_ITEM(submenu, MSG_PREHEAT_ABS_SETTINGS, lcd_control_temperature_preheat_abs_settings_menu);
END_MENU(); END_MENU();
} }
@ -969,7 +997,6 @@ static void lcd_control_temperature_menu() {
* "Temperature" > "Preheat PLA conf" submenu * "Temperature" > "Preheat PLA conf" submenu
* *
*/ */
static void lcd_control_temperature_preheat_pla_settings_menu() { static void lcd_control_temperature_preheat_pla_settings_menu() {
START_MENU(); START_MENU();
MENU_ITEM(back, MSG_TEMPERATURE, lcd_control_temperature_menu); MENU_ITEM(back, MSG_TEMPERATURE, lcd_control_temperature_menu);
@ -991,7 +1018,6 @@ static void lcd_control_temperature_preheat_pla_settings_menu() {
* "Temperature" > "Preheat ABS conf" submenu * "Temperature" > "Preheat ABS conf" submenu
* *
*/ */
static void lcd_control_temperature_preheat_abs_settings_menu() { static void lcd_control_temperature_preheat_abs_settings_menu() {
START_MENU(); START_MENU();
MENU_ITEM(back, MSG_TEMPERATURE, lcd_control_temperature_menu); MENU_ITEM(back, MSG_TEMPERATURE, lcd_control_temperature_menu);
@ -1013,7 +1039,6 @@ static void lcd_control_temperature_preheat_abs_settings_menu() {
* "Control" > "Motion" submenu * "Control" > "Motion" submenu
* *
*/ */
static void lcd_control_motion_menu() { static void lcd_control_motion_menu() {
START_MENU(); START_MENU();
MENU_ITEM(back, MSG_CONTROL, lcd_control_menu); MENU_ITEM(back, MSG_CONTROL, lcd_control_menu);
@ -1055,7 +1080,6 @@ static void lcd_control_motion_menu() {
* "Control" > "Filament" submenu * "Control" > "Filament" submenu
* *
*/ */
static void lcd_control_volumetric_menu() { static void lcd_control_volumetric_menu() {
START_MENU(); START_MENU();
MENU_ITEM(back, MSG_CONTROL, lcd_control_menu); MENU_ITEM(back, MSG_CONTROL, lcd_control_menu);
@ -1083,7 +1107,6 @@ static void lcd_control_volumetric_menu() {
* "Control" > "Contrast" submenu * "Control" > "Contrast" submenu
* *
*/ */
#ifdef HAS_LCD_CONTRAST #ifdef HAS_LCD_CONTRAST
static void lcd_set_contrast() { static void lcd_set_contrast() {
if (encoderPosition != 0) { if (encoderPosition != 0) {
@ -1103,7 +1126,6 @@ static void lcd_control_volumetric_menu() {
* "Control" > "Retract" submenu * "Control" > "Retract" submenu
* *
*/ */
#ifdef FWRETRACT #ifdef FWRETRACT
static void lcd_control_retract_menu() { static void lcd_control_retract_menu() {
START_MENU(); START_MENU();
@ -1141,7 +1163,6 @@ static void lcd_sd_updir() {
* "Print from SD" submenu * "Print from SD" submenu
* *
*/ */
void lcd_sdcard_menu() { void lcd_sdcard_menu() {
if (lcdDrawUpdate == 0 && LCD_CLICKED == 0) return; // nothing to do (so don't thrash the SD card) if (lcdDrawUpdate == 0 && LCD_CLICKED == 0) return; // nothing to do (so don't thrash the SD card)
uint16_t fileCnt = card.getnrfilenames(); uint16_t fileCnt = card.getnrfilenames();

Loading…
Cancel
Save