led blink example

* led blink example

* restore tests

* Update FURI_and_examples.md
This commit is contained in:
coreglitch
2020-08-26 07:56:33 +06:00
committed by GitHub
parent 2e023ffcda
commit bee159f435
14 changed files with 211 additions and 101 deletions

View File

@@ -0,0 +1,16 @@
#include "flipper.h"
void application_blink(void* p) {
// create pin
GpioPin led = {.pin = GPIO_PIN_8, .port = GPIOA};
// configure pin
pinMode(led, GpioModeOutput);
while(1) {
digitalWrite(led, HIGH);
delay(500);
digitalWrite(led, LOW);
delay(500);
}
}