Creality Ender board support
This commit is contained in:
parent
9a2dd0bc5a
commit
f887719a40
@ -176,6 +176,9 @@ MCU ?= atmega1284p
|
|||||||
else ifeq ($(HARDWARE_MOTHERBOARD),69)
|
else ifeq ($(HARDWARE_MOTHERBOARD),69)
|
||||||
HARDWARE_VARIANT ?= Sanguino
|
HARDWARE_VARIANT ?= Sanguino
|
||||||
MCU ?= atmega1284p
|
MCU ?= atmega1284p
|
||||||
|
else ifeq ($(HARDWARE_MOTHERBOARD),601)
|
||||||
|
HARDWARE_VARIANT ?= Sanguino
|
||||||
|
MCU ?= atmega1284p
|
||||||
|
|
||||||
#Ultimaker
|
#Ultimaker
|
||||||
else ifeq ($(HARDWARE_MOTHERBOARD),7)
|
else ifeq ($(HARDWARE_MOTHERBOARD),7)
|
||||||
|
@ -115,6 +115,7 @@
|
|||||||
#define BOARD_MELZI_MAKR3D 66 // Melzi with ATmega1284 (MaKr3d version)
|
#define BOARD_MELZI_MAKR3D 66 // Melzi with ATmega1284 (MaKr3d version)
|
||||||
#define BOARD_MELZI_CREALITY 89 // Melzi Creality3D board (for CR-10 etc)
|
#define BOARD_MELZI_CREALITY 89 // Melzi Creality3D board (for CR-10 etc)
|
||||||
#define BOARD_MELZI_MALYAN 92 // Melzi Malyan M150 board
|
#define BOARD_MELZI_MALYAN 92 // Melzi Malyan M150 board
|
||||||
|
#define BOARD_CREALITY_ENDER 601 // Creality Ender
|
||||||
#define BOARD_STB_11 64 // STB V1.1
|
#define BOARD_STB_11 64 // STB V1.1
|
||||||
#define BOARD_AZTEEG_X1 65 // Azteeg X1
|
#define BOARD_AZTEEG_X1 65 // Azteeg X1
|
||||||
|
|
||||||
|
@ -115,7 +115,14 @@
|
|||||||
// When only one extruder is selected, the "1" on the symbol will not
|
// When only one extruder is selected, the "1" on the symbol will not
|
||||||
// be displayed.
|
// be displayed.
|
||||||
|
|
||||||
#if HAS_TEMP_BED
|
#ifdef CUSTOM_STATUS_SCREEN_FILE
|
||||||
|
#undef STATUS_SCREENWIDTH
|
||||||
|
|
||||||
|
// This file must define STATUS_SCREENWIDTH and status_screen{0,1}_bmp.
|
||||||
|
// It can also define STATUS_SCREEN_X, STATUS_SCREEN_{BED,FAN}_TEXT_X and
|
||||||
|
// STATUS_SCREEN_HOTEND_TEXT_X(i) to modify draw locations.
|
||||||
|
#include CUSTOM_STATUS_SCREEN_FILE
|
||||||
|
#elif HAS_TEMP_BED
|
||||||
#if HOTENDS == 1
|
#if HOTENDS == 1
|
||||||
#define STATUS_SCREENWIDTH 115 //Width in pixels
|
#define STATUS_SCREENWIDTH 115 //Width in pixels
|
||||||
#define STATUS_SCREENHEIGHT 19 //Height in pixels
|
#define STATUS_SCREENHEIGHT 19 //Height in pixels
|
||||||
@ -513,3 +520,16 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
#endif // BABYSTEP_ZPROBE_GFX_OVERLAY || MESH_EDIT_GFX_OVERLAY
|
#endif // BABYSTEP_ZPROBE_GFX_OVERLAY || MESH_EDIT_GFX_OVERLAY
|
||||||
|
|
||||||
|
#ifndef STATUS_SCREEN_X
|
||||||
|
#define STATUS_SCREEN_X 9
|
||||||
|
#endif
|
||||||
|
#ifndef STATUS_SCREEN_HOTEND_TEXT_X
|
||||||
|
#define STATUS_SCREEN_HOTEND_TEXT_X(i) (5 + (i) * 25)
|
||||||
|
#endif
|
||||||
|
#ifndef STATUS_SCREEN_BED_TEXT_X
|
||||||
|
#define STATUS_SCREEN_BED_TEXT_X 81
|
||||||
|
#endif
|
||||||
|
#ifndef STATUS_SCREEN_FAN_TEXT_X
|
||||||
|
#define STATUS_SCREEN_FAN_TEXT_X 104
|
||||||
|
#endif
|
||||||
|
@ -37,7 +37,7 @@
|
|||||||
#undef en
|
#undef en
|
||||||
|
|
||||||
#ifndef WELCOME_MSG
|
#ifndef WELCOME_MSG
|
||||||
#define WELCOME_MSG MACHINE_NAME _UxGT(" ready.")
|
#define WELCOME_MSG MACHINE_NAME _UxGT(" Ready.")
|
||||||
#endif
|
#endif
|
||||||
#ifndef MSG_BACK
|
#ifndef MSG_BACK
|
||||||
#define MSG_BACK _UxGT("Back")
|
#define MSG_BACK _UxGT("Back")
|
||||||
|
@ -324,7 +324,7 @@ void lcd_printPGM_utf(const char *str, uint8_t n=LCD_WIDTH) {
|
|||||||
|
|
||||||
u8g.firstPage();
|
u8g.firstPage();
|
||||||
do {
|
do {
|
||||||
u8g.drawBitmapP(offx, offy, START_BMPBYTEWIDTH, START_BMPHEIGHT, start_bmp);
|
u8g.drawBitmapP(offx, offy, (START_BMPWIDTH + 7) / 8, START_BMPHEIGHT, start_bmp);
|
||||||
lcd_setFont(FONT_MENU);
|
lcd_setFont(FONT_MENU);
|
||||||
#ifndef STRING_SPLASH_LINE2
|
#ifndef STRING_SPLASH_LINE2
|
||||||
u8g.drawStr(txt1X, u8g.getHeight() - (DOG_CHAR_HEIGHT), STRING_SPLASH_LINE1);
|
u8g.drawStr(txt1X, u8g.getHeight() - (DOG_CHAR_HEIGHT), STRING_SPLASH_LINE1);
|
||||||
@ -365,7 +365,6 @@ static void lcd_implementation_init() {
|
|||||||
#elif ENABLED(LCD_SCREEN_ROT_270)
|
#elif ENABLED(LCD_SCREEN_ROT_270)
|
||||||
u8g.setRot270(); // Rotate screen by 270°
|
u8g.setRot270(); // Rotate screen by 270°
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// The kill screen is displayed for unrecoverable conditions
|
// The kill screen is displayed for unrecoverable conditions
|
||||||
@ -503,7 +502,9 @@ static void lcd_implementation_status_screen() {
|
|||||||
|
|
||||||
if (PAGE_UNDER(STATUS_SCREENHEIGHT + 1)) {
|
if (PAGE_UNDER(STATUS_SCREENHEIGHT + 1)) {
|
||||||
|
|
||||||
u8g.drawBitmapP(9, 1, STATUS_SCREENBYTEWIDTH, STATUS_SCREENHEIGHT,
|
u8g.drawBitmapP(
|
||||||
|
STATUS_SCREEN_X, 1,
|
||||||
|
(STATUS_SCREENWIDTH + 7) / 8, STATUS_SCREENHEIGHT,
|
||||||
#if HAS_FAN0
|
#if HAS_FAN0
|
||||||
blink && fanSpeeds[0] ? status_screen0_bmp : status_screen1_bmp
|
blink && fanSpeeds[0] ? status_screen0_bmp : status_screen1_bmp
|
||||||
#else
|
#else
|
||||||
@ -519,11 +520,11 @@ static void lcd_implementation_status_screen() {
|
|||||||
|
|
||||||
if (PAGE_UNDER(28)) {
|
if (PAGE_UNDER(28)) {
|
||||||
// Extruders
|
// Extruders
|
||||||
HOTEND_LOOP() _draw_heater_status(5 + e * 25, e, blink);
|
HOTEND_LOOP() _draw_heater_status(STATUS_SCREEN_HOTEND_TEXT_X(e), e, blink);
|
||||||
|
|
||||||
// Heated bed
|
// Heated bed
|
||||||
#if HOTENDS < 4 && HAS_TEMP_BED
|
#if HOTENDS < 4 && HAS_TEMP_BED
|
||||||
_draw_heater_status(81, -1, blink);
|
_draw_heater_status(STATUS_SCREEN_BED_TEXT_X, -1, blink);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if HAS_FAN0
|
#if HAS_FAN0
|
||||||
@ -531,7 +532,7 @@ static void lcd_implementation_status_screen() {
|
|||||||
// Fan
|
// Fan
|
||||||
const int16_t per = ((fanSpeeds[0] + 1) * 100) / 256;
|
const int16_t per = ((fanSpeeds[0] + 1) * 100) / 256;
|
||||||
if (per) {
|
if (per) {
|
||||||
u8g.setPrintPos(104, 27);
|
u8g.setPrintPos(STATUS_SCREEN_FAN_TEXT_X, 27);
|
||||||
lcd_print(itostr3(per));
|
lcd_print(itostr3(per));
|
||||||
u8g.print('%');
|
u8g.print('%');
|
||||||
}
|
}
|
||||||
|
@ -195,6 +195,8 @@
|
|||||||
#include "pins_MELZI_CREALITY.h" // ATmega644P, ATmega1284P
|
#include "pins_MELZI_CREALITY.h" // ATmega644P, ATmega1284P
|
||||||
#elif MB(MELZI_MALYAN)
|
#elif MB(MELZI_MALYAN)
|
||||||
#include "pins_MELZI_MALYAN.h" // ATmega644P, ATmega1284P
|
#include "pins_MELZI_MALYAN.h" // ATmega644P, ATmega1284P
|
||||||
|
#elif MB(CREALITY_ENDER)
|
||||||
|
#include "pins_CREALITY_ENDER.h" // ATmega1284P
|
||||||
#elif MB(STB_11)
|
#elif MB(STB_11)
|
||||||
#include "pins_STB_11.h" // ATmega644P, ATmega1284P
|
#include "pins_STB_11.h" // ATmega644P, ATmega1284P
|
||||||
#elif MB(AZTEEG_X1)
|
#elif MB(AZTEEG_X1)
|
||||||
|
34
Marlin/src/pins/pins_CREALITY_ENDER.h
Normal file
34
Marlin/src/pins/pins_CREALITY_ENDER.h
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
/**
|
||||||
|
* Marlin 3D Printer Firmware
|
||||||
|
* Copyright (C) 2016 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 <http://www.gnu.org/licenses/>.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creality Ender pin assignments
|
||||||
|
*
|
||||||
|
* Applies to the following boards:
|
||||||
|
*
|
||||||
|
* Creality Ender-2
|
||||||
|
* Creality Ender-4
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define BOARD_NAME "Creality Ender"
|
||||||
|
|
||||||
|
#include "pins_SANGUINOLOLU_12.h"
|
@ -114,7 +114,7 @@
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if MB(AZTEEG_X1) || MB(STB_11) || ENABLED(IS_MELZI)
|
#if MB(AZTEEG_X1) || MB(STB_11) || MB(CREALITY_ENDER) || ENABLED(IS_MELZI)
|
||||||
#define FAN_PIN 4 // Works for Panelolu2 too
|
#define FAN_PIN 4 // Works for Panelolu2 too
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -187,6 +187,11 @@
|
|||||||
#define DOGLCD_CS 17
|
#define DOGLCD_CS 17
|
||||||
#define LCD_BACKLIGHT_PIN 28 // PA3
|
#define LCD_BACKLIGHT_PIN 28 // PA3
|
||||||
|
|
||||||
|
#elif MB(CREALITY_ENDER)
|
||||||
|
|
||||||
|
#define BEEPER_PIN 27
|
||||||
|
#define DOGLCD_CS 28
|
||||||
|
|
||||||
#else // !MAKRPANEL
|
#else // !MAKRPANEL
|
||||||
|
|
||||||
#define DOGLCD_CS 29
|
#define DOGLCD_CS 29
|
||||||
|
Loading…
Reference in New Issue
Block a user