Skip to content

Commit b650cc6

Browse files
committed
Use _delay_ms instead of delay.
This way it works even if the timers have been changed from the Arduino settings.
1 parent 3a8c239 commit b650cc6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/SFE_MicroOLED.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -283,9 +283,9 @@ void MicroOLED::beginCommon()
283283
// Display reset routine
284284
pinMode(rstPin, OUTPUT); // Set RST pin as OUTPUT
285285
digitalWrite(rstPin, HIGH); // Initially set RST HIGH
286-
delay(5); // VDD (3.3V) goes high at start, lets just chill for 5 ms
286+
_delay_ms(5); // VDD (3.3V) goes high at start, lets just chill for 5 ms
287287
digitalWrite(rstPin, LOW); // Bring RST low, reset the display
288-
delay(10); // wait 10ms
288+
_delay_ms(10); // wait 10ms
289289
digitalWrite(rstPin, HIGH); // Set RST HIGH, bring out of reset
290290

291291
// Display Init sequence for 64x48 OLED module

0 commit comments

Comments
 (0)