|
29 | 29 |
|
30 | 30 | #define BOARD_INFO_NAME "Creality3D RAMPS"
|
31 | 31 |
|
| 32 | +//#define CR2020_INDUSTRIAL_SERIES // Use layout specific to CR2020 |
| 33 | + |
| 34 | +// |
| 35 | +// 4-pin expansion header |
| 36 | +// |
| 37 | +#define EXP1_PIN 65 // A11 - Used by CR2020 Industrial series for case |
| 38 | +#define EXP2_PIN 66 // A12 |
| 39 | +#define EXP3_PIN 11 // RAMPS: SERVO0_PIN |
| 40 | +#define EXP4_PIN 12 // RAMPS: PS_ON_PIN |
| 41 | + |
| 42 | +// |
| 43 | +// Servos |
| 44 | +// |
| 45 | +#define SERVO1_PIN 12 |
| 46 | + |
32 | 47 | //
|
33 | 48 | // Heaters / Fans
|
34 | 49 | //
|
35 | 50 | #define MOSFET_B_PIN 7
|
36 | 51 | #define FAN0_PIN 9
|
37 | 52 |
|
| 53 | +// |
| 54 | +// Filament Runout Sensor |
| 55 | +// |
38 | 56 | #define FIL_RUNOUT_PIN 2
|
39 | 57 | #if NUM_RUNOUT_SENSORS >= 2
|
40 | 58 | #define FIL_RUNOUT2_PIN 15 // Creality CR-X can use dual runout sensors
|
41 | 59 | #endif
|
42 | 60 |
|
43 |
| -#ifndef SD_DETECT_PIN |
44 |
| - #if SD_CONNECTION_IS(ONBOARD) |
45 |
| - //#define HAS_ONBOARD_SD_DETECT // If the SD_DETECT_PIN is wired up |
| 61 | +// |
| 62 | +// Misc. Functions |
| 63 | +// |
| 64 | +#ifdef CR2020_INDUSTRIAL_SERIES |
| 65 | + #if ENABLED(PSU_CONTROL) && !defined(PS_ON_PIN) |
| 66 | + #define PS_ON_PIN 40 // Used by CR2020 Industrial series |
46 | 67 | #endif
|
47 |
| - #if ENABLED(HAS_ONBOARD_SD_DETECT) || !SD_CONNECTION_IS(ONBOARD) |
48 |
| - #define SD_DETECT_PIN 49 |
| 68 | + #ifndef SUICIDE_PIN |
| 69 | + #define SUICIDE_PIN 12 // Used by CR2020 Industrial series |
| 70 | + #endif |
| 71 | + #ifndef SUICIDE_PIN_STATE |
| 72 | + #define SUICIDE_PIN_STATE HIGH |
49 | 73 | #endif
|
50 |
| -#endif |
51 |
| - |
52 |
| -#ifndef PS_ON_PIN |
53 |
| - #define PS_ON_PIN 40 // Used by CR2020 Industrial series |
54 | 74 | #endif
|
55 | 75 |
|
56 | 76 | #if ENABLED(CASE_LIGHT_ENABLE) && !defined(CASE_LIGHT_PIN)
|
57 | 77 | #define CASE_LIGHT_PIN 65
|
58 | 78 | #endif
|
59 | 79 |
|
60 |
| -#define SERVO1_PIN 12 |
| 80 | +// |
| 81 | +// SD Card |
| 82 | +// |
| 83 | +#ifndef SD_DETECT_PIN |
| 84 | + #if SD_CONNECTION_IS(ONBOARD) |
| 85 | + //#define HAS_ONBOARD_SD_DETECT // If the SD_DETECT_PIN is wired up |
| 86 | + #endif |
| 87 | + #if ENABLED(HAS_ONBOARD_SD_DETECT) || !SD_CONNECTION_IS(ONBOARD) |
| 88 | + #define SD_DETECT_PIN 49 |
| 89 | + #endif |
| 90 | +#endif |
61 | 91 |
|
| 92 | +// |
| 93 | +// Based on RAMPS 1.4 |
| 94 | +// |
62 | 95 | #include "pins_RAMPS.h"
|
63 | 96 |
|
| 97 | +// |
| 98 | +// LCD / Controller |
| 99 | +// |
64 | 100 | #ifndef BEEPER_PIN
|
65 | 101 | #define BEEPER_PIN 37 // Always define beeper pin so Play Tone works with ExtUI
|
66 | 102 | #endif
|
67 |
| - |
68 |
| -#define EXP1_PIN 65 // A11 - Used by CR2020 Industrial series for case |
69 |
| -#define EXP2_PIN 66 // A12 |
70 |
| -#define EXP3_PIN 11 // SERVO0_PIN |
71 |
| -#define EXP4_PIN 12 // PS_ON_PIN |
72 |
| - |
73 |
| -#ifndef SUICIDE_PIN |
74 |
| - #define SUICIDE_PIN 12 // Used by CR2020 Industrial series |
75 |
| - #ifndef SUICIDE_PIN_STATE |
76 |
| - #define SUICIDE_PIN_STATE HIGH |
77 |
| - #endif |
78 |
| -#endif |
|
0 commit comments