Browse Source

Merge pull request #270 from PavelSindler/MK2

listing files reverted; M117 message during first layer cal. has language variants, pause print
PavelSindler 7 years ago
parent
commit
48f716a7c1

+ 3 - 5
Firmware/cardreader.cpp

@@ -126,11 +126,9 @@ void CardReader::lsDive(const char *prepend, SdFile parent, const char * const m
 			case LS_SerialPrint:
 				createFilename(filename, p);
 				SERIAL_PROTOCOL(prepend);
-				if (longFilename[0] != 0) {
-					SERIAL_PROTOCOL(longFilename);
-				} else {
-					SERIAL_PROTOCOL(filename);
-				}
+
+				SERIAL_PROTOCOL(filename);
+
 				MYSERIAL.write(' ');
 				SERIAL_PROTOCOLLN(p.fileSize);
 				break;

+ 15 - 0
Firmware/language_all.cpp

@@ -1645,6 +1645,21 @@ const char * const MSG_M115_REPORT_LANG_TABLE[1] PROGMEM = {
 	MSG_M115_REPORT_EN
 };
 
+const char MSG_M117_V2_CALIBRATION_EN[] PROGMEM = "M117 First layer cal.";
+const char MSG_M117_V2_CALIBRATION_CZ[] PROGMEM = "M117 Kal. prvni vrstvy";
+const char MSG_M117_V2_CALIBRATION_IT[] PROGMEM = "M117 Cal. primo layer.";
+const char MSG_M117_V2_CALIBRATION_ES[] PROGMEM = "M117 Cal. primera cap.";
+const char MSG_M117_V2_CALIBRATION_PL[] PROGMEM = "M117 Kal. 1. warstwy";
+const char MSG_M117_V2_CALIBRATION_DE[] PROGMEM = "M117 Erste-Schicht Kal.";
+const char * const MSG_M117_V2_CALIBRATION_LANG_TABLE[LANG_NUM] PROGMEM = {
+	MSG_M117_V2_CALIBRATION_EN,
+	MSG_M117_V2_CALIBRATION_CZ,
+	MSG_M117_V2_CALIBRATION_IT,
+	MSG_M117_V2_CALIBRATION_ES,
+	MSG_M117_V2_CALIBRATION_PL,
+	MSG_M117_V2_CALIBRATION_DE
+};
+
 const char MSG_M119_REPORT_EN[] PROGMEM = "Reporting endstop status";
 const char * const MSG_M119_REPORT_LANG_TABLE[1] PROGMEM = {
 	MSG_M119_REPORT_EN

+ 2 - 0
Firmware/language_all.h

@@ -310,6 +310,8 @@ extern const char* const MSG_M109_INVALID_EXTRUDER_LANG_TABLE[1];
 #define MSG_M109_INVALID_EXTRUDER LANG_TABLE_SELECT_EXPLICIT(MSG_M109_INVALID_EXTRUDER_LANG_TABLE, 0)
 extern const char* const MSG_M115_REPORT_LANG_TABLE[1];
 #define MSG_M115_REPORT LANG_TABLE_SELECT_EXPLICIT(MSG_M115_REPORT_LANG_TABLE, 0)
+extern const char* const MSG_M117_V2_CALIBRATION_LANG_TABLE[LANG_NUM];
+#define MSG_M117_V2_CALIBRATION LANG_TABLE_SELECT(MSG_M117_V2_CALIBRATION_LANG_TABLE)
 extern const char* const MSG_M119_REPORT_LANG_TABLE[1];
 #define MSG_M119_REPORT LANG_TABLE_SELECT_EXPLICIT(MSG_M119_REPORT_LANG_TABLE, 0)
 extern const char* const MSG_M200_INVALID_EXTRUDER_LANG_TABLE[1];

+ 2 - 1
Firmware/language_cz.h

@@ -340,4 +340,5 @@
 #define MSG_PLA_FILAMENT_LOADED				"Je PLA filament zaveden?"
 #define MSG_PLEASE_LOAD_PLA					"Nejdrive zavedte PLA filament prosim."
 #define MSG_FILE_CNT						"Nektere soubory nebudou setrideny. Maximalni pocet souboru pro setrideni je 100."
-#define MSG_WIZARD_HEATING					"Predehrivam trysku. Prosim cekejte."
+#define MSG_WIZARD_HEATING					"Predehrivam trysku. Prosim cekejte."
+#define MSG_M117_V2_CALIBRATION				"M117 Kal. prvni vrstvy"

+ 1 - 1
Firmware/language_de.h

@@ -354,4 +354,4 @@
 #define MSG_PLEASE_LOAD_PLA					"Bitte laden Sie zuerst PLA Filament."
 #define MSG_FILE_CNT						"Einige Dateien werden nicht sortiert. Max. Anzahl der Dateien in einem Ordner ist 100."
 #define MSG_WIZARD_HEATING					"Vorheizen der Duese. Bitte warten."
-
+#define MSG_M117_V2_CALIBRATION				"M117 Erste-Schicht Kal."

+ 1 - 0
Firmware/language_en.h

@@ -341,3 +341,4 @@
 #define(lenght=20, lines=2) MSG_PLA_FILAMENT_LOADED				"Is PLA filament loaded?"
 #define(lenght=20, lines=4) MSG_PLEASE_LOAD_PLA					"Please load PLA filament first."
 #define(length=20, lines=8) MSG_FILE_CNT						"Some files will not be sorted. Max. No. of files in 1 folder for sorting is 100."
+#define(length=25, lines=1) MSG_M117_V2_CALIBRATION				"M117 First layer cal."

+ 2 - 1
Firmware/language_es.h

@@ -334,4 +334,5 @@
 #define MSG_PLA_FILAMENT_LOADED				"Esta el filamento PLA cargado?"
 #define MSG_PLEASE_LOAD_PLA					"Carga el filamento PLA primero por favor."
 #define MSG_FILE_CNT						"Algunos archivos no seran ordenados. El Max. num. de archivos para ordenar en 1 carpeta es 100."
-#define MSG_WIZARD_HEATING					"Precalentando nozzle. Espera por favor."
+#define MSG_WIZARD_HEATING					"Precalentando nozzle. Espera por favor."
+#define MSG_M117_V2_CALIBRATION				"M117 Cal. primera cap."

+ 2 - 1
Firmware/language_it.h

@@ -325,4 +325,5 @@
 #define MSG_PLA_FILAMENT_LOADED				"Il PLA e stato caricato?"
 #define MSG_PLEASE_LOAD_PLA					"Per favore prima caricare filamento di PLA."
 #define MSG_FILE_CNT						"Alcuni dei file non potranno essere organizzati. 100 e il n. max. di file che possono essere organizzati."
-#define MSG_WIZARD_HEATING					"Sto preriscaldando l'ugello. Per favore attendi."
+#define MSG_WIZARD_HEATING					"Sto preriscaldando l'ugello. Per favore attendi."
+#define MSG_M117_V2_CALIBRATION				"M117 Cal. primo layer."

+ 2 - 1
Firmware/language_pl.h

@@ -337,4 +337,5 @@
 #define MSG_PLA_FILAMENT_LOADED				"Fialment PLA jest zaladowany?"
 #define MSG_PLEASE_LOAD_PLA					"Prosze, najpierw zaladuj filament PLA."
 #define MSG_FILE_CNT						"Niektore pliki nie beda sortowane. Max. ilosc plikow do sortu w 1 folderze to 100."
-#define MSG_WIZARD_HEATING					"Nagrzewanie dyszy. Prosze czekac."
+#define MSG_WIZARD_HEATING					"Nagrzewanie dyszy. Prosze czekac."
+#define MSG_M117_V2_CALIBRATION				"M117 Kal. 1. warstwy"

+ 11 - 6
Firmware/ultralcd.cpp

@@ -556,10 +556,15 @@ void lcd_commands()
 	if (lcd_commands_type == LCD_COMMAND_LONG_PAUSE)
 	{
 		if(lcd_commands_step == 0) {
-			card.pauseSDPrint();
-			lcd_setstatuspgm(MSG_FINISHING_MOVEMENTS);
-			lcdDrawUpdate = 3;
-			lcd_commands_step = 1;
+			if (card.sdprinting) {
+				card.pauseSDPrint();
+				lcd_setstatuspgm(MSG_FINISHING_MOVEMENTS);
+				lcdDrawUpdate = 3;
+				lcd_commands_step = 1;
+			}
+			else {
+				lcd_commands_type = 0;
+			}
 		}
 		if (lcd_commands_step == 1 && !blocks_queued()) {
 			lcd_setstatuspgm(MSG_PRINT_PAUSED);
@@ -652,7 +657,7 @@ void lcd_commands()
 			enquecommand_P(PSTR("M190 S55"));
 			enquecommand_P(PSTR("M109 S210"));
 			enquecommand_P(PSTR("T0"));
-			enquecommand_P(PSTR("M117 First layer cal."));
+			enquecommand_P(MSG_M117_V2_CALIBRATION);
 			enquecommand_P(PSTR("G87")); //sets calibration status
 			enquecommand_P(PSTR("G28"));
 			enquecommand_P(PSTR("G21")); //set units to millimeters
@@ -915,7 +920,7 @@ void lcd_commands()
 			enquecommand_P(PSTR("M140 S55"));
 			enquecommand_P(PSTR("M190 S55"));
 			enquecommand_P(PSTR("M109 S210"));
-			enquecommand_P(PSTR("M117 First layer cal."));
+			enquecommand_P(MSG_M117_V2_CALIBRATION);
 			enquecommand_P(PSTR("G87")); //sets calibration status
 			enquecommand_P(PSTR("G28"));
 			enquecommand_P(PSTR("G92 E0.0"));