Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update for FLSun Hispeedv1 Board #19959

Merged
merged 76 commits into from
Nov 18, 2020
Merged
Changes from all commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
1c59a8a
Update pins for TMC and UART capacities
Foxies-CSTL Aug 13, 2020
970321f
Update QQS_Pro capacities
Foxies-CSTL Aug 13, 2020
aadf06d
Update platformio.ini
Foxies-CSTL Aug 13, 2020
1d48941
Update pins.h
Foxies-CSTL Aug 13, 2020
f741c8d
Update QQS_Pro Stock/TMC/UART
Foxies-CSTL Aug 13, 2020
57fbe12
Multi_Config FLSUN_QQS-PRO
Foxies-CSTL Aug 17, 2020
eac1d17
add for sync
Foxies-CSTL Oct 8, 2020
26238d7
add for sync
Foxies-CSTL Oct 8, 2020
024bdd8
sync
Foxies-CSTL Oct 8, 2020
faf1b62
sync
Foxies-CSTL Oct 8, 2020
b0a00c5
Update _Statusscreen.h
Foxies-CSTL Oct 8, 2020
671b934
Update _Statusscreen.h
Foxies-CSTL Oct 8, 2020
8f8c0d5
Update _Statusscreen.h
Foxies-CSTL Oct 8, 2020
bf07738
Update _Statusscreen.h
Foxies-CSTL Oct 8, 2020
6264b86
Update _Statusscreen.h
Foxies-CSTL Oct 8, 2020
ef8a287
Update _Statusscreen.h
Foxies-CSTL Oct 8, 2020
0cdfc71
sync
Foxies-CSTL Oct 8, 2020
236cc1b
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 18, 2020
653caa1
Update platformio.ini
thinkyhead Oct 18, 2020
4bc5cfd
Update platformio.ini
thinkyhead Oct 18, 2020
8d6776f
update QQS-PRO
Foxies-CSTL Oct 18, 2020
5a50672
Merge branch 'bugfix-2.0.x' of https://github.com/Foxies-CSTL/Marlin_…
Foxies-CSTL Oct 18, 2020
d63df49
Update platformio.ini
Foxies-CSTL Oct 18, 2020
25f88b3
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 18, 2020
0beea64
Update Configuration.h
Foxies-CSTL Oct 18, 2020
a3ad2e6
Update Configuration_adv.h
Foxies-CSTL Oct 18, 2020
c4877d6
Update Configuration.h
Foxies-CSTL Oct 18, 2020
c915b18
Update Configuration_adv.h
Foxies-CSTL Oct 18, 2020
a746946
Update Version.h
Foxies-CSTL Oct 18, 2020
66834a1
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Oct 19, 2020
38f62bb
Update platformio.ini
Foxies-CSTL Oct 19, 2020
ed2f552
Delete _Statusscreen.h
Foxies-CSTL Oct 19, 2020
33756f7
Delete _Bootscreen.h
Foxies-CSTL Oct 19, 2020
35323bd
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 20, 2020
79a49de
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Oct 20, 2020
66a2c85
Update Configuration_adv.h
Foxies-CSTL Oct 20, 2020
5106ae1
Update Configuration.h
Foxies-CSTL Oct 20, 2020
aed87ce
Update add_nanolib.py
Foxies-CSTL Oct 20, 2020
e754431
FLSUN Delta QQS-Pro support
thinkyhead Oct 21, 2020
6a436e2
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 21, 2020
af829ae
Update boards.h
Foxies-CSTL Oct 21, 2020
7cde38b
Merge branch 'bugfix-2.0.x' of https://github.com/Foxies-CSTL/Marlin_…
Foxies-CSTL Oct 21, 2020
d9fb468
Update boards.h
Foxies-CSTL Oct 21, 2020
fea2c01
Update pins.h
Foxies-CSTL Oct 21, 2020
438e9cb
Update pins.h
Foxies-CSTL Oct 21, 2020
193ae20
Update boards.h
Foxies-CSTL Oct 21, 2020
ce57698
Update Configuration.h
Foxies-CSTL Oct 21, 2020
781f28c
Fix bizarre regressions
thinkyhead Oct 21, 2020
9b10a48
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 22, 2020
e7bda8f
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 27, 2020
9a9b643
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Oct 28, 2020
b9f077d
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 28, 2020
e35be4d
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 28, 2020
316f988
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Oct 30, 2020
16569bc
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 31, 2020
7b596b5
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Oct 31, 2020
f532562
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Oct 31, 2020
95f0778
Update pins_FLSUN_HISPEED.h
thinkyhead Oct 31, 2020
a80b3b1
Update pins_FLSUN_HISPEED.h
thinkyhead Oct 31, 2020
f2198a1
More compatible driver macros
thinkyhead Oct 31, 2020
21ea0a8
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Oct 31, 2020
ee51865
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Nov 2, 2020
1af299c
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Nov 2, 2020
290cfac
Fix SPI2-Extension SDCard-TFT buz
Foxies-CSTL Nov 2, 2020
ef80fda
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Nov 4, 2020
3948460
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Nov 6, 2020
85ed5d3
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Nov 9, 2020
d70922f
Simplication and add J2 connector
Foxies-CSTL Nov 11, 2020
f8af42d
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Nov 11, 2020
4e2e521
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Nov 12, 2020
85af800
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Nov 14, 2020
c2aad56
Update pins_FLSUN_HISPEED.h
Foxies-CSTL Nov 16, 2020
07b5aed
Merge remote-tracking branch 'upstream/bugfix-2.0.x' into bugfix-2.0.x
Foxies-CSTL Nov 16, 2020
1dc8c22
Update pins_FLSUN_HISPEED.h
thinkyhead Nov 17, 2020
658bf5a
Update pins_FLSUN_HISPEED.h
thinkyhead Nov 17, 2020
e4d31a9
Update following the new management of screens.
Foxies-CSTL Nov 17, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
188 changes: 86 additions & 102 deletions Marlin/src/pins/stm32f1/pins_FLSUN_HISPEED.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,16 @@
//
#if EITHER(NO_EEPROM_SELECTED, FLASH_EEPROM_EMULATION)
#define FLASH_EEPROM_EMULATION
#define EEPROM_PAGE_SIZE (0x800U) // 2KB
#define EEPROM_PAGE_SIZE (0x800U) // 2KB
#define EEPROM_START_ADDRESS (0x8000000UL + (STM32_FLASH_SIZE) * 1024UL - (EEPROM_PAGE_SIZE) * 2UL)
#define MARLIN_EEPROM_SIZE EEPROM_PAGE_SIZE // 2KB
#endif

//
// SPI
// Note: FLSun Hispeed (clone MKS_Robin_miniV2) board is using SPI2 interface.
//
#define SPI_DEVICE 2
#define SPI_DEVICE 2

// SPI Flash
#define HAS_SPI_FLASH 1
Expand Down Expand Up @@ -108,49 +109,26 @@
#define E0_STEP_PIN PD6 // E0_STEP
#define E0_DIR_PIN PD3 // E0_DIR

/**
* FLSUN Hi-Speed has no hard-wired UART pins for TMC drivers.
* Several wiring options are provided below, defaulting to
* to the most compatible.
*/

//
// Drivers
//
#if HAS_TMC220x

#if ENABLED(HARDWARE_SERIAL) /* TMC2209 */
#define X_SLAVE_ADDRESS 3 // | | :
#define Y_SLAVE_ADDRESS 2 // : | :
#define Z_SLAVE_ADDRESS 1 // | : :
//#define E0_SLAVE_ADDRESS 0 // : : :

#define X_SERIAL_TX_PIN PA9 // TXD1
#define X_SERIAL_RX_PIN PA9 // TXD1

#define Y_SERIAL_TX_PIN PA9 // TXD1
#define Y_SERIAL_RX_PIN PA9 // TXD1

#define Z_SERIAL_TX_PIN PA9 // TXD1
#define Z_SERIAL_RX_PIN PA9 // TXD1

#elif ENABLED(SOFTWARE_SERIAL) /* TMC220x */
/**
* TMC2208 stepper UART-configurable by PDN_UART pin
* Software serial
*/
#define X_SLAVE_ADDRESS 0
#define Y_SLAVE_ADDRESS 0
#define Z_SLAVE_ADDRESS 0

#define X_SERIAL_TX_PIN PA10 // RXD1
#define X_SERIAL_RX_PIN PA10 // RXD1

#define Y_SERIAL_TX_PIN PA9 // TXD1
#define Y_SERIAL_RX_PIN PA9 // TXD1

#define Z_SERIAL_TX_PIN PC7 // IO1
#define Z_SERIAL_RX_PIN PC7 // IO1

#endif
// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
// SoftwareSerial with one pin per driver
// Compatible with TMC2208 and TMC2209 drivers
#define X_SERIAL_TX_PIN PA10 // RXD1
#define X_SERIAL_RX_PIN PA10 // RXD1
#define Y_SERIAL_TX_PIN PA9 // TXD1
#define Y_SERIAL_RX_PIN PA9 // TXD1
#define Z_SERIAL_TX_PIN PC7 // IO1
#define Z_SERIAL_RX_PIN PC7 // IO1
#define TMC_BAUD_RATE 19200
#else

