diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h index 1660b6d3a6..fb53c40647 100644 --- a/Marlin/Configuration.h +++ b/Marlin/Configuration.h @@ -1460,7 +1460,7 @@ #define FIL_RUNOUT_ENABLED_DEFAULT false // Enable the sensor on startup. Override with M412 followed by M500. #define NUM_RUNOUT_SENSORS 1 // Number of sensors, up to one per extruder. Define a FIL_RUNOUT#_PIN for each. - #define FIL_RUNOUT_STATE HIGH // Pin state indicating that filament is NOT present. + #define FIL_RUNOUT_STATE FIL_RUNOUT_LEVEL // Pin state indicating that filament is NOT present. //#define FIL_RUNOUT_PULLUP // Use internal pullup for filament runout pins. //#define FIL_RUNOUT_PULLDOWN // Use internal pulldown for filament runout pins. //#define WATCH_ALL_RUNOUT_SENSORS // Execute runout script on any triggering sensor, not only for the active extruder. diff --git a/Marlin/src/pins/stm32f1/pins_MKS_ROBIN_NANO.h b/Marlin/src/pins/stm32f1/pins_MKS_ROBIN_NANO.h index 13724103f4..6efcf64f04 100644 --- a/Marlin/src/pins/stm32f1/pins_MKS_ROBIN_NANO.h +++ b/Marlin/src/pins/stm32f1/pins_MKS_ROBIN_NANO.h @@ -36,6 +36,16 @@ #define BOARD_NO_NATIVE_USB +//#define PRINTER_NAME_FB5 +#define PRINTER_NAME_FB4S + + +#ifdef PRINTER_NAME_FB5 + #ifdef PRINTER_NAME_FB4S + #error "Select only one printer name" + #endif +#endif + // Avoid conflict with TIMER_SERVO when using the STM32 HAL #define TEMP_TIMER 5 @@ -184,6 +194,18 @@ https://sergey1560.github.io/fb4s_howto/mks_pwc/ #define FIL_RUNOUT2_PIN PE6 #endif +#ifdef PRINTER_NAME_FB5 + #define FIL_RUNOUT_LEVEL LOW +#endif + +#ifdef PRINTER_NAME_FB4S + #define FIL_RUNOUT_LEVEL HIGH +#endif + +#ifndef FIL_RUNOUT_LEVEL + #define FIL_RUNOUT_LEVEL HIGH +#endif + // // SD Card // diff --git a/Marlin/src/pins/stm32f4/pins_MKS_ROBIN_NANO_S_V13.h b/Marlin/src/pins/stm32f4/pins_MKS_ROBIN_NANO_S_V13.h index 810195b219..0013db20a6 100644 --- a/Marlin/src/pins/stm32f4/pins_MKS_ROBIN_NANO_S_V13.h +++ b/Marlin/src/pins/stm32f4/pins_MKS_ROBIN_NANO_S_V13.h @@ -30,6 +30,8 @@ #define BOARD_INFO_NAME "MKS Robin Nano-S V1.3" +#define PRINTER_NAME_FB5 + #define EXT_EXTRUDER_DRIVER 0 // Если нужен сменный драйвер в слоте второго экструдера как основной экструдер, установить в единицу! #define SPI_DEVICE 2 @@ -148,6 +150,10 @@ #define FIL_RUNOUT2_PIN MT_DET_2_PIN #endif +#ifndef FIL_RUNOUT_LEVEL + #define FIL_RUNOUT_LEVEL HIGH +#endif + #ifndef SDCARD_CONNECTION #define SDCARD_CONNECTION ONBOARD #endif