My Marlin configs for Fabrikator Mini and CTC i3 Pro B
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

pins_MINGDA_MPX_ARM_MINI.h 5.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
  4. *
  5. * Based on Sprinter and grbl.
  6. * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
  7. *
  8. * This program is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program. If not, see <https://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #pragma once
  23. /**
  24. * MKS Robin mini (STM32F103VET6) board pin assignments
  25. */
  26. #if NOT_TARGET(STM32F1, STM32F1xx)
  27. #error "Oops! Select an STM32F1 board in 'Tools > Board.'"
  28. #elif HOTENDS > 2 || E_STEPPERS > 2
  29. #error "MKS Robin supports up to 2 hotends / E-steppers. Comment out this line to continue."
  30. #endif
  31. #define BOARD_INFO_NAME "Mingda MPX_ARM_MINI"
  32. #define BOARD_NO_NATIVE_USB
  33. #define DISABLE_DEBUG
  34. //
  35. // EEPROM
  36. //
  37. /*
  38. //Mingda used an unknown EEPROM chip ATMLH753, so I turned on the emulation below.
  39. //It is connected to EEPROM PB6 PB7
  40. #define I2C_EEPROM
  41. #undef NO_EEPROM_SELECTED
  42. #define MARLIN_EEPROM_SIZE 0x1000 // 4KB
  43. #define USE_SHARED_EEPROM 1 // Use Platform-independent Arduino functions for I2C EEPROM
  44. #define E2END 0xFFFF // EEPROM end address AT24C256 (32kB)
  45. */
  46. #if EITHER(NO_EEPROM_SELECTED, FLASH_EEPROM_EMULATION)
  47. #define FLASH_EEPROM_EMULATION
  48. #define EEPROM_PAGE_SIZE 0x800U // 2KB
  49. #define EEPROM_START_ADDRESS (0x8000000UL + (STM32_FLASH_SIZE) * 1024UL - (EEPROM_PAGE_SIZE) * 2UL)
  50. #define MARLIN_EEPROM_SIZE EEPROM_PAGE_SIZE // 2KB
  51. #endif
  52. #define SPI_DEVICE 2
  53. //
  54. // Limit Switches
  55. //
  56. #define X_MIN_PIN PD6
  57. #define X_MAX_PIN PG15
  58. #define Y_MIN_PIN PG9
  59. #define Y_MAX_PIN PG14
  60. #define Z_MIN_PIN PG10
  61. #define Z_MAX_PIN PG13
  62. #ifndef FIL_RUNOUT_PIN
  63. #define FIL_RUNOUT_PIN PG11
  64. #endif
  65. //
  66. // Steppers
  67. //
  68. #define X_ENABLE_PIN PD13
  69. #define X_STEP_PIN PD12
  70. #define X_DIR_PIN PD11
  71. #define Y_ENABLE_PIN PG4
  72. #define Y_STEP_PIN PG3
  73. #define Y_DIR_PIN PG2
  74. #define Z_ENABLE_PIN PG7
  75. #define Z_STEP_PIN PG6
  76. #define Z_DIR_PIN PG5
  77. #define E0_ENABLE_PIN PC7
  78. #define E0_STEP_PIN PC6
  79. #define E0_DIR_PIN PG8
  80. //
  81. // Temperature Sensors
  82. //
  83. //#define TEMP_0_PIN PF6 // THERM_E0
  84. //#define TEMP_0_PIN PB3 // E0 K+
  85. #define TEMP_BED_PIN PF7 // THERM_BED
  86. #define TEMP_0_CS_PIN PB5
  87. #define TEMP_0_SCK_PIN PB3
  88. #define TEMP_0_MISO_PIN PB4
  89. #define TEMP_0_MOSI_PIN PA14
  90. //
  91. // Heaters / Fans
  92. //
  93. #define HEATER_0_PIN PB0
  94. #define HEATER_BED_PIN PB1
  95. #define FAN_PIN PA0 // FAN
  96. //
  97. // SD Card
  98. //
  99. #ifndef SDCARD_CONNECTION
  100. #define SDCARD_CONNECTION ONBOARD
  101. #endif
  102. #define SDIO_SUPPORT
  103. #define SDIO_CLOCK 4500000 // 4.5 MHz
  104. #define SDIO_READ_RETRIES 16
  105. #define SD_DETECT_PIN PC5
  106. #define ONBOARD_SPI_DEVICE 1 // SPI1
  107. #define ONBOARD_SD_CS_PIN PC10
  108. //
  109. // LCD / Controller
  110. //
  111. #define BEEPER_PIN PE4
  112. //
  113. // TFT with FSMC interface
  114. //
  115. #if HAS_FSMC_TFT
  116. /**
  117. * Note: MKS Robin TFT screens use various TFT controllers
  118. * Supported screens are based on the ILI9341, ST7789V and ILI9328 (320x240)
  119. * ILI9488 is not supported
  120. * Define init sequences for other screens in u8g_dev_tft_320x240_upscale_from_128x64.cpp
  121. *
  122. * If the screen stays white, disable 'TFT_RESET_PIN'
  123. * to let the bootloader init the screen.
  124. *
  125. * Setting an 'TFT_RESET_PIN' may cause a flicker when entering the LCD menu
  126. * because Marlin uses the reset as a failsafe to revive a glitchy LCD.
  127. */
  128. #define TFT_RESET_PIN PF15
  129. #define TFT_BACKLIGHT_PIN PF11
  130. #define LCD_USE_DMA_FSMC // Use DMA transfers to send data to the TFT
  131. #define FSMC_CS_PIN PD7 // NE4
  132. #define FSMC_RS_PIN PG0 // A0
  133. #define FSMC_DMA_DEV DMA2
  134. #define FSMC_DMA_CHANNEL DMA_CH5
  135. #define TFT_CS_PIN FSMC_CS_PIN
  136. #define TFT_RS_PIN FSMC_RS_PIN
  137. #define TOUCH_BUTTONS_HW_SPI
  138. #define TOUCH_BUTTONS_HW_SPI_DEVICE 1
  139. #endif
  140. #if NEED_TOUCH_PINS
  141. #define TOUCH_CS_PIN PA4 // SPI2_NSS
  142. #define TOUCH_SCK_PIN PA5 // SPI2_SCK
  143. #define TOUCH_MISO_PIN PA6 // SPI2_MISO
  144. #define TOUCH_MOSI_PIN PA7 // SPI2_MOSI
  145. #endif