Browse Source

update

pull/45/head
Sergey 3 years ago
parent
commit
dc6785f14c
  1. 16
      Marlin/Configuration.h
  2. 2
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/archim2-flash/flash_storage.cpp
  3. 2
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/archim2-flash/media_file_reader.cpp
  4. 4
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/archim2-flash/media_file_reader.h
  5. 1
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/cocoa_press/screens.h
  6. 10
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/cocoa_press/status_screen.cpp
  7. 2
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/cocoa_press/status_screen.h
  8. 6
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/config.h
  9. 6
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/extended/poly_ui.h
  10. 47
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/scripts/file2cpp.py
  11. 108
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/scripts/font2cpp.py
  12. 113
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/scripts/img2cpp.py
  13. 16
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/bed_mesh_edit_screen.cpp
  14. 3
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/bed_mesh_view_screen.cpp
  15. 6
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/boot_screen.cpp
  16. 15
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/confirm_user_request_alert_box.cpp
  17. 35
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/leveling_menu.cpp
  18. 11
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/tune_menu.cpp
  19. 2
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/z_offset_screen.cpp
  20. 4
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/language/language_en.h
  21. 4
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/screens.h
  22. 66
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/theme/bitmaps.h
  23. 2
      Marlin/src/lcd/extui/ftdi_eve_touch_ui/theme/sounds.cpp
  24. 6
      Marlin/src/lcd/extui/ui_api.h
  25. 26
      Marlin/src/lcd/language/language_ru.h
  26. 46
      Marlin/src/lcd/language/language_uk.h
  27. 17
      Marlin/src/lcd/menu/menu_filament.cpp
  28. 18
      Marlin/src/lcd/menu/menu_item.h
  29. 9
      Marlin/src/lcd/menu/menu_main.cpp
  30. 6
      Marlin/src/pins/pins.h
  31. 4
      Marlin/src/pins/stm32f4/pins_FYSETC_S6.h
  32. 6
      Marlin/src/pins/stm32f4/pins_FYSETC_SPIDER.h
  33. 2
      buildroot/share/PlatformIO/boards/marlin_fysetc_s6.json
  34. 35
      buildroot/share/PlatformIO/boards/marlin_fysetc_s6_8000.json
  35. 12
      buildroot/share/PlatformIO/scripts/fix_framework_weakness.py
  36. 7
      buildroot/share/PlatformIO/scripts/stm32_serialbuffer.py
  37. 4
      ini/stm32f1-maple.ini
  38. 4
      ini/stm32f1.ini
  39. 19
      ini/stm32f4.ini

16
Marlin/Configuration.h

@ -1722,15 +1722,13 @@
//#define MANUAL_J_HOME_POS 0
//#define MANUAL_K_HOME_POS 0
// Use "Z Safe Homing" to avoid homing with a Z probe outside the bed area.
//
// With this feature enabled:
//
// - Allow Z homing only after X and Y homing AND stepper drivers still enabled.
// - If stepper drivers time out, it will need X and Y homing again before Z homing.
// - Move the Z probe (or nozzle) to a defined XY point before Z Homing.
// - Prevent Z homing when the Z probe is outside bed area.
//
/**
* Use "Z Safe Homing" to avoid homing with a Z probe outside the bed area.
*
* - Moves the Z probe (or nozzle) to a defined XY point before Z homing.
* - Allows Z homing only when XY positions are known and trusted.
* - If stepper drivers sleep, XY homing may be required again before Z homing.
*/
#define Z_SAFE_HOMING
#if ENABLED(Z_SAFE_HOMING)

2
Marlin/src/lcd/extui/ftdi_eve_touch_ui/archim2-flash/flash_storage.cpp

@ -20,7 +20,7 @@
* location: <https://www.gnu.org/licenses/>. *
****************************************************************************/
#include "../compat.h"
#include "../config.h"
#if ENABLED(TOUCH_UI_FTDI_EVE)

2
Marlin/src/lcd/extui/ftdi_eve_touch_ui/archim2-flash/media_file_reader.cpp

@ -20,7 +20,7 @@
* location: <https://www.gnu.org/licenses/>. *
****************************************************************************/
#include "../compat.h"
#include "../config.h"
#if ENABLED(TOUCH_UI_FTDI_EVE)
#include "media_file_reader.h"

4
Marlin/src/lcd/extui/ftdi_eve_touch_ui/archim2-flash/media_file_reader.h

@ -32,9 +32,7 @@
class MediaFileReader {
private:
#if ENABLED(SDSUPPORT)
DiskIODriver_SPI_SD card;
SdVolume volume;
SdFile root, file;
SdFile root, file;
#endif
public:

1
Marlin/src/lcd/extui/ftdi_eve_touch_ui/cocoa_press/screens.h

@ -118,7 +118,6 @@ enum {
#include "../generic/files_screen.h"
#include "../generic/move_axis_screen.h"
#include "../generic/flow_percent_screen.h"
#include "../generic/tune_menu.h"
#if HAS_JUNCTION_DEVIATION
#include "../generic/junction_deviation_screen.h"
#else

10
Marlin/src/lcd/extui/ftdi_eve_touch_ui/cocoa_press/status_screen.cpp

@ -294,4 +294,14 @@ void StatusScreen::onIdle() {
}
}
void StatusScreen::onMediaInserted() {
if (AT_SCREEN(StatusScreen))
setStatusMessage(GET_TEXT_F(MSG_MEDIA_INSERTED));
}
void StatusScreen::onMediaRemoved() {
if (AT_SCREEN(StatusScreen) || ExtUI::isPrintingFromMedia())
setStatusMessage(GET_TEXT_F(MSG_MEDIA_REMOVED));
}
#endif // COCOA_STATUS_SCREEN

2
Marlin/src/lcd/extui/ftdi_eve_touch_ui/cocoa_press/status_screen.h

@ -52,4 +52,6 @@ class StatusScreen : public BaseScreen, public CachedScreen<STATUS_SCREEN_CACHE>
static bool onTouchHeld(uint8_t tag);
static bool onTouchEnd(uint8_t tag);
static void onIdle();
static void onMediaInserted();
static void onMediaRemoved();
};

6
Marlin/src/lcd/extui/ftdi_eve_touch_ui/config.h

@ -21,6 +21,10 @@
#pragma once
// Configure this display with options in Configuration_adv.h
#include "../../../inc/MarlinConfigPre.h"
#if ENABLED(TOUCH_UI_FTDI_EVE)
#include "compat.h"
// Configure this display with options in Configuration_adv.h
#endif

6
Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/extended/poly_ui.h

