Explorar el Código

MKS Robin: SD pins not required (SDIO) (#15474)

Tanguy Pruvot hace 5 años
padre
commit
c6ffa7f38d
Se han modificado 1 ficheros con 27 adiciones y 18 borrados
  1. 27
    18
      Marlin/src/pins/stm32/pins_MKS_ROBIN.h

+ 27
- 18
Marlin/src/pins/stm32/pins_MKS_ROBIN.h Ver fichero

@@ -23,6 +23,8 @@
23 23
 
24 24
 /**
25 25
  * MKS Robin (STM32F130ZET6) board pin assignments
26
+ *
27
+ * https://github.com/makerbase-mks/MKS-Robin/tree/master/MKS%20Robin/Hardware
26 28
  */
27 29
 
28 30
 #ifndef __STM32F1__
@@ -36,7 +38,7 @@
36 38
 //
37 39
 // Release PB4 (Y_ENABLE_PIN) from JTAG NRST role
38 40
 //
39
-#define DISABLE_DEBUG
41
+#define DISABLE_JTAG
40 42
 
41 43
 //
42 44
 // Servos
@@ -110,7 +112,7 @@
110 112
 
111 113
 /**
112 114
  * Note: MKS Robin TFT screens use various TFT controllers. Supported screens
113
- * are based on the ILI9342, ILI9328 and ST7798V. Define init sequences for
115
+ * are based on the ILI9341, ILI9328 and ST7798V. Define init sequences for
114 116
  * other screens in u8g_dev_tft_320x240_upscale_from_128x64.cpp
115 117
  *
116 118
  * If the screen stays white, disable 'LCD_RESET_PIN'
@@ -125,21 +127,28 @@
125 127
 #define FSMC_RS_PIN        PF0   // A0
126 128
 
127 129
 #if ENABLED(TOUCH_BUTTONS)
128
-  #define TOUCH_CS_PIN     PB1
130
+  #define TOUCH_CS_PIN     PB1   // SPI2_NSS
131
+  #define TOUCH_SCK_PIN    PB13  // SPI2_SCK
132
+  #define TOUCH_MISO_PIN   PB14  // SPI2_MISO
133
+  #define TOUCH_MOSI_PIN   PB15  // SPI2_MOSI
129 134
 #endif
130 135
 
131
-//
132
-// Custom SPI pins
133
-//
134
-#define SCK_PIN            PC12
135
-#define MISO_PIN           PC8
136
-#define MOSI_PIN           PD2
137
-#define SS_PIN              -1
138
-
139
-//
140
-// Onboard SD Card
141
-//
142
-#define ONBOARD_SD_CS      PC11
143
-#define SDSS               PD2
144
-
145
-#define SD_DETECT_PIN       -1   // PF12
136
+// SPI1(PA7) & SPI3(PB5) not available
137
+#define ENABLE_SPI2
138
+
139
+#if ENABLED(SDIO_SUPPORT)
140
+  #define SCK_PIN           PB13 // SPI2
141
+  #define MISO_PIN          PB14 // SPI2
142
+  #define MOSI_PIN          PB15 // SPI2
143
+  #define SS_PIN            -1   // PB12 is X-
144
+  #define SD_DETECT_PIN     PF12 // SD_CD
145
+#else
146
+  // SD as custom software SPI (SDIO pins)
147
+  #define SCK_PIN           PC12
148
+  #define MISO_PIN          PC8
149
+  #define MOSI_PIN          PD2
150
+  #define SS_PIN            -1
151
+  #define ONBOARD_SD_CS_PIN PC11
152
+  #define SDSS              PD2
153
+  #define SD_DETECT_PIN     -1
154
+#endif

Loading…
Cancelar
Guardar