aboutsummaryrefslogtreecommitdiff
path: root/main/main.cpp
blob: d85c76e269f90bd79fb02a4729fbeeb86dd63859 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include <FreeRTOS.h>
#include <task.h>

#include <pico/stdlib.h>

#include "config.h"
#include "init.h"

void blink_task() {
	while (true) {
		cyw43_arch_gpio_put(LED_PIN, 0);
		vTaskDelay(250 / portTICK_PERIOD_MS);
		cyw43_arch_gpio_put(LED_PIN, 1);
		vTaskDelay(250 / portTICK_PERIOD_MS);
	}
}

int main() {
	init();

	xTaskCreate((TaskFunction_t) blink_task, "blink", 128, NULL, 1, NULL);
	vTaskStartScheduler();
}