Fix some pin inits
This commit is contained in:
parent
bfa6cd3693
commit
449a31dea9
|
@ -123,12 +123,10 @@ void AnycubicTFTClass::OnSetup() {
|
||||||
|
|
||||||
// initialise the state of the key pins running on the tft
|
// initialise the state of the key pins running on the tft
|
||||||
#if ENABLED(SDSUPPORT) && PIN_EXISTS(SD_DETECT)
|
#if ENABLED(SDSUPPORT) && PIN_EXISTS(SD_DETECT)
|
||||||
pinMode(SD_DETECT_PIN, INPUT);
|
SET_INPUT_PULLUP(SD_DETECT_PIN);
|
||||||
WRITE(SD_DETECT_PIN, HIGH);
|
|
||||||
#endif
|
#endif
|
||||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||||
pinMode(FIL_RUNOUT_PIN, INPUT);
|
SET_INPUT_PULLUP(FIL_RUNOUT_PIN);
|
||||||
WRITE(FIL_RUNOUT_PIN, HIGH);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
mediaPrintingState = AMPRINTSTATE_NOT_PRINTING;
|
mediaPrintingState = AMPRINTSTATE_NOT_PRINTING;
|
||||||
|
|
|
@ -161,13 +161,13 @@ void printer_state_polling() {
|
||||||
|
|
||||||
void filament_pin_setup() {
|
void filament_pin_setup() {
|
||||||
#if PIN_EXISTS(MT_DET_1)
|
#if PIN_EXISTS(MT_DET_1)
|
||||||
pinMode(MT_DET_1_PIN, INPUT_PULLUP);
|
SET_INPUT_PULLUP(MT_DET_1_PIN);
|
||||||
#endif
|
#endif
|
||||||
#if PIN_EXISTS(MT_DET_2)
|
#if PIN_EXISTS(MT_DET_2)
|
||||||
pinMode(MT_DET_2_PIN, INPUT_PULLUP);
|
SET_INPUT_PULLUP(MT_DET_2_PIN);
|
||||||
#endif
|
#endif
|
||||||
#if PIN_EXISTS(MT_DET_3)
|
#if PIN_EXISTS(MT_DET_3)
|
||||||
pinMode(MT_DET_3_PIN, INPUT_PULLUP);
|
SET_INPUT_PULLUP(MT_DET_3_PIN);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue