My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

pins_MINGDA_MPX_ARM_MINI.h 4.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161
  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. * MPX ARM MINI (STM32F103ZET6) board pin assignments
  25. */
  26. #if NOT_TARGET(STM32F1, STM32F1xx)
  27. #error "Oops! Select an STM32F1 board in 'Tools > Board.'"
  28. #elif HOTENDS > 1 || E_STEPPERS > 1
  29. #error "MPX ARM Mini only supports 1 hotend / E stepper."
  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 // 4K
  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 // 2K
  49. #define EEPROM_START_ADDRESS (0x8000000UL + (STM32_FLASH_SIZE) * 1024UL - (EEPROM_PAGE_SIZE) * 2UL)
  50. #define MARLIN_EEPROM_SIZE EEPROM_PAGE_SIZE // 2K
  51. #endif
  52. #define SPI_DEVICE 2
  53. //
  54. // Limit Switches
  55. //
  56. #define X_MIN_PIN PD6
  57. #define X_MAX_PIN PG15 // To double check
  58. #define Y_MIN_PIN PG9
  59. #define Y_MAX_PIN PG14 // To double check
  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. #define TFT_RESET_PIN PF15
  117. #define TFT_BACKLIGHT_PIN PF11
  118. #define LCD_USE_DMA_FSMC // Use DMA transfers to send data to the TFT
  119. #define FSMC_CS_PIN PD7 // NE4
  120. #define FSMC_RS_PIN PG0 // A0
  121. #define FSMC_DMA_DEV DMA2
  122. #define FSMC_DMA_CHANNEL DMA_CH5
  123. #define TFT_CS_PIN FSMC_CS_PIN
  124. #define TFT_RS_PIN FSMC_RS_PIN
  125. #define TOUCH_BUTTONS_HW_SPI
  126. #define TOUCH_BUTTONS_HW_SPI_DEVICE 1
  127. #endif
  128. #if NEED_TOUCH_PINS
  129. #define TOUCH_CS_PIN PA4 // SPI1_NSS
  130. #define TOUCH_SCK_PIN PA5 // SPI1_SCK
  131. #define TOUCH_MISO_PIN PA6 // SPI1_MISO
  132. #define TOUCH_MOSI_PIN PA7 // SPI1_MOSI
  133. #endif