Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
This commit is contained in:
commit
ee5186586d
48 changed files with 1580 additions and 1332 deletions
|
|
@ -2943,11 +2943,18 @@
|
|||
|
||||
#define SPINDLE_LASER_FREQUENCY 2500 // (Hz) Spindle/laser frequency (only on supported HALs: AVR and LPC)
|
||||
|
||||
//#define SPINDLE_SERVO // A servo converting an angle to spindle power
|
||||
#ifdef SPINDLE_SERVO
|
||||
#define SPINDLE_SERVO_NR 0 // Index of servo used for spindle control
|
||||
#define SPINDLE_SERVO_MIN 10 // Minimum angle for servo spindle
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Speed / Power can be set ('M3 S') and displayed in terms of:
|
||||
* - PWM255 (S0 - S255)
|
||||
* - PERCENT (S0 - S100)
|
||||
* - RPM (S0 - S50000) Best for use with a spindle
|
||||
* - SERVO (S0 - S180)
|
||||
*/
|
||||
#define CUTTER_POWER_UNIT PWM255
|
||||
|
||||
|
|
|
|||
|
|
@ -357,8 +357,8 @@ void SPIClass::setDataSize(uint32_t ds) {
|
|||
void SPIClass::updateSettings() {
|
||||
//SSP_DeInit(_currentSetting->spi_d); //todo: need force de init?!
|
||||
|
||||
// divide PCLK by 2 for SSP0
|
||||
CLKPWR_SetPCLKDiv(_currentSetting->spi_d == LPC_SSP0 ? CLKPWR_PCLKSEL_SSP0 : CLKPWR_PCLKSEL_SSP1, CLKPWR_PCLKSEL_CCLK_DIV_2);
|
||||
// Divide PCLK by 2 for SSP0
|
||||
//CLKPWR_SetPCLKDiv(_currentSetting->spi_d == LPC_SSP0 ? CLKPWR_PCLKSEL_SSP0 : CLKPWR_PCLKSEL_SSP1, CLKPWR_PCLKSEL_CCLK_DIV_2);
|
||||
|
||||
SSP_CFG_Type HW_SPI_init; // data structure to hold init values
|
||||
SSP_ConfigStructInit(&HW_SPI_init); // set values for SPI mode
|
||||
|
|
|
|||
|
|
@ -37,13 +37,14 @@
|
|||
#define DATA_SIZE_8BIT SSP_DATABIT_8
|
||||
#define DATA_SIZE_16BIT SSP_DATABIT_16
|
||||
|
||||
#define SPI_CLOCK_DIV2 8333333 //(SCR: 2) desired: 8,000,000 actual: 8,333,333 +4.2% SPI_FULL_SPEED
|
||||
#define SPI_CLOCK_DIV4 4166667 //(SCR: 5) desired: 4,000,000 actual: 4,166,667 +4.2% SPI_HALF_SPEED
|
||||
#define SPI_CLOCK_DIV8 2083333 //(SCR: 11) desired: 2,000,000 actual: 2,083,333 +4.2% SPI_QUARTER_SPEED
|
||||
#define SPI_CLOCK_DIV16 1000000 //(SCR: 24) desired: 1,000,000 actual: 1,000,000 SPI_EIGHTH_SPEED
|
||||
#define SPI_CLOCK_DIV32 500000 //(SCR: 49) desired: 500,000 actual: 500,000 SPI_SPEED_5
|
||||
#define SPI_CLOCK_DIV64 250000 //(SCR: 99) desired: 250,000 actual: 250,000 SPI_SPEED_6
|
||||
#define SPI_CLOCK_DIV128 125000 //(SCR:199) desired: 125,000 actual: 125,000 Default from HAL.h
|
||||
#define SPI_CLOCK_MAX_TFT 30000000UL
|
||||
#define SPI_CLOCK_DIV2 8333333 //(SCR: 2) desired: 8,000,000 actual: 8,333,333 +4.2% SPI_FULL_SPEED
|
||||
#define SPI_CLOCK_DIV4 4166667 //(SCR: 5) desired: 4,000,000 actual: 4,166,667 +4.2% SPI_HALF_SPEED
|
||||
#define SPI_CLOCK_DIV8 2083333 //(SCR: 11) desired: 2,000,000 actual: 2,083,333 +4.2% SPI_QUARTER_SPEED
|
||||
#define SPI_CLOCK_DIV16 1000000 //(SCR: 24) desired: 1,000,000 actual: 1,000,000 SPI_EIGHTH_SPEED
|
||||
#define SPI_CLOCK_DIV32 500000 //(SCR: 49) desired: 500,000 actual: 500,000 SPI_SPEED_5
|
||||
#define SPI_CLOCK_DIV64 250000 //(SCR: 99) desired: 250,000 actual: 250,000 SPI_SPEED_6
|
||||
#define SPI_CLOCK_DIV128 125000 //(SCR:199) desired: 125,000 actual: 125,000 Default from HAL.h
|
||||
|
||||
#define SPI_CLOCK_MAX SPI_CLOCK_DIV2
|
||||
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ void TFT_SPI::Init() {
|
|||
#elif TFT_MISO_PIN == BOARD_SPI2_MISO_PIN
|
||||
SPIx.setModule(2);
|
||||
#endif
|
||||
SPIx.setClock(SPI_CLOCK_MAX);
|
||||
SPIx.setClock(SPI_CLOCK_MAX_TFT);
|
||||
SPIx.setBitOrder(MSBFIRST);
|
||||
SPIx.setDataMode(SPI_MODE0);
|
||||
}
|
||||
|
|
@ -125,7 +125,7 @@ uint32_t TFT_SPI::ReadID(uint16_t Reg) {
|
|||
}
|
||||
|
||||
DataTransferEnd();
|
||||
SPIx.setClock(SPI_CLOCK_MAX);
|
||||
SPIx.setClock(SPI_CLOCK_MAX_TFT);
|
||||
#endif
|
||||
|
||||
return data >> 7;
|
||||
|
|
|
|||
|
|
@ -81,7 +81,9 @@ void HAL_init() {
|
|||
|
||||
SetTimerInterruptPriorities();
|
||||
|
||||
TERN_(EMERGENCY_PARSER, USB_Hook_init());
|
||||
#if ENABLED(EMERGENCY_PARSER) && USBD_USE_CDC
|
||||
USB_Hook_init();
|
||||
#endif
|
||||
}
|
||||
|
||||
void HAL_clear_reset_source() { __HAL_RCC_CLEAR_RESET_FLAGS(); }
|
||||
|
|
@ -128,8 +130,12 @@ uint16_t HAL_adc_get_result() { return HAL_adc_result; }
|
|||
void flashFirmware(const int16_t) { NVIC_SystemReset(); }
|
||||
|
||||
// Maple Compatibility
|
||||
volatile uint32_t systick_uptime_millis = 0;
|
||||
systickCallback_t systick_user_callback;
|
||||
void systick_attach_callback(systickCallback_t cb) { systick_user_callback = cb; }
|
||||
void HAL_SYSTICK_Callback() { if (systick_user_callback) systick_user_callback(); }
|
||||
void HAL_SYSTICK_Callback() {
|
||||
systick_uptime_millis++;
|
||||
if (systick_user_callback) systick_user_callback();
|
||||
}
|
||||
|
||||
#endif // ARDUINO_ARCH_STM32 && !STM32GENERIC
|
||||
|
|
|
|||
|
|
@ -184,3 +184,4 @@ void flashFirmware(const int16_t);
|
|||
typedef void (*systickCallback_t)(void);
|
||||
void systick_attach_callback(systickCallback_t cb);
|
||||
void HAL_SYSTICK_Callback();
|
||||
extern volatile uint32_t systick_uptime_millis;
|
||||
|
|
|
|||
|
|
@ -68,26 +68,23 @@
|
|||
#endif
|
||||
|
||||
#ifdef STM32F0xx
|
||||
#define MCU_TIMER_RATE (F_CPU) // Frequency of timer peripherals
|
||||
#define MCU_STEP_TIMER 16
|
||||
#define MCU_TEMP_TIMER 17
|
||||
#elif defined(STM32F1xx)
|
||||
#define MCU_TIMER_RATE (F_CPU)
|
||||
#define MCU_STEP_TIMER 4
|
||||
#define MCU_TEMP_TIMER 2
|
||||
#elif defined(STM32F401xC) || defined(STM32F401xE)
|
||||
#define MCU_TIMER_RATE (F_CPU / 2)
|
||||
#define MCU_STEP_TIMER 9
|
||||
#define MCU_TEMP_TIMER 10
|
||||
#elif defined(STM32F4xx) || defined(STM32F7xx)
|
||||
#define MCU_TIMER_RATE (F_CPU / 2)
|
||||
#define MCU_STEP_TIMER 6 // STM32F401 has no TIM6, TIM7, or TIM8
|
||||
#define MCU_TEMP_TIMER 14 // TIM7 is consumed by Software Serial if used.
|
||||
#endif
|
||||
|
||||
#ifndef HAL_TIMER_RATE
|
||||
#define HAL_TIMER_RATE MCU_TIMER_RATE
|
||||
#define HAL_TIMER_RATE GetStepperTimerClkFreq()
|
||||
#endif
|
||||
|
||||
#ifndef STEP_TIMER
|
||||
#define STEP_TIMER MCU_STEP_TIMER
|
||||
#endif
|
||||
|
|
@ -115,6 +112,13 @@ HardwareTimer *timer_instance[NUM_HARDWARE_TIMERS] = { nullptr };
|
|||
// Public functions
|
||||
// ------------------------
|
||||
|
||||
uint32_t GetStepperTimerClkFreq() {
|
||||
// Timer input clocks vary between devices, and in some cases between timers on the same device.
|
||||
// Retrieve at runtime to ensure device compatibility. Cache result to avoid repeated overhead.
|
||||
static uint32_t clkfreq = timer_instance[STEP_TIMER_NUM]->getTimerClkFreq();
|
||||
return clkfreq;
|
||||
}
|
||||
|
||||
// frequency is in Hertz
|
||||
void HAL_timer_start(const uint8_t timer_num, const uint32_t frequency) {
|
||||
if (!HAL_timer_initialized(timer_num)) {
|
||||
|
|
|
|||
|
|
@ -57,7 +57,8 @@
|
|||
|
||||
// TODO: get rid of manual rate/prescale/ticks/cycles taken for procedures in stepper.cpp
|
||||
#define STEPPER_TIMER_RATE 2000000 // 2 Mhz
|
||||
#define STEPPER_TIMER_PRESCALE ((HAL_TIMER_RATE)/(STEPPER_TIMER_RATE))
|
||||
extern uint32_t GetStepperTimerClkFreq();
|
||||
#define STEPPER_TIMER_PRESCALE (GetStepperTimerClkFreq() / (STEPPER_TIMER_RATE))
|
||||
#define STEPPER_TIMER_TICKS_PER_US ((STEPPER_TIMER_RATE) / 1000000) // stepper timer ticks per µs
|
||||
|
||||
#define PULSE_TIMER_RATE STEPPER_TIMER_RATE
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
#include "../../inc/MarlinConfigPre.h"
|
||||
|
||||
#if ENABLED(EMERGENCY_PARSER)
|
||||
#if ENABLED(EMERGENCY_PARSER) && USBD_USE_CDC
|
||||
|
||||
#include "usb_serial.h"
|
||||
#include "../../feature/e_parser.h"
|
||||
|
|
|
|||
|
|
@ -49,10 +49,6 @@
|
|||
#undef SDSS
|
||||
#define SDSS SS_PIN
|
||||
|
||||
#if ENABLED(ENABLE_SPI3)
|
||||
#define SPI_DEVICE 3
|
||||
#elif ENABLED(ENABLE_SPI2)
|
||||
#define SPI_DEVICE 2
|
||||
#else
|
||||
#ifndef SPI_DEVICE
|
||||
#define SPI_DEVICE 1
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -30,6 +30,10 @@
|
|||
|
||||
#include "spindle_laser.h"
|
||||
|
||||
#if ENABLED(SPINDLE_SERVO)
|
||||
#include "../module/servo.h"
|
||||
#endif
|
||||
|
||||
SpindleLaser cutter;
|
||||
uint8_t SpindleLaser::power;
|
||||
bool SpindleLaser::isReady; // Ready to apply power setting from the UI to OCR
|
||||
|
|
@ -45,7 +49,11 @@ cutter_power_t SpindleLaser::menuPower, // Power s
|
|||
// Init the cutter to a safe OFF state
|
||||
//
|
||||
void SpindleLaser::init() {
|
||||
OUT_WRITE(SPINDLE_LASER_ENA_PIN, !SPINDLE_LASER_ACTIVE_STATE); // Init spindle to off
|
||||
#if ENABLED(SPINDLE_SERVO)
|
||||
MOVE_SERVO(SPINDLE_SERVO_NR, SPINDLE_SERVO_MIN);
|
||||
#else
|
||||
OUT_WRITE(SPINDLE_LASER_ENA_PIN, !SPINDLE_LASER_ACTIVE_STATE); // Init spindle to off
|
||||
#endif
|
||||
#if ENABLED(SPINDLE_CHANGE_DIR)
|
||||
OUT_WRITE(SPINDLE_DIR_PIN, SPINDLE_INVERT_DIR ? 255 : 0); // Init rotation to clockwise (M3)
|
||||
#endif
|
||||
|
|
@ -97,6 +105,8 @@ void SpindleLaser::apply_power(const uint8_t opwr) {
|
|||
ocr_off();
|
||||
isReady = false;
|
||||
}
|
||||
#elif ENABLED(SPINDLE_SERVO)
|
||||
MOVE_SERVO(SPINDLE_SERVO_NR, power);
|
||||
#else
|
||||
WRITE(SPINDLE_LASER_ENA_PIN, enabled() ? SPINDLE_LASER_ACTIVE_STATE : !SPINDLE_LASER_ACTIVE_STATE);
|
||||
isReady = true;
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@
|
|||
#endif
|
||||
|
||||
#define PCT_TO_PWM(X) ((X) * 255 / 100)
|
||||
#define PCT_TO_SERVO(X) ((X) * 180 / 100)
|
||||
|
||||
#ifndef SPEED_POWER_INTERCEPT
|
||||
#define SPEED_POWER_INTERCEPT 0
|
||||
|
|
@ -60,7 +61,7 @@ public:
|
|||
}
|
||||
|
||||
// Convert a cpower (e.g., SPEED_POWER_STARTUP) to unit power (upwr, upower),
|
||||
// which can be PWM, Percent, or RPM (rel/abs).
|
||||
// which can be PWM, Percent, Servo angle, or RPM (rel/abs).
|
||||
static const inline cutter_power_t cpwr_to_upwr(const cutter_cpower_t cpwr) { // STARTUP power to Unit power
|
||||
const cutter_power_t upwr = (
|
||||
#if ENABLED(SPINDLE_FEATURE)
|
||||
|
|
@ -69,6 +70,8 @@ public:
|
|||
cpwr // to RPM
|
||||
#elif CUTTER_UNIT_IS(PERCENT) // to PCT
|
||||
cpwr_to_pct(cpwr)
|
||||
#elif CUTTER_UNIT_IS(SERVO) // to SERVO angle
|
||||
PCT_TO_SERVO(cpwr_to_pct(cpwr))
|
||||
#else // to PWM
|
||||
PCT_TO_PWM(cpwr_to_pct(cpwr))
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -69,9 +69,13 @@ void GcodeSuite::M3_M4(const bool is_M4) {
|
|||
auto get_s_power = [] {
|
||||
if (parser.seenval('S')) {
|
||||
const float spwr = parser.value_float();
|
||||
cutter.unitPower = TERN(SPINDLE_LASER_PWM,
|
||||
#if ENABLED(SPINDLE_SERVO)
|
||||
cutter.unitPower = spwr;
|
||||
#else
|
||||
cutter.unitPower = TERN(SPINDLE_LASER_PWM,
|
||||
cutter.power_to_range(cutter_power_t(round(spwr))),
|
||||
spwr > 0 ? 255 : 0);
|
||||
#endif
|
||||
}
|
||||
else
|
||||
cutter.unitPower = cutter.cpwr_to_upwr(SPEED_POWER_STARTUP);
|
||||
|
|
@ -108,6 +112,8 @@ void GcodeSuite::M3_M4(const bool is_M4) {
|
|||
}
|
||||
else
|
||||
cutter.set_power(cutter.upower_to_ocr(get_s_power()));
|
||||
#elif ENABLED(SPINDLE_SERVO)
|
||||
cutter.set_power(get_s_power());
|
||||
#else
|
||||
cutter.set_enabled(true);
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@
|
|||
// Determine NUM_SERVOS if none was supplied
|
||||
#ifndef NUM_SERVOS
|
||||
#define NUM_SERVOS 0
|
||||
#if ANY(CHAMBER_VENT, HAS_Z_SERVO_PROBE, SWITCHING_EXTRUDER, SWITCHING_NOZZLE)
|
||||
#if ANY(HAS_Z_SERVO_PROBE, CHAMBER_VENT, SWITCHING_TOOLHEAD, SWITCHING_EXTRUDER, SWITCHING_NOZZLE, SPINDLE_SERVO)
|
||||
#if NUM_SERVOS <= Z_PROBE_SERVO_NR
|
||||
#undef NUM_SERVOS
|
||||
#define NUM_SERVOS (Z_PROBE_SERVO_NR + 1)
|
||||
|
|
@ -62,6 +62,10 @@
|
|||
#undef NUM_SERVOS
|
||||
#define NUM_SERVOS (SWITCHING_EXTRUDER_E23_SERVO_NR + 1)
|
||||
#endif
|
||||
#if NUM_SERVOS <= SPINDLE_SERVO_NR
|
||||
#undef NUM_SERVOS
|
||||
#define NUM_SERVOS (SPINDLE_SERVO_NR + 1)
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -3007,8 +3007,8 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|||
#if HAS_CUTTER
|
||||
#ifndef CUTTER_POWER_UNIT
|
||||
#error "CUTTER_POWER_UNIT is required with a spindle or laser. Please update your Configuration_adv.h."
|
||||
#elif !CUTTER_UNIT_IS(PWM255) && !CUTTER_UNIT_IS(PERCENT) && !CUTTER_UNIT_IS(RPM)
|
||||
#error "CUTTER_POWER_UNIT must be PWM255, PERCENT, or RPM. Please update your Configuration_adv.h."
|
||||
#elif !CUTTER_UNIT_IS(PWM255) && !CUTTER_UNIT_IS(PERCENT) && !CUTTER_UNIT_IS(RPM) && !CUTTER_UNIT_IS(SERVO)
|
||||
#error "CUTTER_POWER_UNIT must be PWM255, PERCENT, RPM, or SERVO. Please update your Configuration_adv.h."
|
||||
#endif
|
||||
|
||||
#if ENABLED(LASER_POWER_INLINE)
|
||||
|
|
@ -3047,8 +3047,8 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|||
#define _PIN_CONFLICT(P) (PIN_EXISTS(P) && P##_PIN == SPINDLE_LASER_PWM_PIN)
|
||||
#if BOTH(SPINDLE_FEATURE, LASER_FEATURE)
|
||||
#error "Enable only one of SPINDLE_FEATURE or LASER_FEATURE."
|
||||
#elif !PIN_EXISTS(SPINDLE_LASER_ENA)
|
||||
#error "(SPINDLE|LASER)_FEATURE requires SPINDLE_LASER_ENA_PIN."
|
||||
#elif !PIN_EXISTS(SPINDLE_LASER_ENA) && DISABLED(SPINDLE_SERVO)
|
||||
#error "(SPINDLE|LASER)_FEATURE requires SPINDLE_LASER_ENA_PIN or SPINDLE_SERVO to control the power."
|
||||
#elif ENABLED(SPINDLE_CHANGE_DIR) && !PIN_EXISTS(SPINDLE_DIR)
|
||||
#error "SPINDLE_DIR_PIN is required for SPINDLE_CHANGE_DIR."
|
||||
#elif ENABLED(SPINDLE_LASER_PWM)
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@
|
|||
* version was tagged.
|
||||
*/
|
||||
#ifndef STRING_DISTRIBUTION_DATE
|
||||
#define STRING_DISTRIBUTION_DATE "2020-10-31"
|
||||
#define STRING_DISTRIBUTION_DATE "2020-11-02"
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
110
Marlin/src/lcd/dogm/status/bed.h
Normal file
110
Marlin/src/lcd/dogm/status/bed.h
Normal file
|
|
@ -0,0 +1,110 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* 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.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// lcd/dogm/status/bed.h - Status Screen Bed bitmaps
|
||||
//
|
||||
|
||||
#if ENABLED(STATUS_ALT_BED_BITMAP)
|
||||
|
||||
#define STATUS_BED_ANIM
|
||||
#define STATUS_BED_WIDTH 24
|
||||
#ifndef STATUS_BED_X
|
||||
#define STATUS_BED_X (LCD_PIXEL_WIDTH - (STATUS_BED_BYTEWIDTH + STATUS_CHAMBER_BYTEWIDTH + STATUS_FAN_BYTEWIDTH) * 8)
|
||||
#endif
|
||||
#define STATUS_BED_TEXT_X (STATUS_BED_X + 11)
|
||||
|
||||
const unsigned char status_bed_bmp[] PROGMEM = {
|
||||
B11111111,B11111111,B11000000,
|
||||
B01000000,B00000000,B00100000,
|
||||
B00100000,B00000000,B00010000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00001000,B00000000,B00000100,
|
||||
B00000100,B00000000,B00000010,
|
||||
B00000011,B11111111,B11111111
|
||||
};
|
||||
|
||||
const unsigned char status_bed_on_bmp[] PROGMEM = {
|
||||
B00000010,B00100010,B00000000,
|
||||
B00000100,B01000100,B00000000,
|
||||
B00000100,B01000100,B00000000,
|
||||
B00000010,B00100010,B00000000,
|
||||
B00000001,B00010001,B00000000,
|
||||
B11111111,B11111111,B11000000,
|
||||
B01000000,B10001000,B10100000,
|
||||
B00100001,B00010001,B00010000,
|
||||
B00010010,B00100010,B00001000,
|
||||
B00001000,B00000000,B00000100,
|
||||
B00000100,B00000000,B00000010,
|
||||
B00000011,B11111111,B11111111
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
#define STATUS_BED_WIDTH 21
|
||||
#ifndef STATUS_BED_X
|
||||
#define STATUS_BED_X (LCD_PIXEL_WIDTH - (STATUS_BED_BYTEWIDTH + STATUS_CHAMBER_BYTEWIDTH + STATUS_FAN_BYTEWIDTH) * 8)
|
||||
#endif
|
||||
|
||||
#ifdef STATUS_BED_ANIM
|
||||
|
||||
const unsigned char status_bed_bmp[] PROGMEM = {
|
||||
B00011111,B11111111,B11111000,
|
||||
B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
const unsigned char status_bed_on_bmp[] PROGMEM = {
|
||||
B00000100,B00010000,B01000000,
|
||||
B00000010,B00001000,B00100000,
|
||||
B00000010,B00001000,B00100000,
|
||||
B00000100,B00010000,B01000000,
|
||||
B00001000,B00100000,B10000000,
|
||||
B00010000,B01000001,B00000000,
|
||||
B00010000,B01000001,B00000000,
|
||||
B00001000,B00100000,B10000000,
|
||||
B00000100,B00010000,B01000000,
|
||||
B00000000,B00000000,B00000000,
|
||||
B00011111,B11111111,B11111000,
|
||||
B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
const unsigned char status_bed_bmp[] PROGMEM = {
|
||||
B00000100,B00010000,B01000000,
|
||||
B00000010,B00001000,B00100000,
|
||||
B00000010,B00001000,B00100000,
|
||||
B00000100,B00010000,B01000000,
|
||||
B00001000,B00100000,B10000000,
|
||||
B00010000,B01000001,B00000000,
|
||||
B00010000,B01000001,B00000000,
|
||||
B00001000,B00100000,B10000000,
|
||||
B00000100,B00010000,B01000000,
|
||||
B00000000,B00000000,B00000000,
|
||||
B00011111,B11111111,B11111000,
|
||||
B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
89
Marlin/src/lcd/dogm/status/chamber.h
Normal file
89
Marlin/src/lcd/dogm/status/chamber.h
Normal file
|
|
@ -0,0 +1,89 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* 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.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// lcd/dogm/status/chamber.h - Status Screen Chamber bitmaps
|
||||
//
|
||||
|
||||
#define STATUS_CHAMBER_WIDTH 21
|
||||
#if STATUS_HEATERS_WIDTH
|
||||
#if ENABLED(STATUS_COMBINE_HEATERS)
|
||||
#define STATUS_CHAMBER_X (LCD_PIXEL_WIDTH - 2 - (STATUS_CHAMBER_BYTEWIDTH) * 8)
|
||||
#elif HAS_FAN0 && HAS_HEATED_BED && HOTENDS <= 2
|
||||
#define STATUS_CHAMBER_X (LCD_PIXEL_WIDTH - 2 - (STATUS_HEATERS_BYTEWIDTH - STATUS_CHAMBER_BYTEWIDTH) * 8)
|
||||
#elif HAS_FAN0 && !HAS_HEATED_BED
|
||||
#define STATUS_CHAMBER_X (LCD_PIXEL_WIDTH - (STATUS_CHAMBER_BYTEWIDTH + STATUS_FAN_BYTEWIDTH) * 8)
|
||||
#else
|
||||
#define STATUS_CHAMBER_X (LCD_PIXEL_WIDTH - (STATUS_CHAMBER_BYTEWIDTH) * 8)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef STATUS_CHAMBER_ANIM
|
||||
|
||||
const unsigned char status_chamber_bmp[] PROGMEM = {
|
||||
B00011111,B11111111,B11111000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00011111,B11111111,B11111000,
|
||||
B00011111,B11111111,B11111000
|
||||
};
|
||||
const unsigned char status_chamber_on_bmp[] PROGMEM = {
|
||||
B00011111,B11111111,B11111000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B10000100,B00001000,
|
||||
B00010000,B01000010,B00001000,
|
||||
B00010000,B01000010,B00001000,
|
||||
B00010000,B10000100,B00001000,
|
||||
B00010001,B00001000,B00001000,
|
||||
B00010001,B00001000,B00001000,
|
||||
B00010000,B10000100,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00011111,B11111111,B11111000,
|
||||
B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
const unsigned char status_chamber_bmp[] PROGMEM = {
|
||||
B00011111,B11111111,B11111000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00010000,B10000100,B00001000,
|
||||
B00010000,B01000010,B00001000,
|
||||
B00010000,B01000010,B00001000,
|
||||
B00010000,B10000100,B00001000,
|
||||
B00010001,B00001000,B00001000,
|
||||
B00010001,B00001000,B00001000,
|
||||
B00010000,B10000100,B00001000,
|
||||
B00010000,B00000000,B00001000,
|
||||
B00011111,B11111111,B11111000,
|
||||
B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#endif
|
||||
236
Marlin/src/lcd/dogm/status/combined.h
Normal file
236
Marlin/src/lcd/dogm/status/combined.h
Normal file
|
|
@ -0,0 +1,236 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* 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.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// lcd/dogm/status/combined.h - Status Screen Combined Heater bitmaps
|
||||
//
|
||||
|
||||
#undef STATUS_HOTEND_ANIM
|
||||
#undef STATUS_BED_ANIM
|
||||
#define STATUS_HEATERS_XSPACE 24
|
||||
|
||||
#if HAS_HEATED_BED && HOTENDS <= 4
|
||||
|
||||
#if HOTENDS == 0
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 96
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00011111,B11111111,B11111000,
|
||||
B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#elif HOTENDS == 1
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 96
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00011111,B11100000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00011111,B11100000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00001111,B11000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,
|
||||
B00000111,B10000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00011111,B11111111,B11111000,
|
||||
B00000011,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#elif HOTENDS == 2
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 96
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,B00000000,B00000000,B00000000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00000000,B00000000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,B00000000,B00000000,B00000000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,B00000000,B00000000,B00000000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,B00000000,B00000000,B00000000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,B00000000,B00000000,B00000000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00000000,B00000000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,B00000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000000,B00000000,B00000000,B00011111,B11111111,B11111000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000000,B00000000,B00000000,B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#elif HOTENDS == 3
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 96
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,B00000000,B00111100,B11110000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,B00000000,B00111111,B01110000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,B00000000,B00011100,B11100000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,B00000000,B00011111,B01100000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,B00000000,B00111011,B01110000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,B00000000,B00111100,B11110000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00000000,B00000000,B00000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00011111,B11111111,B11111000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#else // HOTENDS > 3
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 120
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,B00000000,B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,B00000000,B00000010,B00001000,B00100000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,B00000000,B00111111,B01110000,B00000000,B00111011,B01110000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,B00000000,B00011100,B11100000,B00000000,B00011011,B01100000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,B00000000,B00011111,B01100000,B00000000,B00011000,B00100000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,B00000000,B00111011,B01110000,B00000000,B00111111,B01110000,B00000000,B00010000,B01000001,B00000000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,B00000000,B00111100,B11110000,B00000000,B00111111,B01110000,B00000000,B00001000,B00100000,B10000000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00000100,B00010000,B01000000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00000000,B00000000,B00000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00011111,B11111111,B11111000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00011111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#endif // HOTENDS
|
||||
|
||||
#define STATUS_BED_TEXT_X (STATUS_HEATERS_WIDTH - 10)
|
||||
|
||||
#else // !HAS_HEATED_BED || HOTENDS > 3
|
||||
|
||||
#if HOTENDS == 0
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 0
|
||||
|
||||
#elif HOTENDS == 1
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 12
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00011111,B11100000,
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#elif HOTENDS == 2
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 36
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000
|
||||
};
|
||||
|
||||
#elif HOTENDS == 3
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 60
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,B00000000,B00111100,B11110000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,B00000000,B00111111,B01110000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,B00000000,B00011100,B11100000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,B00000000,B00011111,B01100000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,B00000000,B00111011,B01110000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,B00000000,B00111100,B11110000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000
|
||||
};
|
||||
|
||||
#elif HOTENDS == 4
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 84
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,B00000000,B00111100,B11110000,B00000000,B00111011,B01110000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,B00000000,B00111111,B01110000,B00000000,B00111011,B01110000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,B00000000,B00011100,B11100000,B00000000,B00011011,B01100000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,B00000000,B00011111,B01100000,B00000000,B00011000,B00100000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,B00000000,B00111011,B01110000,B00000000,B00111111,B01110000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,B00000000,B00111100,B11110000,B00000000,B00111111,B01110000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000
|
||||
};
|
||||
|
||||
#else // HOTENDS > 4
|
||||
|
||||
#define STATUS_HEATERS_WIDTH 108
|
||||
|
||||
const unsigned char status_heaters_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,B00000000,B00011111,B11100000,
|
||||
B00111110,B11110000,B00000000,B00111100,B11110000,B00000000,B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00111000,B01110000,
|
||||
B00111100,B11110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,B00000000,B00111011,B01110000,B00000000,B00111011,B11110000,
|
||||
B00111010,B11110000,B00000000,B00111111,B01110000,B00000000,B00111111,B01110000,B00000000,B00111011,B01110000,B00000000,B00111000,B11110000,
|
||||
B00011110,B11100000,B00000000,B00011110,B11100000,B00000000,B00011100,B11100000,B00000000,B00011011,B01100000,B00000000,B00011111,B01100000,
|
||||
B00011110,B11100000,B00000000,B00011101,B11100000,B00000000,B00011111,B01100000,B00000000,B00011000,B00100000,B00000000,B00011111,B01100000,
|
||||
B00111110,B11110000,B00000000,B00111011,B11110000,B00000000,B00111011,B01110000,B00000000,B00111111,B01110000,B00000000,B00111011,B01110000,
|
||||
B00111110,B11110000,B00000000,B00111000,B01110000,B00000000,B00111100,B11110000,B00000000,B00111111,B01110000,B00000000,B00111100,B11110000,
|
||||
B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,B00000000,B00111111,B11110000,
|
||||
B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,B00000000,B00001111,B11000000,
|
||||
B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,B00000000,B00000111,B10000000,
|
||||
B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000,B00000000,B00000011,B00000000
|
||||
};
|
||||
|
||||
#endif // HOTENDS
|
||||
|
||||
#endif // !HAS_HEATED_BED || HOTENDS > 3
|
||||
123
Marlin/src/lcd/dogm/status/cutter.h
Normal file
123
Marlin/src/lcd/dogm/status/cutter.h
Normal file
|
|
@ -0,0 +1,123 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* 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.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// lcd/dogm/status/cutter.h - Status Screen Laser / Spindle bitmaps
|
||||
//
|
||||
|
||||
#define STATUS_CUTTER_WIDTH 24
|
||||
#define STATUS_CUTTER_X 80
|
||||
|
||||
#if ENABLED(LASER_FEATURE)
|
||||
#ifdef STATUS_CUTTER_ANIM
|
||||
const unsigned char status_cutter_on_bmp[] PROGMEM = {
|
||||
B00000000,B00100100,B00000000,
|
||||
B00000000,B01100110,B00000000,
|
||||
B00000000,B11000011,B00000000,
|
||||
B00000001,B10011001,B10000000,
|
||||
B00000011,B00100100,B11000000,
|
||||
B00000000,B01000010,B00000000,
|
||||
B00000000,B01000010,B00000000,
|
||||
B00000011,B00100100,B11000000,
|
||||
B00000001,B10011001,B10000000,
|
||||
B00000000,B11000011,B00000000,
|
||||
B00000000,B01100110,B00000000,
|
||||
B00000000,B00100100,B00000000
|
||||
};
|
||||
const unsigned char status_cutter_bmp[] PROGMEM = {
|
||||
B00000000,B00100100,B00000000,
|
||||
B00000000,B01100110,B00000000,
|
||||
B00000000,B00000000,B00000000,
|
||||
B00000001,B00000000,B10000000,
|
||||
B00000011,B00000000,B11000000,
|
||||
B00000000,B00011000,B00000000,
|
||||
B00000000,B00011000,B00000000,
|
||||
B00000011,B00000000,B11000000,
|
||||
B00000001,B00000000,B10000000,
|
||||
B00000000,B00000000,B00000000,
|
||||
B00000000,B01100110,B00000000,
|
||||
B00000000,B00100100,B00000000
|
||||
};
|
||||
#else
|
||||
const unsigned char status_cutter_bmp[] PROGMEM = {
|
||||
B00000000,B00100100,B00000000,
|
||||
B00000000,B01100110,B00000000,
|
||||
B00000000,B11000011,B00000000,
|
||||
B00000001,B10000001,B10000000,
|
||||
B00000011,B00000000,B11000000,
|
||||
B00000000,B00000000,B00000000,
|
||||
B00000000,B00000000,B00000000,
|
||||
B00000011,B00000000,B11000000,
|
||||
B00000001,B10000001,B10000000,
|
||||
B00000000,B11000011,B00000000,
|
||||
B00000000,B01100110,B00000000,
|
||||
B00000000,B00100100,B00000000
|
||||
};
|
||||
#endif
|
||||
#else
|
||||
#ifdef STATUS_CUTTER_ANIM
|
||||
const unsigned char status_cutter_on_bmp[] PROGMEM = {
|
||||
B00000001,B11111110,B10000000,
|
||||
B00000000,B11000000,B00000000,
|
||||
B00000001,B10000000,B10000000,
|
||||
B00000001,B00000000,B10000000,
|
||||
B00000001,B11111100,B10000000,
|
||||
B00000000,B11100000,B00000000,
|
||||
B00000001,B11000000,B10000000,
|
||||
B00000000,B10000001,B00000000,
|
||||
B00000000,B01111010,B00000000,
|
||||
B00000000,B00110100,B00000000,
|
||||
B00000000,B00011000,B00000000,
|
||||
B00000000,B00000000,B00000000
|
||||
};
|
||||
const unsigned char status_cutter_bmp[] PROGMEM = {
|
||||
B00000001,B11111110,B10000000,
|
||||
B00000000,B11000000,B00000000,
|
||||
B00000001,B10000000,B10000000,
|
||||
B00000001,B00000000,B10000000,
|
||||
B00000001,B11111100,B10000000,
|
||||
B00000000,B11100000,B00000000,
|
||||
B00000001,B11000000,B10000000,
|
||||
B00000000,B10000001,B00000000,
|
||||
B00000000,B01111010,B00000000,
|
||||
B00000000,B00110100,B00000000,
|
||||
B00000000,B00011000,B00000000,
|
||||
B00000000,B00000000,B00000000
|
||||
};
|
||||
#else
|
||||
const unsigned char status_cutter_bmp[] PROGMEM = {
|
||||
B00000001,B11000010,B10000000,
|
||||
B00000001,B00011100,B10000000,
|
||||
B00000000,B11100001,B00000000,
|
||||
B00000001,B00001110,B10000000,
|
||||
B00000001,B01110000,B10000000,
|
||||
B00000000,B10000111,B10000000,
|
||||
B00000001,B00111111,B10000000,
|
||||
B00000000,B11111111,B00000000,
|
||||
B00000000,B01111110,B00000000,
|
||||
B00000000,B00111100,B00000000,
|
||||
B00000000,B00011000,B00000000,
|
||||
B00000000,B00000000,B00000000
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
443
Marlin/src/lcd/dogm/status/fan.h
Normal file
443
Marlin/src/lcd/dogm/status/fan.h
Normal file
|
|
@ -0,0 +1,443 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* 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.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// lcd/dogm/status/fan.h - Status Screen Fan bitmaps
|
||||
//
|
||||
|
||||
#undef STATUS_FAN_WIDTH
|
||||
#define STATUS_FAN_WIDTH 20
|
||||
|
||||
#if STATUS_FAN_FRAMES <= 2
|
||||
|
||||
#define STATUS_FAN_Y 2
|
||||
|
||||
#if ENABLED(STATUS_ALT_FAN_BITMAP)
|
||||
|
||||
const unsigned char status_fan0_bmp[] PROGMEM = {
|
||||
B00000001,B11111110,B00000000,
|
||||
B00000110,B00000001,B10000000,
|
||||
B00001000,B11111100,B01000000,
|
||||
B00010000,B11111100,B00100000,
|
||||
B00010000,B01111000,B00100000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00101100,B00000000,B11010000,
|
||||
B00101110,B00110001,B11010000,
|
||||
B00101111,B01111011,B11010000,
|
||||
B00101111,B01111011,B11010000,
|
||||
B00101110,B00110001,B11010000,
|
||||
B00101100,B00000000,B11010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00010000,B01111000,B00100000,
|
||||
B00010000,B11111100,B00100000,
|
||||
B00001000,B11111100,B01000000,
|
||||
B00000110,B00000001,B10000000,
|
||||
B00000001,B11111110,B00000000
|
||||
};
|
||||
|
||||
#if STATUS_FAN_FRAMES == 2
|
||||
const unsigned char status_fan1_bmp[] PROGMEM = {
|
||||
B00000001,B11111110,B00000000,
|
||||
B00000110,B00000001,B10000000,
|
||||
B00001001,B10000110,B01000000,
|
||||
B00010011,B10000111,B00100000,
|
||||
B00010111,B10000111,B10100000,
|
||||
B00101111,B10000111,B11010000,
|
||||
B00101111,B00000011,B11010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00100000,B01111000,B00010000,
|
||||
B00100000,B01111000,B00010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00101111,B00000011,B11010000,
|
||||
B00101111,B10000111,B11010000,
|
||||
B00010111,B10000111,B10100000,
|
||||
B00010011,B10000111,B00100000,
|
||||
B00001001,B10000110,B01000000,
|
||||
B00000110,B00000001,B10000000,
|
||||
B00000001,B11111110,B00000000
|
||||
};
|
||||
#endif
|
||||
|
||||
#else // !STATUS_ALT_FAN_BITMAP
|
||||
|
||||
const unsigned char status_fan0_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11110000,
|
||||
B00111000,B00000000,B01110000,
|
||||
B00110000,B11111100,B00110000,
|
||||
B00100000,B11111100,B00010000,
|
||||
B00100000,B01111000,B00010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00101100,B00000000,B11010000,
|
||||
B00101110,B00110001,B11010000,
|
||||
B00101111,B01111011,B11010000,
|
||||
B00101111,B01111011,B11010000,
|
||||
B00101110,B00110001,B11010000,
|
||||
B00101100,B00000000,B11010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00100000,B01111000,B00010000,
|
||||
B00100000,B11111100,B00010000,
|
||||
B00110000,B11111100,B00110000,
|
||||
B00111000,B00000000,B01110000,
|
||||
B00111111,B11111111,B11110000
|
||||
};
|
||||
|
||||
#if STATUS_FAN_FRAMES == 2
|
||||
const unsigned char status_fan1_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11110000,
|
||||
B00111000,B00000000,B01110000,
|
||||
B00110001,B10000110,B00110000,
|
||||
B00100011,B10000111,B00010000,
|
||||
B00100111,B10000111,B10010000,
|
||||
B00101111,B10000111,B11010000,
|
||||
B00101111,B00000011,B11010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00100000,B01111000,B00010000,
|
||||
B00100000,B01111000,B00010000,
|
||||
B00100000,B00110000,B00010000,
|
||||
B00101111,B00000011,B11010000,
|
||||
B00101111,B10000111,B11010000,
|
||||
B00100111,B10000111,B10010000,
|
||||
B00100011,B10000111,B00010000,
|
||||
B00110001,B10000110,B00110000,
|
||||
B00111000,B00000000,B01110000,
|
||||
B00111111,B11111111,B11110000
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif // !STATUS_ALT_FAN_BITMAP
|
||||
|
||||
#elif STATUS_FAN_FRAMES == 3
|
||||
|
||||
#if ENABLED(STATUS_ALT_FAN_BITMAP)
|
||||
|
||||
const unsigned char status_fan0_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00001001,B00000001,B00100000,
|
||||
B00010111,B10000011,B11010000,
|
||||
B00010111,B10000011,B11010000,
|
||||
B00101111,B11000111,B11101000,
|
||||
B00100111,B11000111,B11001000,
|
||||
B00100001,B11111111,B00001000,
|
||||
B00100000,B01111100,B00001000,
|
||||
B00100000,B01111100,B00001000,
|
||||
B00100000,B01111100,B00001000,
|
||||
B00100001,B11111111,B00001000,
|
||||
B00100111,B11000111,B11001000,
|
||||
B00101111,B11000111,B11101000,
|
||||
B00010111,B10000011,B11010000,
|
||||
B00010111,B10000011,B11010000,
|
||||
B00001001,B00000001,B00100000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
const unsigned char status_fan1_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B00110000,B11000000,
|
||||
B00001001,B11110000,B00100000,
|
||||
B00010001,B11110000,B00010000,
|
||||
B00010000,B11110000,B00010000,
|
||||
B00100000,B11110000,B01101000,
|
||||
B00100000,B00110001,B11101000,
|
||||
B00100000,B00111001,B11101000,
|
||||
B00100000,B01111111,B11111000,
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111111,B11111100,B00001000,
|
||||
B00101111,B00111000,B00001000,
|
||||
B00101110,B00011000,B00001000,
|
||||
B00101100,B00011110,B00001000,
|
||||
B00010000,B00011110,B00010000,
|
||||
B00010000,B00011111,B00010000,
|
||||
B00001000,B00011111,B00100000,
|
||||
B00000110,B00011000,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
const unsigned char status_fan2_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B00011000,B11000000,
|
||||
B00001000,B00011111,B00100000,
|
||||
B00010000,B00011111,B10010000,
|
||||
B00010100,B00011111,B00010000,
|
||||
B00101110,B00011110,B00001000,
|
||||
B00101111,B00011100,B00001000,
|
||||
B00101111,B10111000,B00001000,
|
||||
B00111111,B11111100,B00001000,
|
||||
B00111111,B11111111,B11111000,
|
||||
B00100000,B01111111,B11111000,
|
||||
B00100000,B00111011,B11101000,
|
||||
B00100000,B01110001,B11101000,
|
||||
B00100000,B11110000,B11101000,
|
||||
B00010001,B11110000,B01010000,
|
||||
B00010011,B11110000,B00010000,
|
||||
B00001001,B11110000,B00100000,
|
||||
B00000110,B00110000,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
|
||||
#else // !STATUS_ALT_FAN_BITMAP
|
||||
|
||||
const unsigned char status_fan0_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111001,B00000001,B00111000,
|
||||
B00110111,B10000011,B11011000,
|
||||
B00110111,B10000011,B11011000,
|
||||
B00101111,B11000111,B11101000,
|
||||
B00100111,B11000111,B11001000,
|
||||
B00100001,B11111111,B00001000,
|
||||
B00100000,B01111100,B00001000,
|
||||
B00100000,B01111100,B00001000,
|
||||
B00100000,B01111100,B00001000,
|
||||
B00100001,B11111111,B00001000,
|
||||
B00100111,B11000111,B11001000,
|
||||
B00101111,B11000111,B11101000,
|
||||
B00110111,B10000011,B11011000,
|
||||
B00110111,B10000011,B11011000,
|
||||
B00111001,B00000001,B00111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
const unsigned char status_fan1_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B00110000,B11111000,
|
||||
B00111001,B11110000,B00111000,
|
||||
B00110001,B11110000,B00011000,
|
||||
B00110000,B11110000,B00011000,
|
||||
B00100000,B11110000,B01101000,
|
||||
B00100000,B00110001,B11101000,
|
||||
B00100000,B00111001,B11101000,
|
||||
B00100000,B01111111,B11111000,
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111111,B11111100,B00001000,
|
||||
B00101111,B00111000,B00001000,
|
||||
B00101110,B00011000,B00001000,
|
||||
B00101100,B00011110,B00001000,
|
||||
B00110000,B00011110,B00011000,
|
||||
B00110000,B00011111,B00011000,
|
||||
B00111000,B00011111,B00111000,
|
||||
B00111110,B00011000,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
const unsigned char status_fan2_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B00011000,B11111000,
|
||||
B00111000,B00011111,B00111000,
|
||||
B00110000,B00011111,B10011000,
|
||||
B00110100,B00011111,B00011000,
|
||||
B00101110,B00011110,B00001000,
|
||||
B00101111,B00011100,B00001000,
|
||||
B00101111,B10111000,B00001000,
|
||||
B00111111,B11111100,B00001000,
|
||||
B00111111,B11111111,B11111000,
|
||||
B00100000,B01111111,B11111000,
|
||||
B00100000,B00111011,B11101000,
|
||||
B00100000,B01110001,B11101000,
|
||||
B00100000,B11110000,B11101000,
|
||||
B00110001,B11110000,B01011000,
|
||||
B00110011,B11110000,B00011000,
|
||||
B00111001,B11110000,B00111000,
|
||||
B00111110,B00110000,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#endif // !STATUS_ALT_FAN_BITMAP
|
||||
|
||||
#elif STATUS_FAN_FRAMES == 4
|
||||
|
||||
#if ENABLED(STATUS_ALT_FAN_BITMAP)
|
||||
|
||||
const unsigned char status_fan0_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00001000,B00111111,B00100000,
|
||||
B00010000,B01111110,B00010000,
|
||||
B00010000,B01111100,B00010000,
|
||||
B00101000,B01111100,B00001000,
|
||||
B00101100,B00111000,B00001000,
|
||||
B00101111,B00111001,B11001000,
|
||||
B00101111,B11111111,B11101000,
|
||||
B00101111,B11000111,B11101000,
|
||||
B00101111,B11111111,B11101000,
|
||||
B00100111,B00111001,B11101000,
|
||||
B00100000,B00111000,B01101000,
|
||||
B00100000,B01111100,B00101000,
|
||||
B00010000,B01111100,B00010000,
|
||||
B00010000,B11111100,B00010000,
|
||||
B00001001,B11111000,B00100000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
const unsigned char status_fan1_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00001000,B00001111,B00100000,
|
||||
B00010100,B00011111,B11010000,
|
||||
B00010110,B00011111,B10010000,
|
||||
B00101111,B00011111,B00001000,
|
||||
B00101111,B10011110,B00001000,
|
||||
B00101111,B11111100,B00001000,
|
||||
B00101111,B11011100,B00001000,
|
||||
B00100111,B11101111,B11001000,
|
||||
B00100000,B01110111,B11101000,
|
||||
B00100000,B01111111,B11101000,
|
||||
B00100000,B11110011,B11101000,
|
||||
B00100001,B11110001,B11101000,
|
||||
B00010011,B11110000,B11010000,
|
||||
B00010111,B11110000,B01010000,
|
||||
B00001001,B11100000,B00100000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
const unsigned char status_fan2_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B10000000,B11000000,
|
||||
B00001001,B10000000,B00100000,
|
||||
B00010111,B10000001,B11010000,
|
||||
B00010111,B11000011,B11010000,
|
||||
B00100111,B11000111,B11101000,
|
||||
B00100011,B11000111,B11111000,
|
||||
B00100001,B11111111,B10001000,
|
||||
B00100000,B01101100,B00001000,
|
||||
B00100000,B01101100,B00001000,
|
||||
B00100000,B01101100,B00001000,
|
||||
B00100011,B11111111,B00001000,
|
||||
B00111111,B11000111,B10001000,
|
||||
B00101111,B11000111,B11001000,
|
||||
B00010111,B10000111,B11010000,
|
||||
B00010111,B00000011,B11010000,
|
||||
B00001000,B00000011,B00100000,
|
||||
B00000110,B00000010,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
const unsigned char status_fan3_bmp[] PROGMEM = {
|
||||
B00000001,B11111111,B00000000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00001001,B11110000,B00100000,
|
||||
B00010001,B11100000,B00010000,
|
||||
B00010001,B11100000,B00010000,
|
||||
B00100001,B11100001,B11101000,
|
||||
B00100000,B11110011,B11101000,
|
||||
B00100000,B01111111,B11101000,
|
||||
B00100000,B01110111,B11101000,
|
||||
B00101000,B11101110,B00101000,
|
||||
B00101111,B11011100,B00001000,
|
||||
B00101111,B11111100,B00001000,
|
||||
B00101111,B10011110,B00001000,
|
||||
B00101111,B00001111,B00001000,
|
||||
B00010000,B00001111,B00010000,
|
||||
B00010000,B00001111,B00010000,
|
||||
B00001000,B00011111,B00100000,
|
||||
B00000110,B00000000,B11000000,
|
||||
B00000001,B11111111,B00000000
|
||||
};
|
||||
|
||||
#else // !STATUS_ALT_FAN_BITMAP
|
||||
|
||||
const unsigned char status_fan0_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111000,B00111111,B00111000,
|
||||
B00110000,B01111110,B00011000,
|
||||
B00110000,B01111100,B00011000,
|
||||
B00101000,B01111100,B00001000,
|
||||
B00101100,B00111000,B00001000,
|
||||
B00101111,B00111001,B11001000,
|
||||
B00101111,B11111111,B11101000,
|
||||
B00101111,B11000111,B11101000,
|
||||
B00101111,B11111111,B11101000,
|
||||
B00100111,B00111001,B11101000,
|
||||
B00100000,B00111000,B01101000,
|
||||
B00100000,B01111100,B00101000,
|
||||
B00110000,B01111100,B00011000,
|
||||
B00110000,B11111100,B00011000,
|
||||
B00111001,B11111000,B00111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
const unsigned char status_fan1_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111000,B00001111,B00111000,
|
||||
B00110100,B00011111,B11011000,
|
||||
B00110110,B00011111,B10011000,
|
||||
B00101111,B00011111,B00001000,
|
||||
B00101111,B10011110,B00001000,
|
||||
B00101111,B11111100,B00001000,
|
||||
B00101111,B11011100,B00001000,
|
||||
B00100111,B11101111,B11001000,
|
||||
B00100000,B01110111,B11101000,
|
||||
B00100000,B01111111,B11101000,
|
||||
B00100000,B11110011,B11101000,
|
||||
B00100001,B11110001,B11101000,
|
||||
B00110011,B11110000,B11011000,
|
||||
B00110111,B11110000,B01011000,
|
||||
B00111001,B11100000,B00111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
const unsigned char status_fan2_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B10000000,B11111000,
|
||||
B00111001,B10000000,B00111000,
|
||||
B00110111,B10000001,B11011000,
|
||||
B00110111,B11000011,B11011000,
|
||||
B00100111,B11000111,B11101000,
|
||||
B00100011,B11000111,B11111000,
|
||||
B00100001,B11111111,B10001000,
|
||||
B00100000,B01101100,B00001000,
|
||||
B00100000,B01101100,B00001000,
|
||||
B00100000,B01101100,B00001000,
|
||||
B00100011,B11111111,B00001000,
|
||||
B00111111,B11000111,B10001000,
|
||||
B00101111,B11000111,B11001000,
|
||||
B00110111,B10000111,B11011000,
|
||||
B00110111,B00000011,B11011000,
|
||||
B00111000,B00000011,B00111000,
|
||||
B00111110,B00000010,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
const unsigned char status_fan3_bmp[] PROGMEM = {
|
||||
B00111111,B11111111,B11111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111001,B11110000,B00111000,
|
||||
B00110001,B11100000,B00011000,
|
||||
B00110001,B11100000,B00011000,
|
||||
B00100001,B11100001,B11101000,
|
||||
B00100000,B11110011,B11101000,
|
||||
B00100000,B01111111,B11101000,
|
||||
B00100000,B01110111,B11101000,
|
||||
B00101000,B11101110,B00101000,
|
||||
B00101111,B11011100,B00001000,
|
||||
B00101111,B11111100,B00001000,
|
||||
B00101111,B10011110,B00001000,
|
||||
B00101111,B00001111,B00001000,
|
||||
B00110000,B00001111,B00011000,
|
||||
B00110000,B00001111,B00011000,
|
||||
B00111000,B00011111,B00111000,
|
||||
B00111110,B00000000,B11111000,
|
||||
B00111111,B11111111,B11111000
|
||||
};
|
||||
|
||||
#endif // !STATUS_ALT_FAN_BITMAP
|
||||
|
||||
#endif
|
||||
336
Marlin/src/lcd/dogm/status/hotend.h
Normal file
336
Marlin/src/lcd/dogm/status/hotend.h
Normal file
|
|
@ -0,0 +1,336 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* 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.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// lcd/dogm/status/hotend.h - Status Screen Hotends bitmaps
|
||||
//
|
||||
|
||||
#define STATUS_HOTEND1_WIDTH 16
|
||||
|
||||
#define MAX_HOTEND_BITMAPS 5
|
||||
#if HOTENDS > MAX_HOTEND_BITMAPS
|
||||
#define STATUS_HOTEND_BITMAPS MAX_HOTEND_BITMAPS
|
||||
#else
|
||||
#define STATUS_HOTEND_BITMAPS HOTENDS
|
||||
#endif
|
||||
|
||||
#if HOTENDS == 1 || ENABLED(STATUS_HOTEND_NUMBERLESS)
|
||||
|
||||
const unsigned char status_hotend_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00011111,B11100000,
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#ifdef STATUS_HOTEND_ANIM
|
||||
|
||||
const unsigned char status_hotend_b_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00100000,B00010000,
|
||||
B00100000,B00010000,
|
||||
B00100000,B00010000,
|
||||
B00010000,B00100000,
|
||||
B00010000,B00100000,
|
||||
B00100000,B00010000,
|
||||
B00100000,B00010000,
|
||||
B00110000,B00110000,
|
||||
B00001000,B01000000,
|
||||
B00000100,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#elif HOTENDS >= 2
|
||||
|
||||
#ifdef STATUS_HOTEND_ANIM
|
||||
|
||||
const unsigned char status_hotend1_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111110,B11110000,
|
||||
B00111100,B11110000,
|
||||
B00011010,B11100000,
|
||||
B00011110,B11100000,
|
||||
B00111110,B11110000,
|
||||
B00111110,B11110000,
|
||||
B00111110,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend1_b_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00100000,B00010000,
|
||||
B00100001,B00010000,
|
||||
B00100011,B00010000,
|
||||
B00010101,B00100000,
|
||||
B00010001,B00100000,
|
||||
B00100001,B00010000,
|
||||
B00100001,B00010000,
|
||||
B00110001,B00110000,
|
||||
B00001000,B01000000,
|
||||
B00000100,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend2_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111100,B11110000,
|
||||
B00111011,B01110000,
|
||||
B00011111,B01100000,
|
||||
B00011110,B11100000,
|
||||
B00111101,B11110000,
|
||||
B00111011,B11110000,
|
||||
B00111000,B01110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend2_b_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00100000,B00010000,
|
||||
B00100011,B00010000,
|
||||
B00100100,B10010000,
|
||||
B00010000,B10100000,
|
||||
B00010001,B00100000,
|
||||
B00100010,B00010000,
|
||||
B00100100,B00010000,
|
||||
B00110111,B10110000,
|
||||
B00001000,B01000000,
|
||||
B00000100,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
const unsigned char status_hotend1_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111110,B11110000,
|
||||
B00111100,B11110000,
|
||||
B00111010,B11110000,
|
||||
B00011110,B11100000,
|
||||
B00011110,B11100000,
|
||||
B00111110,B11110000,
|
||||
B00111110,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend2_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111100,B11110000,
|
||||
B00111011,B01110000,
|
||||
B00111111,B01110000,
|
||||
B00011110,B11100000,
|
||||
B00011101,B11100000,
|
||||
B00111011,B11110000,
|
||||
B00111000,B01110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#if STATUS_HOTEND_BITMAPS >= 3
|
||||
|
||||
#ifdef STATUS_HOTEND_ANIM
|
||||
|
||||
const unsigned char status_hotend3_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111100,B11110000,
|
||||
B00111011,B01110000,
|
||||
B00011111,B01100000,
|
||||
B00011100,B11100000,
|
||||
B00111111,B01110000,
|
||||
B00111011,B01110000,
|
||||
B00111100,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend3_b_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00100000,B00010000,
|
||||
B00100011,B00010000,
|
||||
B00100100,B10010000,
|
||||
B00010000,B10100000,
|
||||
B00010011,B00100000,
|
||||
B00100000,B10010000,
|
||||
B00100100,B10010000,
|
||||
B00110011,B00110000,
|
||||
B00001000,B01000000,
|
||||
B00000100,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
const unsigned char status_hotend3_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111100,B11110000,
|
||||
B00111011,B01110000,
|
||||
B00111111,B01110000,
|
||||
B00011100,B11100000,
|
||||
B00011111,B01100000,
|
||||
B00111011,B01110000,
|
||||
B00111100,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#if STATUS_HOTEND_BITMAPS >= 4
|
||||
|
||||
#ifdef STATUS_HOTEND_ANIM
|
||||
|
||||
const unsigned char status_hotend4_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111011,B01110000,
|
||||
B00111011,B01110000,
|
||||
B00011011,B01100000,
|
||||
B00011011,B01100000,
|
||||
B00111000,B00110000,
|
||||
B00111111,B01110000,
|
||||
B00111111,B01110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend4_b_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00100000,B00010000,
|
||||
B00100100,B10010000,
|
||||
B00100100,B10010000,
|
||||
B00010100,B10100000,
|
||||
B00010100,B10100000,
|
||||
B00100111,B11010000,
|
||||
B00100000,B10010000,
|
||||
B00110000,B10110000,
|
||||
B00001000,B01000000,
|
||||
B00000100,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
const unsigned char status_hotend4_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111011,B01110000,
|
||||
B00111011,B01110000,
|
||||
B00111011,B01110000,
|
||||
B00011011,B01100000,
|
||||
B00011000,B00100000,
|
||||
B00111111,B01110000,
|
||||
B00111111,B01110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#if STATUS_HOTEND_BITMAPS >= 5
|
||||
|
||||
#ifdef STATUS_HOTEND_ANIM
|
||||
|
||||
const unsigned char status_hotend5_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111111,B11110000,
|
||||
B00111000,B01110000,
|
||||
B00111011,B11110000,
|
||||
B00011000,B11100000,
|
||||
B00011111,B01100000,
|
||||
B00111111,B01110000,
|
||||
B00111011,B01110000,
|
||||
B00111100,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
const unsigned char status_hotend5_b_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00100000,B00010000,
|
||||
B00100111,B10010000,
|
||||
B00100100,B00010000,
|
||||
B00010111,B00100000,
|
||||
B00010000,B10100000,
|
||||
B00100000,B10010000,
|
||||
B00100100,B10010000,
|
||||
B00110011,B00110000,
|
||||
B00001000,B01000000,
|
||||
B00000100,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
const unsigned char status_hotend5_a_bmp[] PROGMEM = {
|
||||
B00011111,B11100000,
|
||||
B00111000,B01110000,
|
||||
B00111011,B11110000,
|
||||
B00111000,B11110000,
|
||||
B00011111,B01100000,
|
||||
B00011111,B01100000,
|
||||
B00111011,B01110000,
|
||||
B00111100,B11110000,
|
||||
B00111111,B11110000,
|
||||
B00001111,B11000000,
|
||||
B00000111,B10000000,
|
||||
B00000011,B00000000
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
@ -33,6 +33,38 @@
|
|||
|
||||
#include "ultralcd_st7920_u8glib_rrd_AVR.h"
|
||||
|
||||
#if F_CPU >= 20000000
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(50)
|
||||
#elif MB(3DRAG, K8200, K8400)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(188)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#elif MB(MINIRAMBO, EINSY_RAMBO, EINSY_RETRO, SILVER_GATE)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(250)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#elif MB(RAMBO)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#elif MB(BQ_ZUM_MEGA_3D)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(189)
|
||||
#elif defined(ARDUINO_ARCH_STM32)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(300)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(40)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(340)
|
||||
#elif F_CPU == 16000000
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(63)
|
||||
#else
|
||||
#error "No valid condition for delays in 'ultralcd_st7920_u8glib_rrd_AVR.h'"
|
||||
#endif
|
||||
|
||||
#ifndef ST7920_DELAY_1
|
||||
#ifdef BOARD_ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 BOARD_ST7920_DELAY_1
|
||||
|
|
|
|||
|
|
@ -37,43 +37,6 @@
|
|||
|
||||
#include <U8glib.h>
|
||||
|
||||
// If you want you can define your own set of delays in Configuration.h
|
||||
//#define ST7920_DELAY_1 DELAY_NS(0)
|
||||
//#define ST7920_DELAY_2 DELAY_NS(0)
|
||||
//#define ST7920_DELAY_3 DELAY_NS(0)
|
||||
|
||||
#if F_CPU >= 20000000
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(50)
|
||||
#elif MB(3DRAG, K8200, K8400)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(188)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#elif MB(MINIRAMBO, EINSY_RAMBO, EINSY_RETRO, SILVER_GATE)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(250)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#elif MB(RAMBO)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#elif MB(BQ_ZUM_MEGA_3D)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(189)
|
||||
#elif defined(ARDUINO_ARCH_STM32)
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(300)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(40)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(340)
|
||||
#elif F_CPU == 16000000
|
||||
#define CPU_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_2 DELAY_NS(0)
|
||||
#define CPU_ST7920_DELAY_3 DELAY_NS(63)
|
||||
#else
|
||||
#error "No valid condition for delays in 'ultralcd_st7920_u8glib_rrd_AVR.h'"
|
||||
#endif
|
||||
|
||||
void ST7920_SWSPI_SND_8BIT(uint8_t val);
|
||||
|
||||
#if DOGM_SPI_DELAY_US > 0
|
||||
|
|
@ -82,8 +45,8 @@ void ST7920_SWSPI_SND_8BIT(uint8_t val);
|
|||
#define U8G_DELAY() DELAY_US(10)
|
||||
#endif
|
||||
|
||||
#define ST7920_CS() { WRITE(ST7920_CS_PIN,1); U8G_DELAY(); }
|
||||
#define ST7920_NCS() { WRITE(ST7920_CS_PIN,0); }
|
||||
#define ST7920_CS() { WRITE(ST7920_CS_PIN, HIGH); U8G_DELAY(); }
|
||||
#define ST7920_NCS() { WRITE(ST7920_CS_PIN, LOW); }
|
||||
#define ST7920_SET_CMD() { ST7920_SWSPI_SND_8BIT(0xF8); U8G_DELAY(); }
|
||||
#define ST7920_SET_DAT() { ST7920_SWSPI_SND_8BIT(0xFA); U8G_DELAY(); }
|
||||
#define ST7920_WRITE_BYTE(a) { ST7920_SWSPI_SND_8BIT((uint8_t)((a)&0xF0u)); ST7920_SWSPI_SND_8BIT((uint8_t)((a)<<4U)); U8G_DELAY(); }
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ void Touch::init() {
|
|||
enable();
|
||||
}
|
||||
|
||||
void Touch::add_control(TouchControlType type, uint16_t x, uint16_t y, uint16_t width, uint16_t height, int32_t data) {
|
||||
void Touch::add_control(TouchControlType type, uint16_t x, uint16_t y, uint16_t width, uint16_t height, intptr_t data) {
|
||||
if (controls_count == MAX_CONTROLS) return;
|
||||
|
||||
controls[controls_count].type = type;
|
||||
|
|
@ -306,7 +306,7 @@ bool MarlinUI::touch_pressed() {
|
|||
return touch.is_clicked();
|
||||
}
|
||||
|
||||
void add_control(uint16_t x, uint16_t y, TouchControlType control_type, int32_t data, MarlinImage image, bool is_enabled, uint16_t color_enabled, uint16_t color_disabled) {
|
||||
void add_control(uint16_t x, uint16_t y, TouchControlType control_type, intptr_t data, MarlinImage image, bool is_enabled, uint16_t color_enabled, uint16_t color_disabled) {
|
||||
uint16_t width = Images[image].width;
|
||||
uint16_t height = Images[image].height;
|
||||
tft.canvas(x, y, width, height);
|
||||
|
|
|
|||
|
|
@ -85,9 +85,9 @@ enum TouchControlType : uint16_t {
|
|||
|
||||
typedef void (*screenFunc_t)();
|
||||
|
||||
void add_control(uint16_t x, uint16_t y, TouchControlType control_type, int32_t data, MarlinImage image, bool is_enabled = true, uint16_t color_enabled = COLOR_CONTROL_ENABLED, uint16_t color_disabled = COLOR_CONTROL_DISABLED);
|
||||
void add_control(uint16_t x, uint16_t y, TouchControlType control_type, intptr_t data, MarlinImage image, bool is_enabled = true, uint16_t color_enabled = COLOR_CONTROL_ENABLED, uint16_t color_disabled = COLOR_CONTROL_DISABLED);
|
||||
inline void add_control(uint16_t x, uint16_t y, TouchControlType control_type, MarlinImage image, bool is_enabled = true, uint16_t color_enabled = COLOR_CONTROL_ENABLED, uint16_t color_disabled = COLOR_CONTROL_DISABLED) { add_control(x, y, control_type, 0, image, is_enabled, color_enabled, color_disabled); }
|
||||
inline void add_control(uint16_t x, uint16_t y, screenFunc_t screen, MarlinImage image, bool is_enabled = true, uint16_t color_enabled = COLOR_CONTROL_ENABLED, uint16_t color_disabled = COLOR_CONTROL_DISABLED) { add_control(x, y, MENU_SCREEN, (int32_t)screen, image, is_enabled, color_enabled, color_disabled); }
|
||||
inline void add_control(uint16_t x, uint16_t y, screenFunc_t screen, MarlinImage image, bool is_enabled = true, uint16_t color_enabled = COLOR_CONTROL_ENABLED, uint16_t color_disabled = COLOR_CONTROL_DISABLED) { add_control(x, y, MENU_SCREEN, (intptr_t)screen, image, is_enabled, color_enabled, color_disabled); }
|
||||
|
||||
typedef struct __attribute__((__packed__)) {
|
||||
TouchControlType type;
|
||||
|
|
@ -95,7 +95,7 @@ typedef struct __attribute__((__packed__)) {
|
|||
uint16_t y;
|
||||
uint16_t width;
|
||||
uint16_t height;
|
||||
int32_t data;
|
||||
intptr_t data;
|
||||
} touch_control_t;
|
||||
|
||||
typedef struct __attribute__((__packed__)) {
|
||||
|
|
@ -158,7 +158,7 @@ class Touch {
|
|||
|
||||
public:
|
||||
static void init();
|
||||
static void reset() { controls_count = 0; touch_time = -1; current_control = NULL; }
|
||||
static void reset() { controls_count = 0; touch_time = 0; current_control = NULL; }
|
||||
static void clear() { controls_count = 0; }
|
||||
static void idle();
|
||||
static bool is_clicked() {
|
||||
|
|
@ -171,7 +171,7 @@ class Touch {
|
|||
static void disable() { enabled = false; }
|
||||
static void enable() { enabled = true; }
|
||||
|
||||
static void add_control(TouchControlType type, uint16_t x, uint16_t y, uint16_t width, uint16_t height, int32_t data = 0);
|
||||
static void add_control(TouchControlType type, uint16_t x, uint16_t y, uint16_t width, uint16_t height, intptr_t data = 0);
|
||||
|
||||
static touch_calibration_t calibration;
|
||||
static void calibration_reset() { calibration = {TOUCH_CALIBRATION_X, TOUCH_CALIBRATION_Y, TOUCH_OFFSET_X, TOUCH_OFFSET_Y, TOUCH_ORIENTATION}; }
|
||||
|
|
|
|||
|
|
@ -249,6 +249,59 @@
|
|||
#define LCD_PINS_ENABLE P1_22
|
||||
#define LCD_PINS_D4 P0_17
|
||||
|
||||
#elif HAS_SPI_TFT // Config for Classic UI (emulated DOGM) and Color UI
|
||||
#define TFT_CS_PIN P1_00
|
||||
#define TFT_A0_PIN P1_22
|
||||
#define TFT_DC_PIN P1_22
|
||||
#define TFT_MISO_PIN P0_08
|
||||
#define TFT_BACKLIGHT_PIN P0_18
|
||||
#define TFT_RESET_PIN P0_16
|
||||
|
||||
#define LCD_USE_DMA_SPI
|
||||
|
||||
#define TOUCH_INT_PIN P0_17
|
||||
#define TOUCH_CS_PIN P0_15
|
||||
#define TOUCH_BUTTONS_HW_SPI
|
||||
#define TOUCH_BUTTONS_HW_SPI_DEVICE 2
|
||||
|
||||
// Disable any LCD related PINs config
|
||||
#define LCD_PINS_ENABLE -1
|
||||
#define LCD_PINS_RS -1
|
||||
|
||||
// XPT2046 Touch Screen calibration
|
||||
#if ENABLED(TFT_CLASSIC_UI)
|
||||
#ifndef XPT2046_X_CALIBRATION
|
||||
#define XPT2046_X_CALIBRATION -11386
|
||||
#endif
|
||||
#ifndef XPT2046_Y_CALIBRATION
|
||||
#define XPT2046_Y_CALIBRATION 8684
|
||||
#endif
|
||||
#ifndef XPT2046_X_OFFSET
|
||||
#define XPT2046_X_OFFSET 689
|
||||
#endif
|
||||
#ifndef XPT2046_Y_OFFSET
|
||||
#define XPT2046_Y_OFFSET -273
|
||||
#endif
|
||||
#elif ENABLED(TFT_COLOR_UI)
|
||||
#ifndef XPT2046_X_CALIBRATION
|
||||
#define XPT2046_X_CALIBRATION -16741
|
||||
#endif
|
||||
#ifndef XPT2046_Y_CALIBRATION
|
||||
#define XPT2046_Y_CALIBRATION 11258
|
||||
#endif
|
||||
#ifndef XPT2046_X_OFFSET
|
||||
#define XPT2046_X_OFFSET 1024
|
||||
#endif
|
||||
#ifndef XPT2046_Y_OFFSET
|
||||
#define XPT2046_Y_OFFSET -367
|
||||
#endif
|
||||
|
||||
#define TFT_BUFFER_SIZE 2400
|
||||
#endif
|
||||
|
||||
#define BTN_EN1 P3_25
|
||||
#define BTN_EN2 P3_26
|
||||
|
||||
#elif IS_TFTGLCD_PANEL
|
||||
|
||||
#undef BEEPER_PIN
|
||||
|
|
|
|||
|
|
@ -871,6 +871,9 @@
|
|||
#undef ST7920_DELAY_1
|
||||
#undef ST7920_DELAY_2
|
||||
#undef ST7920_DELAY_3
|
||||
#undef BOARD_ST7920_DELAY_1
|
||||
#undef BOARD_ST7920_DELAY_2
|
||||
#undef BOARD_ST7920_DELAY_3
|
||||
#endif
|
||||
|
||||
#undef HAS_FREE_AUX2_PINS
|
||||
|
|
|
|||
|
|
@ -210,14 +210,13 @@
|
|||
#endif
|
||||
|
||||
#if SD_CONNECTION_IS(LCD)
|
||||
#define ENABLE_SPI3
|
||||
#define SPI_DEVICE 3
|
||||
#define SD_DETECT_PIN PB9
|
||||
#define SCK_PIN PB3
|
||||
#define MISO_PIN PB4
|
||||
#define MOSI_PIN PB5
|
||||
#define SS_PIN PA15
|
||||
#elif SD_CONNECTION_IS(ONBOARD)
|
||||
#define ENABLE_SPI1
|
||||
#define SD_DETECT_PIN PA3
|
||||
#define SCK_PIN PA5
|
||||
#define MISO_PIN PA6
|
||||
|
|
|
|||
|
|
@ -165,7 +165,6 @@
|
|||
// SD-NAND
|
||||
//
|
||||
#if SD_CONNECTION_IS(ONBOARD)
|
||||
#define ENABLE_SPI1
|
||||
#define SD_DETECT_PIN -1
|
||||
#define SCK_PIN PA5
|
||||
#define MISO_PIN PA6
|
||||
|
|
|
|||
|
|
@ -185,7 +185,7 @@
|
|||
|
||||
// SPI1(PA7)=LCD & SPI3(PB5)=STUFF, are not available
|
||||
// Needs to use SPI2
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN PB14
|
||||
#define MOSI_PIN PB15
|
||||
|
|
|
|||
|
|
@ -200,7 +200,7 @@
|
|||
|
||||
// SPI1(PA7)=LCD & SPI3(PB5)=STUFF, are not available
|
||||
// so SPI2 is required.
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN PB14
|
||||
#define MOSI_PIN PB15
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@
|
|||
// SPI
|
||||
// Note: FLSun Hispeed (clone MKS_Robin_miniV2) board is using SPI2 interface.
|
||||
//
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
// SPI Flash
|
||||
#define HAS_SPI_FLASH 1
|
||||
|
|
|
|||
|
|
@ -132,7 +132,7 @@
|
|||
//
|
||||
// LCD / Controller
|
||||
//
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
#define SS_PIN PB12
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN PB14
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@
|
|||
#endif
|
||||
|
||||
// SPI1(PA7) & SPI3(PB5) not available
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
#if ENABLED(SDIO_SUPPORT)
|
||||
#define SCK_PIN PB13 // SPI2
|
||||
|
|
|
|||
|
|
@ -55,8 +55,7 @@
|
|||
//
|
||||
// Note: MKS Robin board is using SPI2 interface.
|
||||
//
|
||||
//#define SPI_MODULE 2
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
|
|
|||
|
|
@ -167,7 +167,7 @@
|
|||
//
|
||||
// SD Card
|
||||
//
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
#define SD_DETECT_PIN PC10
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN PB14
|
||||
|
|
|
|||
|
|
@ -34,7 +34,6 @@
|
|||
|
||||
//#define DISABLE_DEBUG
|
||||
#define DISABLE_JTAG
|
||||
#define ENABLE_SPI2
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
|
@ -135,8 +134,12 @@
|
|||
//
|
||||
// SD Card
|
||||
//
|
||||
#define ENABLE_SPI2
|
||||
#define SD_DETECT_PIN PC10
|
||||
|
||||
//
|
||||
// SPI
|
||||
//
|
||||
#define SPI_DEVICE 2
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN P1B4
|
||||
#define MOSI_PIN P1B5
|
||||
|
|
|
|||
|
|
@ -38,7 +38,6 @@
|
|||
|
||||
//#define DISABLE_DEBUG
|
||||
#define DISABLE_JTAG
|
||||
#define ENABLE_SPI2
|
||||
|
||||
//
|
||||
// Servos
|
||||
|
|
@ -87,9 +86,9 @@
|
|||
//
|
||||
// Temperature Sensors
|
||||
//
|
||||
#define TEMP_BED_PIN PA1 //TB
|
||||
#define TEMP_0_PIN PA0 //TH1
|
||||
#define TEMP_1_PIN PA2 //TH2
|
||||
#define TEMP_BED_PIN PA1 // TB
|
||||
#define TEMP_0_PIN PA0 // TH1
|
||||
#define TEMP_1_PIN PA2 // TH2
|
||||
|
||||
#define FIL_RUNOUT_PIN PB10 // MT_DET
|
||||
|
||||
|
|
@ -132,24 +131,22 @@
|
|||
|
||||
#endif // !MKS_MINI_12864
|
||||
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
|
||||
#endif // HAS_WIRED_LCD
|
||||
|
||||
//
|
||||
// SD Card
|
||||
//
|
||||
#define ENABLE_SPI2
|
||||
#define SD_DETECT_PIN PC10
|
||||
|
||||
//
|
||||
// SPI
|
||||
//
|
||||
#define SPI_DEVICE 2
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN PB14
|
||||
#define MOSI_PIN PB15
|
||||
#define SS_PIN PA15
|
||||
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@
|
|||
#define MARLIN_EEPROM_SIZE EEPROM_PAGE_SIZE // 2KB
|
||||
#endif
|
||||
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@
|
|||
#define MARLIN_EEPROM_SIZE EEPROM_PAGE_SIZE // 2KB
|
||||
#endif
|
||||
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
|
|
|||
|
|
@ -55,8 +55,7 @@
|
|||
//
|
||||
// Note: MKS Robin board is using SPI2 interface.
|
||||
//
|
||||
//#define SPI_MODULE 2
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
|
|
|||
|
|
@ -41,8 +41,7 @@
|
|||
//
|
||||
// Note: MKS Robin board is using SPI2 interface.
|
||||
//
|
||||
//#define SPI_MODULE 2
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
//
|
||||
// Servos
|
||||
|
|
@ -191,7 +190,6 @@
|
|||
#endif
|
||||
|
||||
#if SD_CONNECTION_IS(LCD)
|
||||
#define ENABLE_SPI2
|
||||
#define SD_DETECT_PIN PG3
|
||||
#define SCK_PIN PB13
|
||||
#define MISO_PIN PB14
|
||||
|
|
|
|||
|
|
@ -173,7 +173,7 @@
|
|||
#endif
|
||||
|
||||
// SPI1(PA7) & SPI3(PB5) not available
|
||||
#define ENABLE_SPI2
|
||||
#define SPI_DEVICE 2
|
||||
|
||||
#if ENABLED(SDIO_SUPPORT)
|
||||
#define SCK_PIN PB13 // SPI2 ok
|
||||
|
|
|
|||
|
|
@ -46,8 +46,6 @@
|
|||
#define FLASH_EEPROM_LEVELING
|
||||
#endif
|
||||
|
||||
#define ENABLE_SPI1
|
||||
|
||||
#include "pins_RUMBA32_common.h"
|
||||
|
||||
#if HAS_TMC_UART
|
||||
|
|
|
|||
|
|
@ -47,7 +47,6 @@
|
|||
|
||||
#define STEP_TIMER 10
|
||||
#define TEMP_TIMER 14
|
||||
#define HAL_TIMER_RATE F_CPU
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
|
|
|||
|
|
@ -10,3 +10,13 @@ env.Append(CXXFLAGS=[
|
|||
#"-Wno-maybe-uninitialized",
|
||||
#"-Wno-sign-compare"
|
||||
])
|
||||
|
||||
# Useful for JTAG debugging
|
||||
#
|
||||
# It will separe release and debug build folders.
|
||||
# It useful when we need keep two live versions: one debug, for debugging,
|
||||
# other release, for flashing.
|
||||
# Without this, PIO will recompile everything twice for any small change.
|
||||
#
|
||||
if env.GetBuildType() == "debug":
|
||||
env['BUILD_DIR'] = '$PROJECT_BUILD_DIR/$PIOENV/debug'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue