Marlin Configuration
The following assumes:
a) A mega2560 CPU
b) RAMPS 1.4 shield
c) The MKS MINI 12864 LCD controller is plugged into the Smart Adapter (the card used to
interface to the RepRapDiscount Full Graphic Smart Controller).
1.In Configuration.h enable MINIPANEL.2.In pins_RAMPS.h use these defines.
#elif ENABLED(MINIPANEL)
#define MISO_PIN 50 // system defined - only needed if using onboard SD card
#define MOSI_PIN 51 // system defined
#define SCK_PIN 52 // system defined
#define SDSS 53 // only needed if using onboard SD card
#define BEEPER_PIN 37
#define BTN_EN1 31
#define BTN_EN2 33
#define BTN_ENC 35
#define KILL_PIN 41 // optional
#define SD_DETECT_PIN 49 // only needed if using onboard SD card
#define DOGLCD_CS 25
#define DOGLCD_A0 27
3.In Marlin 1.1.x and earlier, only one SD card interface can be active. If there is an SD card slot on the controller then either the SD card slot on the MKS MINI 12864 LCD controller is active or the SD card slot on the controller is active but not both.4.If the SD card slot on the MKS MINI 12864 LCD controller is not used then the following functions should NOT be defined/used:
MISO_PIN
SDSS
SD_DETECT_PIN