// Motor current PWM pins
#define MOTOR_CURRENT_PWM_XY_PIN PA6 // VREF2/3 CONTROL XY
#define MOTOR_CURRENT_PWM_Z_PIN PA7 // VREF4 CONTROL Z
Expand All @@ -159,33 +137,33 @@
#define DEFAULT_PWM_MOTOR_CURRENT { 800, 800, 800 }
#endif

/**
* src: MKS Robin_Mini V2
* __ESP(M1)__ -J1-
* GND| 15 | | 08 |+3v3 (22)=>RXD1(PA10) //
* | 16 | | 07 |MOSI (21)=>TXD1(PA9) // active low, probably OK to leave floating
* IO2| 17 | | 06 |MISO (19)=>IO1(PC7) // Leave as unused (ESP3D software configures this with a pullup so OK to leave as floating)
* IO0| 18 | | 05 |CLK (18)=>IO0(PA8) // must be high (ESP3D software configures this with a pullup so OK to leave as floating)
* IO1| 19 | | 03 |EN (03)=>WIFI_EN() // Must be high for module to run
* | nc | | nc | (01)=>WIFI_CTRL(PA5)
* RX| 21 | | nc |
* TX| 22 | | 01 |RST
*  ̄ ̄ AE ̄ ̄
*
*/
#ifdef ESP_WIFI
#define WIFI_IO0_PIN PA8 // PC13 MKS ESP WIFI IO0 PIN
#define WIFI_IO1_PIN PC7 // MKS ESP WIFI IO1 PIN
#define WIFI_RESET_PIN PA5 // MKS ESP WIFI RESET PIN
#endif
/**
* MKS Robin_Wifi or another ESP8266 module
*
* __ESP(M1)__ -J1-
* GND| 15 | | 08 |+3v3 (22) RXD1 (PA10)
* | 16 | | 07 |MOSI (21) TXD1 (PA9) Active LOW, probably OK to leave floating
* IO2| 17 | | 06 |MISO (19) IO1 (PC7) Leave as unused (ESP3D software configures this with a pullup so OK to leave as floating)
* IO0| 18 | | 05 |CLK (18) IO0 (PA8) Must be HIGH (ESP3D software configures this with a pullup so OK to leave as floating)
* IO1| 19 | | 03 |EN (03) WIFI_EN Must be HIGH for module to run
* | nc | | nc | (01) WIFI_CTRL (PA5)
* RX| 21 | | nc |
* TX| 22 | | 01 |RST
*  ̄ ̄ AE ̄ ̄
*/
// Module ESP-WIFI
#define ESP_WIFI_MODULE_COM 2 // Must also set either SERIAL_PORT or SERIAL_PORT_2 to this
#define ESP_WIFI_MODULE_BAUDRATE BAUDRATE // Must use same BAUDRATE as SERIAL_PORT & SERIAL_PORT_2
#define ESP_WIFI_MODULE_RESET_PIN PA5 // WIFI CTRL/RST
#define ESP_WIFI_MODULE_ENABLE_PIN -1
#define ESP_WIFI_MODULE_TXD_PIN PA9 // MKS or ESP WIFI RX PIN
#define ESP_WIFI_MODULE_RXD_PIN PA10 // MKS or ESP WIFI TX PIN
#endif

//
// EXTRUDER
//
#if AXIS_DRIVER_TYPE(E0,TMC2208)||AXIS_DRIVER_TYPE(E0,TMC2209)
#define E0_SLAVE_ADDRESS 0

#if AXIS_DRIVER_TYPE_E0(TMC2208) || AXIS_DRIVER_TYPE_E0(TMC2209)
#define E0_SERIAL_TX_PIN PA8 // IO0
#define E0_SERIAL_RX_PIN PA8 // IO0
#define TMC_BAUD_RATE 19200
Expand All @@ -199,7 +177,7 @@
#endif

//
// Temperature Sensors(THM)
// Temperature Sensors (THM)
//
#define TEMP_0_PIN PC1 // TEMP_E0
#define TEMP_BED_PIN PC0 // TEMP_BED
Expand All @@ -211,7 +189,6 @@
#define HEATER_BED_PIN PA0 // HEATER_BED-WKUP

#define FAN_PIN PB1 // E_FAN
//#define CONTROLLER_FAN_PIN PD6 // BOARD FAN

//
// Misc. Functions
Expand All @@ -221,12 +198,24 @@
#define POWER_LOSS_PIN PA2 // PW_DET (UPS) MKSPWC
#endif

/**
* Connector J2
* -------
* DIO O|1 2|O 3v3
* CSK O|3 5|O GND
* RST O|5 6|O GND
* -------
*/
//#define SW_DIO PA13
//#define SW_CLK PA14
//#define SW_RST NRST // (14)

