Integration page

This commit is contained in:
cpq committed 2023-07-19 16:25:14 +01:00
1 parent ee80822564
commit 3415b62d2d
7 files changed
+2476 -2172

No files matched your search

@@ -24,7 +24,7 @@ void mg_random(void *buf, size_t len) { // Use on-board RNG
}
static void timer_fn(void *arg) {
gpio_toggle(LED); // Blink LED
//gpio_toggle(LED); // Blink LED
struct mg_tcpip_if *ifp = arg; // And show
const char *names[] = {"down", "up", "req", "ready"}; // network stats
MG_INFO(("Ethernet: %s, IP: %M, rx:%u, tx:%u, dr:%u, er:%u",
@@ -32,6 +32,13 @@ static void timer_fn(void *arg) {
ifp->ndrop, ifp->nerr));
}
bool led_get(void) {
return gpio_read(LED);
}
void led_set(bool val) {
gpio_write(LED, val);
}
int main(void) {
gpio_output(LED); // Setup green LED
uart_init(UART_DEBUG, 115200); // Initialise debug printf