PFW-1471 Rename 'Toolchange count' to 'Material changes'
Added the string to our message so it can be translated Change in memory: Flash: -10 bytes SRAM: 0 bytes
This commit is contained in:
parent
ba34661b62
commit
b28aa6f42a
|
|
@ -722,7 +722,7 @@ static void factory_reset_stats(){
|
|||
|
||||
eeprom_update_word((uint16_t *)EEPROM_MMU_FAIL_TOT, 0);
|
||||
eeprom_update_word((uint16_t *)EEPROM_MMU_LOAD_FAIL_TOT, 0);
|
||||
eeprom_update_dword((uint32_t *)EEPROM_TOTAL_TOOLCHANGE_COUNT, 0);
|
||||
eeprom_update_dword((uint32_t *)EEPROM_MMU_MATERIAL_CHANGES, 0);
|
||||
}
|
||||
|
||||
// Factory reset function
|
||||
|
|
@ -9617,7 +9617,7 @@ void save_statistics(unsigned long _total_filament_used, unsigned long _total_pr
|
|||
total_filament_used = 0;
|
||||
|
||||
if (MMU2::mmu2.Enabled()) {
|
||||
eeprom_add_dword((uint32_t *)EEPROM_TOTAL_TOOLCHANGE_COUNT, MMU2::mmu2.ToolChangeCounter());
|
||||
eeprom_add_dword((uint32_t *)EEPROM_MMU_MATERIAL_CHANGES, MMU2::mmu2.ToolChangeCounter());
|
||||
// @@TODO why were EEPROM_MMU_FAIL_TOT and EEPROM_MMU_LOAD_FAIL_TOT behaving differently - i.e. updated with every change?
|
||||
MMU2::mmu2.ClearToolChangeCounter();
|
||||
MMU2::mmu2.ClearTMCFailures(); // not stored into EEPROM
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ void eeprom_init()
|
|||
eeprom_init_default_word((uint16_t*)EEPROM_MMU_LOAD_FAIL_TOT, 0);
|
||||
eeprom_init_default_byte((uint8_t*)EEPROM_MMU_FAIL, 0);
|
||||
eeprom_init_default_byte((uint8_t*)EEPROM_MMU_LOAD_FAIL, 0);
|
||||
eeprom_init_default_dword((uint32_t*)EEPROM_TOTAL_TOOLCHANGE_COUNT, 0);
|
||||
eeprom_init_default_dword((uint32_t*)EEPROM_MMU_MATERIAL_CHANGES, 0);
|
||||
if (eeprom_read_byte(&(EEPROM_Sheets_base->active_sheet)) == EEPROM_EMPTY_VALUE)
|
||||
{
|
||||
eeprom_update_byte(&(EEPROM_Sheets_base->active_sheet), 0);
|
||||
|
|
|
|||
|
|
@ -344,7 +344,7 @@ static_assert(sizeof(Sheets) == EEPROM_SHEETS_SIZEOF, "Sizeof(Sheets) is not EEP
|
|||
| 0x0CAE 3246 | float | EEPROM_TEMP_MODEL_E | ??? | ff ff ff ffh | Temp model error threshold (K/s) | Temp model | D3 Ax0cae C4
|
||||
| 0x0CAD 3245 | uint8 | EEPROM_FSENSOR_JAM_DETECTION | 01h 1 | ff/01 | fsensor pat9125 jam detection feature | LCD menu | D3 Ax0cad C1
|
||||
| 0x0CAC 3244 | uint8 | EEPROM_MMU_ENABLED | 01h 1 | ff/01 | MMU enabled | LCD menu | D3 Ax0cac C1
|
||||
| 0x0CA8 3240 | uint32 | EEPROM_TOTAL_TOOLCHANGE_COUNT | ??? | ff ff ff ffh | MMU toolchange counter over printers lifetime | LCD statistic| D3 Ax0ca8 C4
|
||||
| 0x0CA8 3240 | uint32 | EEPROM_MMU_MATERIAL_CHANGES | ??? | ff ff ff ffh | MMU toolchange counter over printers lifetime | LCD statistic| D3 Ax0ca8 C4
|
||||
| 0x0CA7 3239 | uint8 | EEPROM_HEAT_BED_ON_LOAD_FILAMENT | ffh 255 | ffh 255 | Heat bed on load filament unknown state | LCD menu | D3 Ax0ca7 C1
|
||||
| ^ | ^ | ^ | 00h 0 | ^ | Do not heat bed on load filament | ^ | ^
|
||||
| ^ | ^ | ^ | 01h 1 | ^ | Heat bed on load filament | ^ | ^
|
||||
|
|
@ -582,8 +582,8 @@ static Sheets * const EEPROM_Sheets_base = (Sheets*)(EEPROM_SHEETS_BASE);
|
|||
|
||||
#define EEPROM_FSENSOR_JAM_DETECTION (EEPROM_TEMP_MODEL_E-1) // uint8_t
|
||||
#define EEPROM_MMU_ENABLED (EEPROM_FSENSOR_JAM_DETECTION-1) // uint8_t
|
||||
#define EEPROM_TOTAL_TOOLCHANGE_COUNT (EEPROM_MMU_ENABLED-4)
|
||||
#define EEPROM_HEAT_BED_ON_LOAD_FILAMENT (EEPROM_TOTAL_TOOLCHANGE_COUNT-1) //uint8
|
||||
#define EEPROM_MMU_MATERIAL_CHANGES (EEPROM_MMU_ENABLED-4) // uint32_t
|
||||
#define EEPROM_HEAT_BED_ON_LOAD_FILAMENT (EEPROM_MMU_MATERIAL_CHANGES-1) //uint8
|
||||
#define EEPROM_CALIBRATION_STATUS_V2 (EEPROM_HEAT_BED_ON_LOAD_FILAMENT-1) //uint8
|
||||
|
||||
//This is supposed to point to last item to allow EEPROM overrun check. Please update when adding new items.
|
||||
|
|
|
|||
|
|
@ -100,6 +100,7 @@ const char MSG_SETTINGS[] PROGMEM_I1 = ISTR("Settings"); ////MSG_SETTINGS c=18
|
|||
const char MSG_SELECT_LANGUAGE[] PROGMEM_I1 = ISTR("Select language"); ////MSG_SELECT_LANGUAGE c=18
|
||||
const char MSG_SORTING_FILES[] PROGMEM_I1 = ISTR("Sorting files"); ////MSG_SORTING_FILES c=20
|
||||
const char MSG_TOTAL[] PROGMEM_I1 = ISTR("Total"); ////MSG_TOTAL c=6
|
||||
const char MSG_MATERIAL_CHANGES[] PROGMEM_I1 = ISTR("Material changes"); ////MSG_MATERIAL_CHANGES c=18
|
||||
const char MSG_TOTAL_FAILURES[] PROGMEM_I1 = ISTR("Total failures"); ////MSG_TOTAL_FAILURES c=20
|
||||
const char MSG_HW_SETUP[] PROGMEM_I1 = ISTR("HW Setup"); ////MSG_HW_SETUP c=18
|
||||
const char MSG_MODE[] PROGMEM_I1 = ISTR("Mode"); ////MSG_MODE c=6
|
||||
|
|
|
|||
|
|
@ -105,6 +105,7 @@ extern const char MSG_SETTINGS[];
|
|||
extern const char MSG_SELECT_LANGUAGE[];
|
||||
extern const char MSG_SORTING_FILES[];
|
||||
extern const char MSG_TOTAL[];
|
||||
extern const char MSG_MATERIAL_CHANGES[];
|
||||
extern const char MSG_TOTAL_FAILURES[];
|
||||
extern const char MSG_HW_SETUP[];
|
||||
extern const char MSG_MODE[];
|
||||
|
|
|
|||
|
|
@ -1160,10 +1160,10 @@ static uint16_t __attribute__((noinline)) clamp999(uint16_t v){
|
|||
//!
|
||||
//! @code{.unparsed}
|
||||
//! |01234567890123456789|
|
||||
//! | Main | MSG_MAIN c=18
|
||||
//! | Last print | MSG_LAST_PRINT c=18
|
||||
//! | Total | MSG_TOTAL c=6
|
||||
//! | |
|
||||
//! | Main | MSG_MAIN c=18
|
||||
//! | Last print | MSG_LAST_PRINT c=18
|
||||
//! | Total | MSG_TOTAL c=6
|
||||
//! | Material changes | MSG_MATERIAL_CHANGES c=18
|
||||
//! ----------------------
|
||||
//! @endcode
|
||||
static void lcd_menu_fails_stats_mmu()
|
||||
|
|
@ -1172,7 +1172,7 @@ static void lcd_menu_fails_stats_mmu()
|
|||
MENU_ITEM_BACK_P(_T(MSG_MAIN));
|
||||
MENU_ITEM_SUBMENU_P(_T(MSG_LAST_PRINT), lcd_menu_fails_stats_mmu_print);
|
||||
MENU_ITEM_SUBMENU_P(_T(MSG_TOTAL), lcd_menu_fails_stats_mmu_total);
|
||||
MENU_ITEM_SUBMENU_P(_i("Toolchange count"), lcd_menu_toolchange_stats_mmu_total);
|
||||
MENU_ITEM_SUBMENU_P(_T(MSG_MATERIAL_CHANGES), lcd_menu_toolchange_stats_mmu_total);
|
||||
MENU_END();
|
||||
}
|
||||
|
||||
|
|
@ -1230,7 +1230,7 @@ static void lcd_menu_fails_stats_mmu_total() {
|
|||
//!
|
||||
//! @code{.unparsed}
|
||||
//! |01234567890123456789|
|
||||
//! |Toolchange count: |
|
||||
//! |Material changes: ||
|
||||
//! | 4294967295|
|
||||
//! | |
|
||||
//! | |
|
||||
|
|
@ -1245,10 +1245,11 @@ static void lcd_menu_toolchange_stats_mmu_total()
|
|||
static_assert(sizeof(menu_data)>= sizeof(_menu_data_t),"_menu_data_t doesn't fit into menu_data");
|
||||
_menu_data_t* _md = (_menu_data_t*)&(menu_data[0]);
|
||||
if(!_md->initialized) {
|
||||
lcd_set_cursor(0, 0);
|
||||
lcd_puts_P(PSTR("Toolchange count:"));
|
||||
lcd_clear();
|
||||
lcd_puts_P(_T(MSG_MATERIAL_CHANGES)); /// MSG_MATERIAL_CHANGES c=18
|
||||
lcd_putc(':');
|
||||
lcd_set_cursor(10, 1);
|
||||
lcd_print(eeprom_read_dword((uint32_t*)EEPROM_TOTAL_TOOLCHANGE_COUNT));
|
||||
lcd_print(eeprom_read_dword((uint32_t*)EEPROM_MMU_MATERIAL_CHANGES));
|
||||
_md->initialized = true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue