File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ void calibrate_delay_loop();
100
100
101
101
// For delay in microseconds, no smart delay selection is required, directly call the delay function
102
102
// Teensy compiler is too old and does not accept smart delay compile-time / run-time selection correctly
103
- #define DELAY_US (x ) DelayCycleFnc((x) * ((F_CPU) / 1000000UL ))
103
+ #define DELAY_US (x ) DelayCycleFnc((unsigned long )( x) * ((F_CPU) / 1000000UL ))
104
104
105
105
#elif defined(__AVR__)
106
106
FORCE_INLINE static void __delay_up_to_3c (uint8_t cycles) {
@@ -164,7 +164,7 @@ void calibrate_delay_loop();
164
164
}
165
165
166
166
// Delay in microseconds
167
- #define DELAY_US (x ) DELAY_CYCLES((x) * ((F_CPU) / 1000000UL ))
167
+ #define DELAY_US (x ) DELAY_CYCLES((unsigned long )( x) * ((F_CPU) / 1000000UL ))
168
168
169
169
#define DELAY_CYCLES_VAR DELAY_CYCLES
170
170
@@ -173,7 +173,7 @@ void calibrate_delay_loop();
173
173
// DELAY_CYCLES specified inside platform
174
174
175
175
// Delay in microseconds
176
- #define DELAY_US (x ) DELAY_CYCLES((x) * ((F_CPU) / 1000000UL ))
176
+ #define DELAY_US (x ) DELAY_CYCLES((unsigned long )( x) * ((F_CPU) / 1000000UL ))
177
177
178
178
#define DELAY_CYCLES_VAR DELAY_CYCLES
179
179
You can’t perform that action at this time.
0 commit comments