@ -239,9 +239,11 @@ class DeduplicatedPolyReader : public POLY_READER {
*/
template<class POLY_READER=DeduplicatedPolyReader<TransformedPolyReader>>
class GenericPolyUI {
private:
protected:
CommandProcessor &cmd;
draw_mode_t mode;
private:
// Attributes used to paint buttons
uint32_t btn_fill_color = 0x000000;
@ -250,8 +252,6 @@ class GenericPolyUI {
uint32_t btn_stroke_color = 0x000000;
uint8_t btn_stroke_width = 28;
draw_mode_t mode;
public:
enum ButtonStyle : uint8_t {
FILL = 1,

47
Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/scripts/file2cpp.py

@ -0,0 +1,47 @@
#!/usr/bin/python
# Written By Marcio Teixeira 2021 - SynDaver Labs, Inc.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# To view a copy of the GNU General Public License, go to the following
# location: <https://www.gnu.org/licenses/>.
from __future__ import print_function
import argparse
import textwrap
import os
import zlib
def deflate(data):
return zlib.compress(data)
if __name__ == "__main__":
parser = argparse.ArgumentParser(description='Converts a file into a packed C array for use as data')
parser.add_argument("input")
parser.add_argument("-d", "--deflate", action="store_true", help="Packs the data using the deflate algorithm")
args = parser.parse_args()
varname = os.path.splitext(os.path.basename(args.input))[0];
with open(args.input, "rb") as in_file:
data = in_file.read()
if args.deflate:
data = deflate(data)
data = bytearray(data)
data = list(map(lambda a: "0x" + format(a, '02x'), data))
nElements = len(data)
data = ', '.join(data)
data = textwrap.fill(data, 75, initial_indent = ' ', subsequent_indent = ' ')
print("const unsigned char " + varname + "[" + format(nElements) + "] PROGMEM = {")
print(data)
print("};")

108
Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/scripts/font2cpp.py

@ -0,0 +1,108 @@
#!/usr/bin/python
# Written By Marcio Teixeira 2019 - Aleph Objects, Inc.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# To view a copy of the GNU General Public License, go to the following
# location: <https://www.gnu.org/licenses/>.
from __future__ import print_function
from PIL import Image
import argparse
import textwrap
def pack_rle(data):
"""Use run-length encoding to pack the bytes"""
rle = []
value = data[0]
count = 0
for i in data:
if i != value or count == 255:
rle.append(count)
rle.append(value)
value = i
count = 1
else:
count += 1
rle.append(count)
rle.append(value)
return rle
class WriteSource:
def __init__(self, lines_in_blocks):
self.blocks = []
self.values = []
self.block_size = lines_in_blocks
self.rows = 0
def add_pixel(self, value):
self.values.append(value)
def convert_to_4bpp(self, data, chunk_size = 0):
# Invert the image
data = list(map(lambda i: 255 - i, data))
# Quanitize 8-bit values into 4-bits
data = list(map(lambda i: i >> 4, data))
# Make sure there is an even number of elements
if (len(data) & 1) == 1:
data.append(0)
# Combine each two adjacent values into one
i = iter(data)
data = list(map(lambda a, b: a << 4 | b, i ,i))
# Pack the data
data = pack_rle(data)
# Convert values into hex strings
return list(map(lambda a: "0x" + format(a, '02x'), data))
def end_row(self, y):
# Pad each row into even number of values
if len(self.values) & 1:
self.values.append(0)
self.rows += 1
if self.block_size and (self.rows % self.block_size) == 0:
self.blocks.append(self.values)
self.values = []
def write(self):
if len(self.values):
self.blocks.append(self.values)
block_strs = [];
for b in self.blocks:
data = self.convert_to_4bpp(b)
data = ', '.join(data)
data = textwrap.fill(data, 75, initial_indent = ' ', subsequent_indent = ' ')
block_strs.append(data)
print("const unsigned char font[] PROGMEM = {")
for i, b in enumerate(block_strs):
if i:
print(',')
print('\n /* {} */'.format(i))
print(b, end='')
print("\n};")
if __name__ == "__main__":
parser = argparse.ArgumentParser(description='Converts a grayscale bitmap into a 16-level RLE packed C array for use as font data')
parser.add_argument("input")
parser.add_argument('--char_height', help='Adds a separator every so many lines', type=int)
args = parser.parse_args()
writer = WriteSource(args.char_height)
img = Image.open(args.input).convert('L')
for y in range(img.height):
for x in range(img.width):
writer.add_pixel(img.getpixel((x,y)))
writer.end_row(y)
writer.write()

113
Marlin/src/lcd/extui/ftdi_eve_touch_ui/ftdi_eve_lib/scripts/img2cpp.py

@ -0,0 +1,113 @@
#!/usr/bin/python
# Written By Marcio Teixeira 2021 - SynDaver Labs, Inc.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# To view a copy of the GNU General Public License, go to the following
# location: <https://www.gnu.org/licenses/>.
from __future__ import print_function
from PIL import Image
import argparse
import textwrap
import os
import sys
import zlib
class WriteSource:
def __init__(self, mode):
self.values = []
self.mode = mode
self.offset = 8
self.byte = 0
def finish_byte(self):
if self.offset != 8:
self.values.append(self.byte)
self.offset = 8
self.byte = 0
def add_bits_to_byte(self, value, size = 1):
self.offset -= size
self.byte = self.byte | value << self.offset
if self.offset == 0:
self.finish_byte()
def append_rgb565(self, color):
value = ((color[0] & 0xF8) << 8) + ((color[1] & 0xFC) << 3) + ((color[2] & 0xF8) >> 3)
self.values.append((value & 0x00FF) >> 0);
self.values.append((value & 0xFF00) >> 8);
def append_rgb332(self, color):
value = (color[0] & 0xE0) + ((color[1] & 0xE0) >> 3) + ((color[2] & 0xC0) >> 6)
self.values.append(value);
def append_grayscale(self, color, bits):
luminance = int(0.2126 * color[0] + 0.7152 * color[1] + 0.0722 * color[2])
self.add_bits_to_byte(luminance >> (8 - bits), bits)
def deflate(self, data):
return zlib.compress(data)
def add_pixel(self, color):
if self.mode == "l1":
self.append_grayscale(color, 1)
elif self.mode == "l2":
self.append_grayscale(color, 2)
elif self.mode == "l4":
self.append_grayscale(color, 4)
elif self.mode == "l8":
self.append_grayscale(color, 8)
elif self.mode == "rgb565":
self.append_rgb565(color)
elif self.mode == "rgb332":
self.append_rgb332(color)
def end_row(self, y):
if self.mode in ["l1", "l2", "l3"]:
self.finish_byte()
def write(self, varname, deflate):
print("Length of uncompressed data: ", len(self.values), file=sys.stderr)
data = bytes(bytearray(self.values))
if deflate:
data = self.deflate(data)
print("Length of data after compression: ", len(data), file=sys.stderr)
data = bytearray(data)
data = list(map(lambda a: "0x" + format(a, '02x'), data))
nElements = len(data)
data = ', '.join(data)
data = textwrap.fill(data, 75, initial_indent = ' ', subsequent_indent = ' ')
print("const unsigned char " + varname + "[" + format(nElements) + "] PROGMEM = {")
print(data)
print("};")
if __name__ == "__main__":
parser = argparse.ArgumentParser(description='Converts a bitmap into a C array')
parser.add_argument("input")
parser.add_argument("-d", "--deflate", action="store_true", help="Packs the data using the deflate algorithm")
parser.add_argument("-m", "--mode", default="l1", help="Mode, can be l1, l2, l4, l8, rgb332 or rgb565")
args = parser.parse_args()
varname = os.path.splitext(os.path.basename(args.input))[0];
writer = WriteSource(args.mode)
img = Image.open(args.input)
print("Image height: ", img.height, file=sys.stderr)
print("Image width: ", img.width, file=sys.stderr)
for y in range(img.height):
for x in range(img.width):
writer.add_pixel(img.getpixel((x,y)))
writer.end_row(y)
writer.write(varname, args.deflate)

16
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/bed_mesh_edit_screen.cpp

@ -190,17 +190,11 @@ bool BedMeshEditScreen::onTouchEnd(uint8_t tag) {
}
void BedMeshEditScreen::show() {
// On entry, home if needed and save current mesh
if (!ExtUI::isMachineHomed()) {
SpinnerDialogBox::enqueueAndWait_P(F("G28\nG29 S1"));
// After the spinner, go to this screen.
current_screen.forget();
PUSH_SCREEN(BedMeshEditScreen);
}
else {
injectCommands_P(PSTR("G29 S1"));
GOTO_SCREEN(BedMeshEditScreen);
}
// On entry, always home (to account for possible Z offset changes) and save current mesh
SpinnerDialogBox::enqueueAndWait_P(F("G28\nG29 S1"));
// After the spinner, go to this screen.
current_screen.forget();
PUSH_SCREEN(BedMeshEditScreen);
}
#endif // FTDI_BED_MESH_EDIT_SCREEN

3
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/bed_mesh_view_screen.cpp

@ -132,7 +132,6 @@ void BedMeshViewScreen::onMeshUpdate(const int8_t x, const int8_t y, const ExtUI
mydata.count = GRID_MAX_POINTS;
break;
case ExtUI::G26_START:
GOTO_SCREEN(BedMeshViewScreen);
mydata.message = nullptr;
mydata.count = 0;
break;
@ -161,7 +160,7 @@ void BedMeshViewScreen::doProbe() {
void BedMeshViewScreen::doMeshValidation() {
mydata.count = 0;
GOTO_SCREEN(StatusScreen);
injectCommands_P(PSTR("M75\nG28 O\nM117 Heating...\nG26 R X0 Y0\nG27\nM77"));
injectCommands_P(PSTR("G28\nM117 Heating...\nG26 R X0 Y0\nG27"));
}
void BedMeshViewScreen::show() {

6
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/boot_screen.cpp

@ -83,8 +83,10 @@ void BootScreen::onIdle() {
if (UIData::animations_enabled()) {
// If there is a startup video in the flash SPI, play
// that, otherwise show a static splash screen.
if (!MediaPlayerScreen::playBootMedia())
showSplashScreen();
#ifdef FTDI_MEDIA_PLAYER_SCREEN
if (!MediaPlayerScreen::playBootMedia())
#endif
showSplashScreen();
}
#endif

15
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/confirm_user_request_alert_box.cpp

@ -35,12 +35,15 @@ void ConfirmUserRequestAlertBox::onRedraw(draw_mode_t mode) {
bool ConfirmUserRequestAlertBox::onTouchEnd(uint8_t tag) {
switch (tag) {
case 1:
if (ExtUI::isPrintingPaused()) {
// The TuneMenu will call ExtUI::setUserConfirmed()
GOTO_SCREEN(TuneMenu);
current_screen.forget();
}
else {
#ifdef FTDI_TUNE_MENU
if (ExtUI::isPrintingPaused()) {
// The TuneMenu will call ExtUI::setUserConfirmed()
GOTO_SCREEN(TuneMenu);
current_screen.forget();
}
else
#endif
{
ExtUI::setUserConfirmed();
GOTO_PREVIOUS();
}

35
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/leveling_menu.cpp

@ -83,6 +83,7 @@ void LevelingMenu::onRedraw(draw_mode_t what) {
.font(font_medium).colors(normal_btn)
.enabled(EITHER(Z_STEPPER_AUTO_ALIGN,MECHANICAL_GANTRY_CALIBRATION))
.tag(2).button(LEVEL_AXIS_POS, GET_TEXT_F(MSG_LEVEL_X_AXIS))
.enabled(ENABLED(HAS_BED_PROBE))
.tag(3).button(PROBE_BED_POS, GET_TEXT_F(MSG_PROBE_BED))
.enabled(ENABLED(HAS_MESH))
.tag(4).button(SHOW_MESH_POS, GET_TEXT_F(MSG_SHOW_MESH))
@ -101,30 +102,32 @@ void LevelingMenu::onRedraw(draw_mode_t what) {
bool LevelingMenu::onTouchEnd(uint8_t tag) {
switch (tag) {
case 1: GOTO_PREVIOUS(); break;
case 1: GOTO_PREVIOUS(); break;
#if EITHER(Z_STEPPER_AUTO_ALIGN,MECHANICAL_GANTRY_CALIBRATION)
case 2: SpinnerDialogBox::enqueueAndWait_P(F("G34")); break;
case 2: SpinnerDialogBox::enqueueAndWait_P(F("G34")); break;
#endif
case 3:
#ifndef BED_LEVELING_COMMANDS
#define BED_LEVELING_COMMANDS "G29"
#if ENABLED(HAS_BED_PROBE)
case 3:
#ifndef BED_LEVELING_COMMANDS
#define BED_LEVELING_COMMANDS "G29"
#endif
#if ENABLED(AUTO_BED_LEVELING_UBL)
BedMeshViewScreen::doProbe();
#else
SpinnerDialogBox::enqueueAndWait_P(F(BED_LEVELING_COMMANDS));
#endif
break;
#endif
#if ENABLED(AUTO_BED_LEVELING_UBL)
BedMeshViewScreen::doProbe();
#else
SpinnerDialogBox::enqueueAndWait_P(F(BED_LEVELING_COMMANDS));
#endif
break;
#if ENABLED(AUTO_BED_LEVELING_UBL)
case 4: BedMeshViewScreen::show(); break;
case 5: BedMeshEditScreen::show(); break;
case 4: BedMeshViewScreen::show(); break;
case 5: BedMeshEditScreen::show(); break;
#endif
#if ENABLED(G26_MESH_VALIDATION)
case 6: BedMeshViewScreen::doMeshValidation(); break;
case 6: BedMeshViewScreen::doMeshValidation(); break;
#endif
#if ENABLED(BLTOUCH)
case 7: injectCommands_P(PSTR("M280 P0 S60")); break;
case 8: SpinnerDialogBox::enqueueAndWait_P(F("M280 P0 S90\nG4 P100\nM280 P0 S120")); break;
case 7: injectCommands_P(PSTR("M280 P0 S60")); break;
case 8: SpinnerDialogBox::enqueueAndWait_P(F("M280 P0 S90\nG4 P100\nM280 P0 S120")); break;
#endif
default: return false;
}

11
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/tune_menu.cpp

@ -77,8 +77,11 @@ void TuneMenu::onRedraw(draw_mode_t what) {
.tag(3).button(FIL_CHANGE_POS, GET_TEXT_F(MSG_FILAMENTCHANGE))
.enabled(EITHER(LIN_ADVANCE, FILAMENT_RUNOUT_SENSOR))
.tag(9).button(FILAMENT_POS, GET_TEXT_F(MSG_FILAMENT))
.enabled(BOTH(HAS_LEVELING, HAS_BED_PROBE) || ENABLED(BABYSTEPPING))
.tag(4).button(NUDGE_NOZ_POS, GET_TEXT_F(TERN(BABYSTEPPING, MSG_NUDGE_NOZZLE, MSG_ZPROBE_ZOFFSET)))
#if ENABLED(BABYSTEPPING) && HAS_MULTI_HOTEND
.tag(4).button(NUDGE_NOZ_POS, GET_TEXT_F(MSG_NUDGE_NOZZLE))
#elif BOTH(HAS_LEVELING, HAS_BED_PROBE)
.tag(4).button(NUDGE_NOZ_POS, GET_TEXT_F(MSG_ZPROBE_ZOFFSET))
#endif
.tag(5).button(SPEED_POS, GET_TEXT_F(MSG_PRINT_SPEED))
.enabled(sdOrHostPrinting)
.tag(sdOrHostPaused ? 7 : 6)
@ -99,11 +102,11 @@ bool TuneMenu::onTouchEnd(uint8_t tag) {
using namespace Theme;
using namespace ExtUI;
switch (tag) {
case 1: GOTO_PREVIOUS(); break;
case 1: SaveSettingsDialogBox::promptToSaveSettings(); break;
case 2: GOTO_SCREEN(TemperatureScreen); break;
case 3: GOTO_SCREEN(ChangeFilamentScreen); break;
case 4:
#if ENABLED(BABYSTEPPING)
#if ENABLED(BABYSTEPPING) && HAS_MULTI_HOTEND
GOTO_SCREEN(NudgeNozzleScreen);
#elif BOTH(HAS_LEVELING, HAS_BED_PROBE)
GOTO_SCREEN(ZOffsetScreen);

2
Marlin/src/lcd/extui/ftdi_eve_touch_ui/generic/z_offset_screen.cpp

@ -53,7 +53,7 @@ void ZOffsetScreen::onRedraw(draw_mode_t what) {
w.heading( GET_TEXT_F(MSG_ZPROBE_ZOFFSET));
w.color(z_axis).adjuster(4, GET_TEXT_F(MSG_ZPROBE_ZOFFSET), getZOffset_mm());
w.increments();
w.button(2, GET_TEXT_F(MSG_PROBE_WIZARD), !isPrinting());
w.button(2, GET_TEXT_F(MSG_PROBE_WIZARD), !isPrinting() && !wizardRunning());
}
void ZOffsetScreen::move(float mm, int16_t steps) {

4
Marlin/src/lcd/extui/ftdi_eve_touch_ui/language/language_en.h

@ -130,7 +130,7 @@ namespace Language_en {
PROGMEM Language_Str MSG_EEPROM_RESTORED = u8"Settings restored from backup";
PROGMEM Language_Str MSG_EEPROM_RESET = u8"Settings restored to default";
PROGMEM Language_Str MSG_EEPROM_SAVED = u8"Settings saved!";
PROGMEM Language_Str MSG_EEPROM_SAVE_PROMPT = u8"Do you wish to save these settings for next power-on?";
PROGMEM Language_Str MSG_EEPROM_SAVE_PROMPT = u8"Settings applied. Save these settings for next power-on?";
PROGMEM Language_Str MSG_EEPROM_RESET_WARNING = u8"Are you sure? Customizations will be lost.";
PROGMEM Language_Str MSG_PASSCODE_REJECTED = u8"Wrong passcode!";
@ -146,7 +146,7 @@ namespace Language_en {
PROGMEM Language_Str MSG_AXIS_LEVELING = u8"Axis Leveling";
PROGMEM Language_Str MSG_PROBE_BED = u8"Probe Mesh";
PROGMEM Language_Str MSG_SHOW_MESH = u8"View Mesh";
PROGMEM Language_Str MSG_PRINT_TEST = u8"Print Test";
PROGMEM Language_Str MSG_PRINT_TEST = u8"Print Test (PLA)";
PROGMEM Language_Str MSG_MOVE_Z_TO_TOP = u8"Raise Z to Top";
#if ENABLED(TOUCH_UI_LULZBOT_BIO)

4
Marlin/src/lcd/extui/ftdi_eve_touch_ui/screens.h

@ -22,7 +22,7 @@
#pragma once
#include "compat.h"
#include "config.h"
#if ENABLED(TOUCH_UI_FTDI_EVE)
@ -40,7 +40,7 @@ extern tiny_timer_t refresh_timer;
#if ENABLED(TOUCH_UI_LULZBOT_BIO)
#include "bioprinter/screens.h"
#elif ENABLED(TOUCH_UI_COCOA_PRESS)
#include "cocoapress/screens.h"
#include "cocoa_press/screens.h"
#elif ENABLED(TOUCH_UI_SYNDAVER_LEVEL)
#include "syndaver_level/screens.h"
#else

66
Marlin/src/lcd/extui/ftdi_eve_touch_ui/theme/bitmaps.h

@ -36,7 +36,7 @@ namespace Theme {
.height = 23,
};
constexpr PROGMEM unsigned char Extruder_Icon[] = {
constexpr PROGMEM unsigned char Extruder_Icon[69] = {
0x3F, 0xFF, 0xFC,
0x7F, 0xFF, 0xFE,
0xC0, 0x00, 0x03,
@ -68,12 +68,12 @@ namespace Theme {
.filter = BILINEAR,
.wrapx = BORDER,
.wrapy = BORDER,
.RAMG_offset = 8100,
.RAMG_offset = 8069,
.width = 32,
.height = 23,
};
constexpr PROGMEM unsigned char Bed_Heat_Icon[] = {
constexpr PROGMEM unsigned char Bed_Heat_Icon[92] = {
0x01, 0x81, 0x81, 0x80,
0x01, 0x81, 0x81, 0x80,
0x00, 0xC0, 0xC0, 0xC0,
@ -105,12 +105,12 @@ namespace Theme {
.filter = BILINEAR,
.wrapx = BORDER,
.wrapy = BORDER,
.RAMG_offset = 8300,
.RAMG_offset = 8161,
.width = 32,
.height = 32,
};
constexpr PROGMEM unsigned char Fan_Icon[] = {
constexpr PROGMEM unsigned char Fan_Icon[128] = {
0xFF, 0xFF, 0xFF, 0xFF,
0xFF, 0xFF, 0xFF, 0xFF,
0xF8, 0x00, 0x00, 0x1F,
@ -151,12 +151,12 @@ namespace Theme {
.filter = BILINEAR,
.wrapx = BORDER,
.wrapy = BORDER,
.RAMG_offset = 9000,
.RAMG_offset = 8289,
.width = 50,
.height = 20,
};
constexpr PROGMEM unsigned char TD_Icon[] = {
constexpr PROGMEM unsigned char TD_Icon[140] = {
0x00, 0x7F, 0xFF, 0xFF, 0xFF, 0xFC, 0x00, // Thumb Drive Widget
0x00, 0x7F, 0xFF, 0xFF, 0xFF, 0xFF, 0x00,
0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x80,
@ -179,5 +179,55 @@ namespace Theme {
0x00, 0x7F, 0xFF, 0xFF, 0xFF, 0xFC, 0x00
};
constexpr PROGMEM uint32_t UTF8_FONT_OFFSET = 10000;
constexpr PROGMEM bitmap_info_t File_Icon_Info = {
.format = L1,
.linestride = 4,
.filter = BILINEAR,
.wrapx = BORDER,
.wrapy = BORDER,
.RAMG_offset = 8429,
.width = 25,
.height = 32,
};
const unsigned char File_Icon[128] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x7F, 0xFE, 0x00, 0x00, 0x40, 0x03, 0x00, 0x00,
0x40, 0x02, 0x80, 0x00, 0x40, 0x02, 0x40, 0x00, 0x40, 0x02, 0x20, 0x00,
0x40, 0x02, 0x10, 0x00, 0x40, 0x02, 0x08, 0x00, 0x40, 0x02, 0x04, 0x00,
0x40, 0x02, 0x02, 0x00, 0x40, 0x03, 0xFF, 0x00, 0x40, 0x00, 0x01, 0x00,
0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00,
0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00,
0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00,
0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00,
0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00,
0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00,
0x7F, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00
};
constexpr PROGMEM bitmap_info_t Clock_Icon_Info = {
.format = L1,
.linestride = 4,
.filter = BILINEAR,
.wrapx = BORDER,
.wrapy = BORDER,
.RAMG_offset = 8557,
.width = 32,
.height = 32,
};
const unsigned char Clock_Icon[128] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x0F, 0xF0, 0x00, 0x00, 0x7E, 0x7E, 0x00,
0x00, 0xE0, 0x07, 0x00, 0x03, 0x80, 0x01, 0xC0, 0x07, 0x01, 0x00, 0xE0,
0x0C, 0x01, 0x80, 0x70, 0x0C, 0x01, 0x80, 0x30, 0x18, 0x01, 0x80, 0x18,
0x30, 0x01, 0x80, 0x08, 0x30, 0x01, 0x80, 0x0C, 0x20, 0x01, 0x80, 0x0C,
0x60, 0x01, 0x80, 0x04, 0x60, 0x01, 0x80, 0x06, 0x60, 0x01, 0x80, 0x06,
0x60, 0x01, 0xFF, 0x06, 0x60, 0x01, 0xFF, 0x06, 0x60, 0x00, 0x00, 0x06,
0x60, 0x00, 0x00, 0x06, 0x60, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x0C,
0x30, 0x00, 0x00, 0x0C, 0x30, 0x00, 0x00, 0x08, 0x18, 0x00, 0x00, 0x18,
0x0C, 0x00, 0x00, 0x30, 0x0E, 0x00, 0x00, 0x70, 0x07, 0x00, 0x00, 0xE0,
0x03, 0x80, 0x01, 0xC0, 0x00, 0xE0, 0x07, 0x00, 0x00, 0x7F, 0xFE, 0x00,
0x00, 0x0F, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00
};
constexpr PROGMEM uint32_t UTF8_FONT_OFFSET = 10000;
}; // namespace Theme

2
Marlin/src/lcd/extui/ftdi_eve_touch_ui/theme/sounds.cpp

@ -20,7 +20,7 @@
* location: <https://www.gnu.org/licenses/>. *
****************************************************************************/
#include "../compat.h"
#include "../config.h"
#if ENABLED(TOUCH_UI_FTDI_EVE)

6
Marlin/src/lcd/extui/ui_api.h

@ -190,7 +190,11 @@ namespace ExtUI {
void setHostResponse(const uint8_t);
#endif
inline void simulateUserClick() { ui.lcd_clicked = true; }
inline void simulateUserClick() {
#if EITHER(HAS_LCD_MENU, EXTENSIBLE_UI)
ui.lcd_clicked = true;
#endif
}
#if ENABLED(PRINTCOUNTER)
char* getFailedPrints_str(char buffer[21]);

26
Marlin/src/lcd/language/language_ru.h

@ -128,23 +128,28 @@ namespace Language_ru {
PROGMEM Language_Str MSG_COOLDOWN = _UxGT("Охлаждение");
PROGMEM Language_Str MSG_CUTTER_FREQUENCY = _UxGT("Частота");
PROGMEM Language_Str MSG_LASER_MENU = _UxGT("Управление лазером");
PROGMEM Language_Str MSG_LASER_TOGGLE = _UxGT("Переключить лазер");
PROGMEM Language_Str MSG_SPINDLE_MENU = _UxGT("Управление шпинделем");
PROGMEM Language_Str MSG_SPINDLE_TOGGLE = _UxGT("Переключить шпиндель");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_SPINDLE_MENU = _UxGT("Управление шпинделем");
PROGMEM Language_Str MSG_LASER_TOGGLE = _UxGT("Переключить лазер");
PROGMEM Language_Str MSG_SPINDLE_TOGGLE = _UxGT("Переключ.шпиндель");
PROGMEM Language_Str MSG_SPINDLE_POWER = _UxGT("Мощность шпинделя");
PROGMEM Language_Str MSG_LASER_POWER = _UxGT("Мощность лазера");
PROGMEM Language_Str MSG_LASER_PULSE_MS = _UxGT("Тестовый импульс мс");
PROGMEM Language_Str MSG_LASER_EVAC_TOGGLE = _UxGT("Переключить обдув");
PROGMEM Language_Str MSG_SPINDLE_EVAC_TOGGLE = _UxGT("Переключить вакуум");
#else
PROGMEM Language_Str MSG_SPINDLE_MENU = _UxGT("Управление шпинд.");
PROGMEM Language_Str MSG_LASER_TOGGLE = _UxGT("Переключ.лазер");
PROGMEM Language_Str MSG_SPINDLE_TOGGLE = _UxGT("Переключ.шпинд");
PROGMEM Language_Str MSG_SPINDLE_POWER = _UxGT("Мощн.шпинделя");
PROGMEM Language_Str MSG_LASER_POWER = _UxGT("Мощн. лазера");
PROGMEM Language_Str MSG_LASER_PULSE_MS = _UxGT("Тест. имп. мс");
PROGMEM Language_Str MSG_LASER_EVAC_TOGGLE = _UxGT("Переключ. обдув");
PROGMEM Language_Str MSG_SPINDLE_EVAC_TOGGLE = _UxGT("Переключ. вакуум");
#endif
PROGMEM Language_Str MSG_LASER_EVAC_TOGGLE = _UxGT("Переключить обдув");
PROGMEM Language_Str MSG_LASER_ASSIST_TOGGLE = _UxGT("Управление обдувом");
PROGMEM Language_Str MSG_FLOWMETER_FAULT = _UxGT("Ошибка обдува");
PROGMEM Language_Str MSG_LASER_FIRE_PULSE = _UxGT("Импульс лазера");
PROGMEM Language_Str MSG_SPINDLE_EVAC_TOGGLE = _UxGT("Переключить вакуум");
PROGMEM Language_Str MSG_SPINDLE_FORWARD = _UxGT("Шпиндель вперёд");
PROGMEM Language_Str MSG_SPINDLE_REVERSE = _UxGT("Инверсия шпинделя");
@ -357,13 +362,14 @@ namespace Language_ru {
PROGMEM Language_Str MSG_NOZZLE_STANDBY = _UxGT("Сопло ожидает");
PROGMEM Language_Str MSG_BED = _UxGT("Стол, ") LCD_STR_DEGREE "C";
PROGMEM Language_Str MSG_CHAMBER = _UxGT("Камера,") LCD_STR_DEGREE "C";
PROGMEM Language_Str MSG_COOLER = _UxGT("Охлаждение лазера");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Переключить охлаждение");
PROGMEM Language_Str MSG_FLOWMETER_SAFETY = _UxGT("Безопасность потока");
#else
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Переключить охлажд.");
PROGMEM Language_Str MSG_COOLER = _UxGT("Охлаждение лазера");
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Переключ. охлажд.");
PROGMEM Language_Str MSG_FLOWMETER_SAFETY = _UxGT("Безопасн. потока");
#else
PROGMEM Language_Str MSG_COOLER = _UxGT("Охлажд. лазера");
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Переключ. охл.");
PROGMEM Language_Str MSG_FLOWMETER_SAFETY = _UxGT("Безопас.потока");
#endif
PROGMEM Language_Str MSG_LASER = _UxGT("Лазер");
PROGMEM Language_Str MSG_FAN_SPEED = _UxGT("Кулер");

46
Marlin/src/lcd/language/language_uk.h

@ -34,7 +34,7 @@ namespace Language_uk {
using namespace Language_en; // Inherit undefined strings from English
constexpr uint8_t CHARSIZE = 2;
PROGMEM Language_Str LANGUAGE = _UxGT("Ukranian");
PROGMEM Language_Str LANGUAGE = _UxGT("Ukrainian");
PROGMEM Language_Str WELCOME_MSG = MACHINE_NAME _UxGT(" Готовий.");
PROGMEM Language_Str MSG_YES = _UxGT("ТАК");
@ -133,23 +133,24 @@ namespace Language_uk {
PROGMEM Language_Str MSG_SPINDLE_MENU = _UxGT("Керування шпінделем");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_LASER_POWER = _UxGT("Потужність лазера");
#else
PROGMEM Language_Str MSG_LASER_POWER = _UxGT("Потуж.лазера");
#endif
PROGMEM Language_Str MSG_SPINDLE_TOGGLE = _UxGT("Перемкнути шпіндель");
PROGMEM Language_Str MSG_LASER_TOGGLE = _UxGT("Перемкнути лазер");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_SPINDLE_POWER = _UxGT("Потуж. шпінделя");
PROGMEM Language_Str MSG_SPINDLE_TOGGLE = _UxGT("Перемкн. шпіндель");
PROGMEM Language_Str MSG_SPINDLE_EVAC_TOGGLE = _UxGT("Перемкнути вакуум");
PROGMEM Language_Str MSG_LASER_TOGGLE = _UxGT("Перемкнути лазер");
PROGMEM Language_Str MSG_SPINDLE_POWER = _UxGT("Потужн. шпінделя");
PROGMEM Language_Str MSG_LASER_PULSE_MS = _UxGT("Тестовий імпульс мс");
PROGMEM Language_Str MSG_LASER_EVAC_TOGGLE = _UxGT("Перемкнути обдув");
#else
PROGMEM Language_Str MSG_SPINDLE_POWER = _UxGT("Потуж. шпінд.");
PROGMEM Language_Str MSG_LASER_PULSE_MS = _UxGT("Тест. імп. мс");
PROGMEM Language_Str MSG_LASER_POWER = _UxGT("Потужн. лазера");
PROGMEM Language_Str MSG_SPINDLE_TOGGLE = _UxGT("Перемк. шпінд.");
PROGMEM Language_Str MSG_SPINDLE_EVAC_TOGGLE = _UxGT("Перемк. вакуум");
PROGMEM Language_Str MSG_LASER_TOGGLE = _UxGT("Перемкн. лазер");
PROGMEM Language_Str MSG_SPINDLE_POWER = _UxGT("Потужн. шпінд.");
PROGMEM Language_Str MSG_LASER_PULSE_MS = _UxGT("Тест. імп., мс");
PROGMEM Language_Str MSG_LASER_EVAC_TOGGLE = _UxGT("Перемкн. обдув");
#endif
PROGMEM Language_Str MSG_LASER_EVAC_TOGGLE = _UxGT("Перемкнути обдув");
PROGMEM Language_Str MSG_LASER_ASSIST_TOGGLE = _UxGT("Керування обдувом");
PROGMEM Language_Str MSG_FLOWMETER_FAULT = _UxGT("Помилка обдуву");
PROGMEM Language_Str MSG_LASER_FIRE_PULSE = _UxGT("Імпульс лазеру");
PROGMEM Language_Str MSG_SPINDLE_EVAC_TOGGLE = _UxGT("Перемкнути вакуум");
PROGMEM Language_Str MSG_SPINDLE_FORWARD = _UxGT("Шпіндель вперед");
PROGMEM Language_Str MSG_SPINDLE_REVERSE = _UxGT("Шпіндель назад");
@ -361,18 +362,19 @@ namespace Language_uk {
PROGMEM Language_Str MSG_NOZZLE_STANDBY = _UxGT("Сопло очікує");
PROGMEM Language_Str MSG_BED = _UxGT("Стіл, ") LCD_STR_DEGREE "C";
PROGMEM Language_Str MSG_CHAMBER = _UxGT("Камера,") LCD_STR_DEGREE "C";
PROGMEM Language_Str MSG_COOLER = _UxGT("Охолодження лазеру");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Перемкнути охолодження");
PROGMEM Language_Str MSG_COOLER = _UxGT("Охолодження лазеру");
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Перемк. охолодж.");
#else
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Перемкнути охолодж.");
PROGMEM Language_Str MSG_COOLER = _UxGT("Охолодж. лазеру");
PROGMEM Language_Str MSG_COOLER_TOGGLE = _UxGT("Перемк.охолод");
#endif
PROGMEM Language_Str MSG_FLOWMETER_SAFETY = _UxGT("Безпека потоку");
PROGMEM Language_Str MSG_LASER = _UxGT("Лазер");
PROGMEM Language_Str MSG_FAN_SPEED = _UxGT("Швидк. вент.");
PROGMEM Language_Str MSG_FAN_SPEED_N = _UxGT("Швидк. вент. ~");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_STORED_FAN_N = _UxGT("Збереж. швидк. вент. ~");
PROGMEM Language_Str MSG_STORED_FAN_N = _UxGT("Збереж.швидк.вент. ~");
PROGMEM Language_Str MSG_EXTRA_FAN_SPEED_N = _UxGT("Дод. швидк. вент. ~");
#else
PROGMEM Language_Str MSG_STORED_FAN_N = _UxGT("Збереж. вент. ~");
@ -391,8 +393,8 @@ namespace Language_uk {
PROGMEM Language_Str MSG_MAX = " " LCD_STR_THERMOMETER ", " LCD_STR_DEGREE _UxGT("С макс");
PROGMEM Language_Str MSG_FACTOR = " " LCD_STR_THERMOMETER _UxGT(" Фактор");
PROGMEM Language_Str MSG_AUTOTEMP = _UxGT("Автотемпер.");
PROGMEM Language_Str MSG_LCD_ON = _UxGT("Увімк");
PROGMEM Language_Str MSG_LCD_OFF = _UxGT("Вимк.");
PROGMEM Language_Str MSG_LCD_ON = _UxGT("Увім");
PROGMEM Language_Str MSG_LCD_OFF = _UxGT("Вимк");
PROGMEM Language_Str MSG_PID_AUTOTUNE = _UxGT("Автопідбір PID");
PROGMEM Language_Str MSG_PID_AUTOTUNE_E = _UxGT("Автопідбір PID *");
@ -426,8 +428,12 @@ namespace Language_uk {
PROGMEM Language_Str MSG_VMAX_K = _UxGT("Швидк.макс ") LCD_STR_K;
PROGMEM Language_Str MSG_VMAX_E = _UxGT("Швидк.макс ") LCD_STR_E;
PROGMEM Language_Str MSG_VMAX_EN = _UxGT("Швидк.макс *");
PROGMEM Language_Str MSG_VMIN = _UxGT("Швидк.мін");
PROGMEM Language_Str MSG_VTRAV_MIN = _UxGT("Переміщення мін");
PROGMEM Language_Str MSG_VMIN = _UxGT("Швидк. мін");
#if LCD_WIDTH > 21
PROGMEM Language_Str MSG_VTRAV_MIN = _UxGT("Переміщення мін");
#else
PROGMEM Language_Str MSG_VTRAV_MIN = _UxGT("Переміщ. мін");
#endif
PROGMEM Language_Str MSG_ACCELERATION = _UxGT("Прискорення, мм/с2");
PROGMEM Language_Str MSG_AMAX_A = _UxGT("Приск.макс ") LCD_STR_A;
PROGMEM Language_Str MSG_AMAX_B = _UxGT("Приск.макс ") LCD_STR_B;

17
Marlin/src/lcd/menu/menu_filament.cpp

@ -106,10 +106,11 @@ void _menu_temp_filament_op(const PauseMode mode, const int8_t extruder) {
* "Change Filament" submenu
*/
#if E_STEPPERS > 1 || ENABLED(FILAMENT_LOAD_UNLOAD_GCODES)
bool printingIsPaused();
#endif
void menu_change_filament() {
void menu_change_filament() {
#if E_STEPPERS > 1 || ENABLED(FILAMENT_LOAD_UNLOAD_GCODES)
// Say "filament change" when no print is active
editable.int8 = printingIsPaused() ? PAUSE_MODE_PAUSE_PRINT : PAUSE_MODE_CHANGE_FILAMENT;
@ -204,8 +205,16 @@ void _menu_temp_filament_op(const PauseMode mode, const int8_t extruder) {
#endif
END_MENU();
}
#endif
#else
if (thermalManager.targetHotEnoughToExtrude(active_extruder))
queue.inject_P(PSTR("M600B0"));
else
_menu_temp_filament_op(PAUSE_MODE_CHANGE_FILAMENT, 0);
#endif
}
static uint8_t hotend_status_extruder = 0;

18
Marlin/src/lcd/menu/menu_item.h

@ -434,23 +434,23 @@ class MenuItem_bool : public MenuEditItemBase {
}while(0)
// Indexed items set a global index value
#define _CONFIRM_ITEM_N_P(N, V...) _CONFIRM_ITEM_N_S_P(N, nullptr, V)
#define _CONFIRM_ITEM_N_P(N, V...) _CONFIRM_ITEM_N_S_P(N, nullptr, V)
#define CONFIRM_ITEM_P(PLABEL,A,B,V...) _CONFIRM_ITEM_P(PLABEL, GET_TEXT(A), GET_TEXT(B), ##V)
#define CONFIRM_ITEM(LABEL, V...) CONFIRM_ITEM_P(GET_TEXT(LABEL), ##V)
#define CONFIRM_ITEM_P(PLABEL,A,B,V...) _CONFIRM_ITEM_P(PLABEL, GET_TEXT(A), GET_TEXT(B), ##V)
#define CONFIRM_ITEM(LABEL, V...) CONFIRM_ITEM_P(GET_TEXT(LABEL), ##V)
#define YESNO_ITEM_P(PLABEL, V...) _CONFIRM_ITEM_P(PLABEL, ##V)
#define YESNO_ITEM(LABEL, V...) YESNO_ITEM_P(GET_TEXT(LABEL), ##V)
#define YESNO_ITEM_P(PLABEL, V...) CONFIRM_ITEM_P(PLABEL, MSG_YES, MSG_NO, ##V)
#define YESNO_ITEM(LABEL, V...) YESNO_ITEM_P(GET_TEXT(LABEL), ##V)
#define CONFIRM_ITEM_N_S_P(N,S,PLABEL,A,B,V...) _CONFIRM_ITEM_N_S_P(N, S, PLABEL, GET_TEXT(A), GET_TEXT(B), ##V)
#define CONFIRM_ITEM_N_S(N,S,LABEL,V...) CONFIRM_ITEM_N_S_P(N, S, GET_TEXT(LABEL), ##V)
#define CONFIRM_ITEM_N_P(N,PLABEL,A,B,V...) _CONFIRM_ITEM_N_P(N, PLABEL, GET_TEXT(A), GET_TEXT(B), ##V)
#define CONFIRM_ITEM_N(N,LABEL, V...) CONFIRM_ITEM_N_P(N, GET_TEXT(LABEL), ##V)
#define YESNO_ITEM_N_S_P(N,S,PLABEL, V...) _CONFIRM_ITEM_N_S_P(N, S, PLABEL, ##V)
#define YESNO_ITEM_N_S(N,S,LABEL, V...) YESNO_ITEM_N_S_P(N, S, GET_TEXT(LABEL), ##V)
#define YESNO_ITEM_N_P(N,PLABEL, V...) _CONFIRM_ITEM_N_P(N, PLABEL, ##V)
#define YESNO_ITEM_N(N,LABEL, V...) YESNO_ITEM_N_P(N, GET_TEXT(LABEL), ##V)
#define YESNO_ITEM_N_S_P(N,S,PLABEL, V...) _CONFIRM_ITEM_N_S_P(N, S, PLABEL, MSG_YES, MSG_NO, ##V)
#define YESNO_ITEM_N_S(N,S,LABEL, V...) YESNO_ITEM_N_S_P(N, S, GET_TEXT(LABEL), ##V)
#define YESNO_ITEM_N_P(N,PLABEL, V...) CONFIRM_ITEM_N_P(N, PLABEL, MSG_YES, MSG_NO, ##V)
#define YESNO_ITEM_N(N,LABEL, V...) YESNO_ITEM_N_P(N, GET_TEXT(LABEL), ##V)
#if ENABLED(LEVEL_BED_CORNERS)
void _lcd_level_bed_corners();

9
Marlin/src/lcd/menu/menu_main.cpp

@ -77,7 +77,6 @@ void menu_configuration();
#endif
#if ENABLED(ADVANCED_PAUSE_FEATURE)
void _menu_temp_filament_op(const PauseMode, const int8_t);
void menu_change_filament();
#endif
@ -365,10 +364,10 @@ void menu_main() {
#if ENABLED(ADVANCED_PAUSE_FEATURE)
#if E_STEPPERS == 1 && DISABLED(FILAMENT_LOAD_UNLOAD_GCODES)
if (thermalManager.targetHotEnoughToExtrude(active_extruder))
GCODES_ITEM(MSG_FILAMENTCHANGE, PSTR("M600 B0"));
else
SUBMENU(MSG_FILAMENTCHANGE, []{ _menu_temp_filament_op(PAUSE_MODE_CHANGE_FILAMENT, 0); });
YESNO_ITEM(MSG_FILAMENTCHANGE,
menu_change_filament, ui.goto_previous_screen,
GET_TEXT(MSG_FILAMENTCHANGE), (const char *)nullptr, PSTR("?")
);
#else
SUBMENU(MSG_FILAMENTCHANGE, menu_change_filament);
#endif

6
Marlin/src/pins/pins.h

@ -610,11 +610,11 @@
#elif MB(VAKE403D)
#include "stm32f4/pins_VAKE403D.h" // STM32F4
#elif MB(FYSETC_S6)
#include "stm32f4/pins_FYSETC_S6.h" // STM32F4 env:FYSETC_S6
#include "stm32f4/pins_FYSETC_S6.h" // STM32F4 env:FYSETC_S6 env:FYSETC_S6_8000
#elif MB(FYSETC_S6_V2_0)
#include "stm32f4/pins_FYSETC_S6_V2_0.h" // STM32F4 env:FYSETC_S6
#include "stm32f4/pins_FYSETC_S6_V2_0.h" // STM32F4 env:FYSETC_S6 env:FYSETC_S6_8000
#elif MB(FYSETC_SPIDER)
#include "stm32f4/pins_FYSETC_SPIDER.h" // STM32F4 env:FYSETC_S6
#include "stm32f4/pins_FYSETC_SPIDER.h" // STM32F4 env:FYSETC_S6 env:FYSETC_S6_8000
#elif MB(FLYF407ZG)
#include "stm32f4/pins_FLYF407ZG.h" // STM32F4 env:FLYF407ZG
#elif MB(MKS_ROBIN2)

4
Marlin/src/pins/stm32f4/pins_FYSETC_S6.h

@ -56,7 +56,9 @@
//
// Servos
//
#define SERVO0_PIN PA3
#ifndef SERVO0_PIN
#define SERVO0_PIN PA3
#endif
//
// Limit Switches

6
Marlin/src/pins/stm32f4/pins_FYSETC_SPIDER.h

@ -68,6 +68,12 @@
//
#define X_ENABLE_PIN PE9
//
// Servos
// Z_MAX_PIN only works in input mode
//
#define SERVO0_PIN PA2
#if HAS_TMC_UART
#define X_SERIAL_TX_PIN PE7
#define X_SERIAL_RX_PIN PE7

2
buildroot/share/PlatformIO/boards/marlin_fysetc_s6.json

@ -21,7 +21,7 @@
"name": "3D Printer control board",
"upload": {
"maximum_ram_size": 131072,
"maximum_size": 524288,
"maximum_size": 458752,
"protocol": "stlink",
"protocols": [
"jlink",

35
buildroot/share/PlatformIO/boards/marlin_fysetc_s6_8000.json

@ -0,0 +1,35 @@
{
"build": {
"cpu": "cortex-m4",
"extra_flags": "-DSTM32F446xx",
"f_cpu": "180000000L",
"mcu": "stm32f446ret6",
"variant": "MARLIN_FYSETC_S6"
},
"connectivity": [
"can"
],
"debug": {
"jlink_device": "STM32F446RE",
"openocd_target": "stm32f4x",
"svd_path": "STM32F446x.svd"
},
"frameworks": [
"arduino",
"stm32cube"
],
"name": "3D Printer control board",
"upload": {
"maximum_ram_size": 131072,
"maximum_size": 491520,
"protocol": "stlink",
"protocols": [
"jlink",
"stlink",
"blackmagic",
"serial"
]
},
"url": "https://www.st.com/en/microcontrollers-microprocessors/stm32f446.html",
"vendor": "FYSETC"
}

12
buildroot/share/PlatformIO/scripts/fix_framework_weakness.py

@ -30,15 +30,3 @@ if env.MarlinFeatureIsEnabled("POSTMORTEM_DEBUGGING"):
print("Done patching exception handler")
print("Libmaple modified and ready for post mortem debugging")
mf = env["MARLIN_FEATURES"]
rxBuf = mf["RX_BUFFER_SIZE"] if "RX_BUFFER_SIZE" in mf else "0"
txBuf = mf["TX_BUFFER_SIZE"] if "TX_BUFFER_SIZE" in mf else "0"
if int(rxBuf) < 64:
rxBuf = "64"
if int(txBuf) < 64:
txBuf = "64"
build_flags = env.get('BUILD_FLAGS')
build_flags.append("-DUSART_RX_BUF_SIZE=" + rxBuf + " -DUSART_TX_BUF_SIZE=" + txBuf)
env.Replace(BUILD_FLAGS=build_flags)

7
buildroot/share/PlatformIO/scripts/stm32_serialbuffer.py

@ -13,11 +13,16 @@ Import("env")
#
# The script will set the value as the default one (64 bytes)
# or the user-configured one, whichever is higher.
#
# Marlin has 128 and 32 as default values for RX_BUFFER_SIZE and
# TX_BUFFER_SIZE respectively. We use the highest value.
mf = env["MARLIN_FEATURES"]
rxBuf = str(max(64, int(mf["RX_BUFFER_SIZE"]) if "RX_BUFFER_SIZE" in mf else 0))
rxBuf = str(max(128, int(mf["RX_BUFFER_SIZE"]) if "RX_BUFFER_SIZE" in mf else 0))
txBuf = str(max(64, int(mf["TX_BUFFER_SIZE"]) if "TX_BUFFER_SIZE" in mf else 0))
build_flags = env.get('BUILD_FLAGS')
build_flags.append("-DSERIAL_RX_BUFFER_SIZE=" + rxBuf)
build_flags.append("-DSERIAL_TX_BUFFER_SIZE=" + txBuf)
build_flags.append("-DUSART_RX_BUF_SIZE=" + rxBuf)
build_flags.append("-DUSART_TX_BUF_SIZE=" + txBuf)
env.Replace(BUILD_FLAGS=build_flags)

4
ini/stm32f1-maple.ini

@ -36,6 +36,7 @@ lib_deps = ${common.lib_deps}
platform_packages = tool-stm32duino
extra_scripts = ${common.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/fix_framework_weakness.py
pre:buildroot/share/PlatformIO/scripts/stm32_serialbuffer.py
#
# STM32F103RC
@ -325,7 +326,8 @@ lib_ignore = ${common_stm32f1.lib_ignore}
platform = ${common_stm32f1.platform}
extends = common_stm32f1
board = marlin_CHITU_F103
extra_scripts = pre:buildroot/share/PlatformIO/scripts/common-dependencies.py
extra_scripts = ${common_stm32f1.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/common-dependencies.py
pre:buildroot/share/PlatformIO/scripts/STM32F1_create_variant.py
buildroot/share/PlatformIO/scripts/chitu_crypt.py
build_flags = ${common_stm32f1.build_flags}

4
ini/stm32f1.ini

@ -153,7 +153,7 @@ board_build.offset = 0x7000
board_build.ldscript = ldscript.ld
board_upload.offset_address = 0x08007000
build_unflags = ${common_stm32.build_unflags} -DUSBCON -DUSBD_USE_CDC
extra_scripts = ${common.extra_scripts}
extra_scripts = ${common_stm32.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
pre:buildroot/share/PlatformIO/scripts/random-bin.py
buildroot/share/PlatformIO/scripts/stm32_bootloader.py
@ -178,7 +178,7 @@ board_build.offset = 0x7000
board_build.ldscript = ldscript.ld
board_upload.offset_address = 0x08007000
build_unflags = ${common_stm32.build_unflags}
extra_scripts = ${common.extra_scripts}
extra_scripts = ${common_stm32.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
buildroot/share/PlatformIO/scripts/stm32_bootloader.py
debug_tool = jlink

19
ini/stm32f4.ini

@ -76,15 +76,28 @@ platform = ${common_stm32.platform}
extends = common_stm32
platform_packages = tool-stm32duino
board = marlin_fysetc_s6
build_flags = ${common_stm32.build_flags}
-DVECT_TAB_OFFSET=0x10000
-DHAL_PCD_MODULE_ENABLED
build_flags = ${common_stm32.build_flags} -DVECT_TAB_OFFSET=0x10000 -DHAL_PCD_MODULE_ENABLED
extra_scripts = ${common.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
debug_tool = stlink
upload_protocol = dfu
upload_command = dfu-util -a 0 -s 0x08010000:leave -D "$SOURCE"
#
# FYSETC S6 new bootloader
#
[env:FYSETC_S6_8000]
platform = ${common_stm32.platform}
extends = env:FYSETC_S6
board = marlin_fysetc_s6_8000
board_build.offset = 0x8000
board_upload.offset_address = 0x08008000
build_flags = ${common_stm32.build_flags} -DHAL_PCD_MODULE_ENABLED
extra_scripts = ${common.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
buildroot/share/PlatformIO/scripts/stm32_bootloader.py
upload_command = dfu-util -a 0 -s 0x08008000:leave -D "$SOURCE"
#
# STM32F407VET6 with RAMPS-like shield
# 'Black' STM32F407VET6 board - https://wiki.stm32duino.com/index.php?title=STM32F407

Loading…
Cancel
Save