From 6ea04f1f6be11fb8633beff35f1ff5904a66f972 Mon Sep 17 00:00:00 2001 From: Paul Mathieu Date: Sun, 14 Mar 2021 12:18:01 -0700 Subject: [PATCH] dsp: some UART logging \o/ --- dsp/main.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/dsp/main.c b/dsp/main.c index 06cd6ce..591711f 100644 --- a/dsp/main.c +++ b/dsp/main.c @@ -16,18 +16,25 @@ int main() { uint16_t period; if (c == 'c') { period = 1493; // C4, 262.63 Hz, maybe + uart_writen(uart0, "C4\r\n", 4); } else if (c == 'd') { period = 1330; // D4, 293.66 Hz, maybe + uart_writen(uart0, "D4\r\n", 4); } else if (c == 'e') { period = 1185; // E4, 329.63 Hz, maybe + uart_writen(uart0, "E4\r\n", 4); } else if (c == 'f') { period = 1119; // F4, 249.23 Hz, maybe + uart_writen(uart0, "F4\r\n", 4); } else if (c == 'g') { period = 996; // G4, 392.00 Hz, maybe + uart_writen(uart0, "G4\r\n", 4); } else if (c == 'a') { period = 887; // A4, 440.00 Hz, maybe + uart_writen(uart0, "A4\r\n", 4); } else if (c == 'b') { period = 791; // B4, 493.88 Hz, maybe + uart_writen(uart0, "B4\r\n", 4); } square0->period = period;