//
// Power Supply Control
//
#if ENABLED(PSU_CONTROL)
#define KILL_PIN PA2 // PW_DET
#define KILL_PIN_INVERTING true //
#define KILL_PIN_INVERTING true
//#define PS_ON_PIN PA3 // PW_CN /PW_OFF
#endif

Expand All @@ -240,28 +229,33 @@
//#define LED_PIN PB2 // BOOT1

#if ENABLED(NEOPIXEL_LED)
#define LED_PWM PA8
#define LED_PWM PC7 // IO1
#ifndef NEOPIXEL_PIN
#define NEOPIXEL_PIN LED_PWM // USED WIFI IO0/IO1/TX/RX PIN
#define NEOPIXEL_PIN LED_PWM // USED WIFI IO0/IO1 PIN
#endif
#endif

//Others test.
//#define SERVO0_PIN PA5 // WIFI CRTL
//#define GPIO_CLEAR PA8 // IO0
//#define GPIO_SET PA5

//
// SD Card
//
#define SDIO_SUPPORT
#define SDIO_CLOCK 4500000 // 4.5 MHz /* 18 MHz (18000000) or 4.5MHz (450000) */
//#define SDIO_CLOCK 18000000 // 18 MHz (18000000)
#if ENABLED(SDIO_SUPPORT)
#define SCK_PIN PB13 // SPI2
#define MISO_PIN PB14 // SPI2
#define MOSI_PIN PB15 // SPI2
#define SD_DETECT_PIN PD12 // SD_CD
#ifndef SDCARD_CONNECTION
#define SDCARD_CONNECTION ONBOARD
#endif

// Use the on-board card socket labeled SD_Extender
#if SD_CONNECTION_IS(CUSTOM_CABLE)
#define SCK_PIN PC12
#define MISO_PIN PC8
#define MOSI_PIN PD2
#define SS_PIN -1
#define SD_DETECT_PIN PD12 // SD_CD (if -1 no detection)
#else
#define SDIO_SUPPORT
#define SDIO_CLOCK 4500000 // 4.5 MHz
#define SDIO_READ_RETRIES 16
#define ONBOARD_SPI_DEVICE 1 // SPI1
#define ONBOARD_SD_CS_PIN PC11
#define SD_DETECT_PIN -1 // SD_CD (-1 active refresh)
#endif

//
Expand All @@ -271,6 +265,10 @@
#define BEEPER_PIN PC5
#endif

#if ENABLED(SPEAKER) && BEEPER_PIN == PC5
#error "FLSun HiSpeed default BEEPER_PIN is not a SPEAKER."
#endif

/**
* Note: MKS Robin TFT screens use various TFT controllers
* Supported screens are based on the ILI9341, ST7789V and ILI9328 (320x240)
Expand All @@ -284,26 +282,7 @@
* because Marlin uses the reset as a failsafe to revive a glitchy LCD.
*/

// MKS Robin TFT v2.0 with ILI9341
// Read display identification information (0xD3 on ILI9341)
//#define TOUCH_CALIBRATION_X 12013
//#define TOUCH_CALIBRATION_Y -8711
//#define TOUCH_OFFSET_X -32
//#define TOUCH_OFFSET_Y 256

// MKS Robin TFT v1.1 with ILI9328
//#define TOUCH_CALIBRATION_X -11792
//#define TOUCH_CALIBRATION_Y 8947
//#define TOUCH_OFFSET_X 342
//#define TOUCH_OFFSET_Y -19

// MKS Robin TFT v1.1 with R61505
//#define TOUCH_CALIBRATION_X 12489
//#define TOUCH_CALIBRATION_Y 9210
//#define TOUCH_OFFSET_X -52
//#define TOUCH_OFFSET_Y -17

// QQS-Pro uses MKS Robin TFT v2.0
// QQS-Pro uses MKS Robin TFT v2.0 320x240

// Shared FSMC Configs
#if HAS_FSMC_TFT
Expand All @@ -320,8 +299,13 @@
#define FSMC_DMA_DEV DMA2
#define FSMC_DMA_CHANNEL DMA_CH5

#define TOUCH_BUTTONS_HW_SPI
#define TOUCH_BUTTONS_HW_SPI_DEVICE 2
#define TFT_BUFFER_SIZE 14400
#if ENABLED(TFT_CLASSIC_UI)
#define TFT_MARLINBG_COLOR 0x3186 // White
#define TFT_MARLINUI_COLOR 0xC7B6 // green
#define TFT_BTARROWS_COLOR 0xDEE6 // Yellow
#define TFT_BTOKMENU_COLOR 0x145F // Cyan
#endif
#endif

#if NEED_TOUCH_PINS
Expand Down