Browse Source

Skip impossible PWM sanity-checks

Scott Lahteine 5 years ago
parent
commit
580d314fbe
2 changed files with 2 additions and 1 deletions
  1. 1
    0
      Marlin/src/HAL/STM32F1/HAL.h
  2. 1
    1
      Marlin/src/inc/SanityCheck.h

+ 1
- 0
Marlin/src/HAL/STM32F1/HAL.h View File

@@ -160,6 +160,7 @@ void HAL_idletask();
160 160
 
161 161
 #ifndef digitalPinHasPWM
162 162
   #define digitalPinHasPWM(P) (PIN_MAP[P].timer_device != nullptr)
163
+  #define NO_COMPILE_TIME_PWM
163 164
 #endif
164 165
 
165 166
 #define CRITICAL_SECTION_START()  uint32_t primask = __get_primask(); (void)__iCliRetVal()

+ 1
- 1
Marlin/src/inc/SanityCheck.h View File

@@ -1985,7 +1985,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
1985 1985
 /**
1986 1986
  * Auto Fan check for PWM pins
1987 1987
  */
1988
-#if HAS_AUTO_FAN && EXTRUDER_AUTO_FAN_SPEED != 255
1988
+#if HAS_AUTO_FAN && EXTRUDER_AUTO_FAN_SPEED != 255 && DISABLED(NO_COMPILE_TIME_PWM)
1989 1989
   #define AF_ERR_SUFF "_AUTO_FAN_PIN is not a PWM pin. Set EXTRUDER_AUTO_FAN_SPEED to 255."
1990 1990
   #if HAS_AUTO_FAN_0
1991 1991
     static_assert(PWM_PIN(E0_AUTO_FAN_PIN), "E0" AF_ERR_SUFF);

Loading…
Cancel
Save