make delay to use rtos API
- also add delay_blocking() for non-rtos API function. Useful for calling in ISR or when scheduler is not started yet. - Make setup() invoked insided loop task since user may use setup() to do most of their work calling RTOS API.
This commit is contained in:
1 parent
991497ec56
commit
7b77fe8595
7 files changed
+42
-14
No files matched your search
@@ -19,10 +19,9 @@ BLEBas blebas;
|
||||
|
||||
void setup()
|
||||
{
|
||||
pinMode(LED_BUILTIN, OUTPUT);
|
||||
Serial.begin(115200);
|
||||
|
||||
Serial.println("BLEUART Example");
|
||||
Serial.println("Bluefruit52 BLEUART Example");
|
||||
|
||||
Bluefruit.begin();
|
||||
Bluefruit.setName("Bluefruit52");
|
||||
|
||||
@@ -16,7 +16,6 @@
|
||||
|
||||
void setup()
|
||||
{
|
||||
pinMode(LED_BUILTIN, OUTPUT);
|
||||
Serial.begin(115200);
|
||||
|
||||
Serial.println("Bluefruit52 Blinky Example");
|
||||
@@ -48,6 +47,6 @@ void loop()
|
||||
digitalToggle(LED_BUILTIN);
|
||||
digitalToggle(LED_CONN);
|
||||
|
||||
rtos_delay(1000);
|
||||
delay(1000);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user