Compare commits
	
		
			9 Commits
		
	
	
		
			v1.4.0
			...
			8a558c3121
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 8a558c3121 | |||
| 5afb60df32 | |||
| 3394e6eb01 | |||
| 3818c2c059 | |||
| 0afc543b5f | |||
| adee46e3fc | |||
| 1db74867e6 | |||
| 0f24a63d32 | |||
| 3640809502 | 
| @@ -9,6 +9,7 @@ Das System integriert sich nahtlos mit der [Spoolman](https://github.com/Donkie/ | |||||||
| Weitere Bilder finden Sie im [img Ordner](/img/) | Weitere Bilder finden Sie im [img Ordner](/img/) | ||||||
| oder auf meiner Website: [FilaMan Website](https://www.filaman.app)   | oder auf meiner Website: [FilaMan Website](https://www.filaman.app)   | ||||||
| Deutsches Erklärvideo: [Youtube](https://youtu.be/uNDe2wh9SS8?si=b-jYx4I1w62zaOHU)   | Deutsches Erklärvideo: [Youtube](https://youtu.be/uNDe2wh9SS8?si=b-jYx4I1w62zaOHU)   | ||||||
|  | Discord Server: [https://discord.gg/vMAx2gf5](https://discord.gg/vMAx2gf5) | ||||||
|  |  | ||||||
| ### Es gibt jetzt auch ein Wiki, dort sind nochmal alle Funktionen beschrieben: [Wiki](https://github.com/ManuelW77/Filaman/wiki) | ### Es gibt jetzt auch ein Wiki, dort sind nochmal alle Funktionen beschrieben: [Wiki](https://github.com/ManuelW77/Filaman/wiki) | ||||||
|  |  | ||||||
|   | |||||||
| @@ -6,12 +6,14 @@ FilaMan is a filament management system for 3D printing. It uses ESP32 hardware | |||||||
| Users can manage filament spools, monitor the status of the Automatic Material System (AMS) and make settings via a web interface.  | Users can manage filament spools, monitor the status of the Automatic Material System (AMS) and make settings via a web interface.  | ||||||
| The system integrates seamlessly with [Bambulab](https://bambulab.com/en-us) 3D printers and [Spoolman](https://github.com/Donkie/Spoolman) filament management as well as the [Openspool](https://github.com/spuder/OpenSpool) NFC-TAG format. | The system integrates seamlessly with [Bambulab](https://bambulab.com/en-us) 3D printers and [Spoolman](https://github.com/Donkie/Spoolman) filament management as well as the [Openspool](https://github.com/spuder/OpenSpool) NFC-TAG format. | ||||||
|  |  | ||||||
|  |  | ||||||
|  |  | ||||||
|  |  | ||||||
|  |  | ||||||
| More Images can be found in the [img Folder](/img/)   | More Images can be found in the [img Folder](/img/)   | ||||||
| or my website:[FilaMan Website](https://www.filaman.app)   | or my website: [FilaMan Website](https://www.filaman.app)   | ||||||
| german explanatory video: [Youtube](https://youtu.be/uNDe2wh9SS8?si=b-jYx4I1w62zaOHU)   | german explanatory video: [Youtube](https://youtu.be/uNDe2wh9SS8?si=b-jYx4I1w62zaOHU)   | ||||||
|  | Discord Server: [https://discord.gg/vMAx2gf5](https://discord.gg/vMAx2gf5) | ||||||
|  |  | ||||||
| ### Now more detailed informations about the usage: [Wiki](https://github.com/ManuelW77/Filaman/wiki) | ### Now more detailed informations about the usage: [Wiki](https://github.com/ManuelW77/Filaman/wiki) | ||||||
|  |  | ||||||
|   | |||||||
							
								
								
									
										15297
									
								
								_3D Print Files/FilaMan-Waage.step
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15297
									
								
								_3D Print Files/FilaMan-Waage.step
									
									
									
									
									
										Normal file
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								_3D Print Files/Filaman-Waage.f3z
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								_3D Print Files/Filaman-Waage.f3z
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| @@ -154,11 +154,11 @@ | |||||||
|                     <p>If activated, FilaMan will automatically update the next filled tray with the last scanned and weighed spool.</p> |                     <p>If activated, FilaMan will automatically update the next filled tray with the last scanned and weighed spool.</p> | ||||||
|                     <div class="input-group" style="display: flex; margin-bottom: 0;"> |                     <div class="input-group" style="display: flex; margin-bottom: 0;"> | ||||||
|                         <label for="autoSend" style="width: 250px; margin-right: 5px;">Auto Send to Bambu:</label> |                         <label for="autoSend" style="width: 250px; margin-right: 5px;">Auto Send to Bambu:</label> | ||||||
|                         <label for="autoSendTime" style="width: 250px; margin-right: 5px;">Wait time in Seconds:</label> |                         <label for="autoSendTime" style="width: 250px; margin-right: 5px;">Wait for Spool in Sec:</label> | ||||||
|                     </div> |                     </div> | ||||||
|                     <div class="input-group" style="display: flex;"> |                     <div class="input-group" style="display: flex;"> | ||||||
|                         <input type="checkbox" id="autoSend" {{autoSendToBambu}} style="width: 190px; margin-right: 10px;"> |                         <input type="checkbox" id="autoSend" {{autoSendToBambu}} style="width: 190px; margin-right: 10px;"> | ||||||
|                         <input type="text" id="autoSendTime" placeholder="Time to wait for new Spool" value="{{autoSendTime}}" style="width: 100px;"> |                         <input type="number" min="60" id="autoSendTime" placeholder="Time to wait" value="{{autoSendTime}}" style="width: 100px;"> | ||||||
|                     </div> |                     </div> | ||||||
|  |  | ||||||
|                     <button style="margin: 0;" onclick="saveBambuCredentials()">Save Bambu Credentials</button> |                     <button style="margin: 0;" onclick="saveBambuCredentials()">Save Bambu Credentials</button> | ||||||
|   | |||||||
| @@ -86,7 +86,7 @@ function populateVendorDropdown(data, selectedSmId = null) { | |||||||
|     }); |     }); | ||||||
|  |  | ||||||
|     // Nach der Schleife: Formatierung der Gesamtlänge |     // Nach der Schleife: Formatierung der Gesamtlänge | ||||||
|     console.log("Total Lenght: ", totalLength); |     console.log("Total Length: ", totalLength); | ||||||
|     const formattedLength = totalLength > 1000  |     const formattedLength = totalLength > 1000  | ||||||
|         ? (totalLength / 1000).toFixed(2) + " km"  |         ? (totalLength / 1000).toFixed(2) + " km"  | ||||||
|         : totalLength.toFixed(2) + " m"; |         : totalLength.toFixed(2) + " m"; | ||||||
|   | |||||||
| @@ -188,14 +188,18 @@ label { | |||||||
|     font-weight: bold;  |     font-weight: bold;  | ||||||
| } | } | ||||||
|  |  | ||||||
| input[type="text"], input[type="submit"] {  | input[type="text"], input[type="submit"], input[type="number"] {  | ||||||
|     padding: 10px;  |     padding: 10px;  | ||||||
|     border: 1px solid #ccc;  |     border: 1px solid #ccc;  | ||||||
|     border-radius: 5px;  |     border-radius: 5px;  | ||||||
|     font-size: 16px;  |     font-size: 16px;  | ||||||
| } | } | ||||||
|  |  | ||||||
| input[type="text"]:focus {  | input[type="number"] {  | ||||||
|  |     width: 108px !important;  | ||||||
|  | } | ||||||
|  |  | ||||||
|  | input[type="text"]:focus, input[type="number"]:focus {  | ||||||
|     border-color: #007bff;  |     border-color: #007bff;  | ||||||
|     outline: none;  |     outline: none;  | ||||||
| } | } | ||||||
|   | |||||||
							
								
								
									
										
											BIN
										
									
								
								img/7-enable.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								img/7-enable.png
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 52 KiB | 
| @@ -341,7 +341,7 @@ void updateAmsWsData(JsonDocument& doc, JsonArray& amsArray, int& ams_count, Jso | |||||||
|             ams_data[i].trays[j].tray_color = trayObj["tray_color"].as<String>(); |             ams_data[i].trays[j].tray_color = trayObj["tray_color"].as<String>(); | ||||||
|             ams_data[i].trays[j].nozzle_temp_min = trayObj["nozzle_temp_min"].as<int>(); |             ams_data[i].trays[j].nozzle_temp_min = trayObj["nozzle_temp_min"].as<int>(); | ||||||
|             ams_data[i].trays[j].nozzle_temp_max = trayObj["nozzle_temp_max"].as<int>(); |             ams_data[i].trays[j].nozzle_temp_max = trayObj["nozzle_temp_max"].as<int>(); | ||||||
|             //ams_data[i].trays[j].setting_id = trayObj["setting_id"].as<String>(); |             if (trayObj["tray_type"].as<String>() == "") ams_data[i].trays[j].setting_id = ""; | ||||||
|             ams_data[i].trays[j].cali_idx = trayObj["cali_idx"].as<String>(); |             ams_data[i].trays[j].cali_idx = trayObj["cali_idx"].as<String>(); | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
| @@ -425,16 +425,8 @@ void mqtt_callback(char* topic, byte* payload, unsigned int length) { | |||||||
|         return; |         return; | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     // Wenn bambu auto set spool aktiv und eine spule erkannt und mqtt meldung das neue spule im ams |  | ||||||
|     if (autoSendToBambu && autoSetToBambuSpoolId > 0 &&  |  | ||||||
|         doc["print"]["command"].as<String>() == "push_status" && doc["print"]["ams"]["tray_pre"].as<uint8_t>() |  | ||||||
|         && !doc["print"]["ams"]["ams"].as<JsonArray>()) |  | ||||||
|     { |  | ||||||
|         autoSetSpool(autoSetToBambuSpoolId, doc["print"]["ams"]["tray_pre"].as<uint8_t>()); |  | ||||||
|     } |  | ||||||
|  |  | ||||||
|     // Prüfen, ob "print->upgrade_state" und "print.ams.ams" existieren |     // Prüfen, ob "print->upgrade_state" und "print.ams.ams" existieren | ||||||
|     if (doc["print"]["upgrade_state"].is<JsonObject>())  |     if (doc["print"]["upgrade_state"].is<JsonObject>() || (doc["print"]["command"].is<String>() && doc["print"]["command"] == "push_status"))  | ||||||
|     { |     { | ||||||
|         // Prüfen ob AMS-Daten vorhanden sind |         // Prüfen ob AMS-Daten vorhanden sind | ||||||
|         if (!doc["print"]["ams"].is<JsonObject>() || !doc["print"]["ams"]["ams"].is<JsonArray>())  |         if (!doc["print"]["ams"].is<JsonObject>() || !doc["print"]["ams"]["ams"].is<JsonArray>())  | ||||||
| @@ -479,6 +471,12 @@ void mqtt_callback(char* topic, byte* payload, unsigned int length) { | |||||||
|                     (trayObj["setting_id"].as<String>() != "" && trayObj["setting_id"].as<String>() != ams_data[storedIndex].trays[j].setting_id) || |                     (trayObj["setting_id"].as<String>() != "" && trayObj["setting_id"].as<String>() != ams_data[storedIndex].trays[j].setting_id) || | ||||||
|                     trayObj["cali_idx"].as<String>() != ams_data[storedIndex].trays[j].cali_idx) { |                     trayObj["cali_idx"].as<String>() != ams_data[storedIndex].trays[j].cali_idx) { | ||||||
|                     hasChanges = true; |                     hasChanges = true; | ||||||
|  |  | ||||||
|  |                     if (autoSendToBambu && autoSetToBambuSpoolId > 0 && hasChanges) | ||||||
|  |                     { | ||||||
|  |                         autoSetSpool(autoSetToBambuSpoolId, ams_data[storedIndex].trays[j].id); | ||||||
|  |                     } | ||||||
|  |  | ||||||
|                     break; |                     break; | ||||||
|                 } |                 } | ||||||
|             } |             } | ||||||
| @@ -497,6 +495,11 @@ void mqtt_callback(char* topic, byte* payload, unsigned int length) { | |||||||
|                         (vtTray["setting_id"].as<String>() != "" && vtTray["setting_id"].as<String>() != ams_data[i].trays[0].setting_id) || |                         (vtTray["setting_id"].as<String>() != "" && vtTray["setting_id"].as<String>() != ams_data[i].trays[0].setting_id) || | ||||||
|                         (vtTray["tray_type"].as<String>() != "" && vtTray["cali_idx"].as<String>() != ams_data[i].trays[0].cali_idx)) { |                         (vtTray["tray_type"].as<String>() != "" && vtTray["cali_idx"].as<String>() != ams_data[i].trays[0].cali_idx)) { | ||||||
|                         hasChanges = true; |                         hasChanges = true; | ||||||
|  |  | ||||||
|  |                         if (autoSendToBambu && autoSetToBambuSpoolId > 0 && hasChanges) | ||||||
|  |                         { | ||||||
|  |                             autoSetSpool(autoSetToBambuSpoolId, 254); | ||||||
|  |                         } | ||||||
|                     } |                     } | ||||||
|                     break; |                     break; | ||||||
|                 } |                 } | ||||||
| @@ -600,7 +603,6 @@ void mqtt_loop(void * parameter) { | |||||||
| bool setupMqtt() { | bool setupMqtt() { | ||||||
|     // Wenn Bambu Daten vorhanden |     // Wenn Bambu Daten vorhanden | ||||||
|     bool success = loadBambuCredentials(); |     bool success = loadBambuCredentials(); | ||||||
|     vTaskDelay(100 / portTICK_PERIOD_MS); |  | ||||||
|  |  | ||||||
|     if (!success) { |     if (!success) { | ||||||
|         Serial.println("Failed to load Bambu credentials"); |         Serial.println("Failed to load Bambu credentials"); | ||||||
| @@ -664,6 +666,7 @@ bool setupMqtt() { | |||||||
| void bambu_restart() { | void bambu_restart() { | ||||||
|     if (BambuMqttTask) { |     if (BambuMqttTask) { | ||||||
|         vTaskDelete(BambuMqttTask); |         vTaskDelete(BambuMqttTask); | ||||||
|  |         delay(10); | ||||||
|     } |     } | ||||||
|     setupMqtt(); |     setupMqtt(); | ||||||
| } | } | ||||||
| @@ -47,7 +47,7 @@ void scale_loop(void * parameter) { | |||||||
|       weight = round(scale.get_units()); |       weight = round(scale.get_units()); | ||||||
|     } |     } | ||||||
|      |      | ||||||
|     vTaskDelay(pdMS_TO_TICKS(100)); // Verzögerung, um die CPU nicht zu überlasten |     vTaskDelay(pdMS_TO_TICKS(100)); | ||||||
|   } |   } | ||||||
| } | } | ||||||
|  |  | ||||||
| @@ -90,7 +90,7 @@ uint8_t start_scale() { | |||||||
|   BaseType_t result = xTaskCreatePinnedToCore( |   BaseType_t result = xTaskCreatePinnedToCore( | ||||||
|     scale_loop, /* Function to implement the task */ |     scale_loop, /* Function to implement the task */ | ||||||
|     "ScaleLoop", /* Name of the task */ |     "ScaleLoop", /* Name of the task */ | ||||||
|     10000,  /* Stack size in words */ |     2048,  /* Stack size in words */ | ||||||
|     NULL,  /* Task input parameter */ |     NULL,  /* Task input parameter */ | ||||||
|     scaleTaskPrio,  /* Priority of the task */ |     scaleTaskPrio,  /* Priority of the task */ | ||||||
|     &ScaleTask,  /* Task handle. */ |     &ScaleTask,  /* Task handle. */ | ||||||
| @@ -110,6 +110,7 @@ uint8_t calibrate_scale() { | |||||||
|  |  | ||||||
|   //vTaskSuspend(RfidReaderTask); |   //vTaskSuspend(RfidReaderTask); | ||||||
|   vTaskDelete(RfidReaderTask); |   vTaskDelete(RfidReaderTask); | ||||||
|  |   vTaskDelete(ScaleTask); | ||||||
|   pauseBambuMqttTask = true; |   pauseBambuMqttTask = true; | ||||||
|   pauseMainTask = 1; |   pauseMainTask = 1; | ||||||
|  |  | ||||||
| @@ -177,8 +178,6 @@ uint8_t calibrate_scale() { | |||||||
|         vTaskDelay(pdMS_TO_TICKS(1)); |         vTaskDelay(pdMS_TO_TICKS(1)); | ||||||
|         esp_task_wdt_reset(); |         esp_task_wdt_reset(); | ||||||
|       } |       } | ||||||
|  |  | ||||||
|       //ESP.restart(); |  | ||||||
|     } |     } | ||||||
|     else |     else | ||||||
|     { |     { | ||||||
| @@ -212,8 +211,7 @@ uint8_t calibrate_scale() { | |||||||
|  |  | ||||||
|   oledShowMessage("Scale Ready"); |   oledShowMessage("Scale Ready"); | ||||||
|    |    | ||||||
|    |   Serial.println("restart Scale Task"); | ||||||
|   Serial.println("starte Scale Task"); |  | ||||||
|   start_scale(); |   start_scale(); | ||||||
|  |  | ||||||
|   pauseBambuMqttTask = false; |   pauseBambuMqttTask = false; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user