summaryrefslogtreecommitdiff
path: root/hid
diff options
context:
space:
mode:
authorMaxim Devaev <[email protected]>2023-08-07 00:13:48 +0300
committerMaxim Devaev <[email protected]>2023-08-07 00:13:48 +0300
commitef8fee5f9ca1496717f3a97663939d3f8b533b83 (patch)
tree8baff0c230be1f3885bd4253b2af9e8e9b8e40d6 /hid
parenta10c45a1c1857508e5349ea1ff5b267b0b6f77e6 (diff)
muted act led
Diffstat (limited to 'hid')
-rw-r--r--hid/pico/src/main.c5
-rw-r--r--hid/pico/src/ph_debug.c9
-rw-r--r--hid/pico/src/ph_debug.h3
3 files changed, 10 insertions, 7 deletions
diff --git a/hid/pico/src/main.c b/hid/pico/src/main.c
index 7d8c6843..8b551a97 100644
--- a/hid/pico/src/main.c
+++ b/hid/pico/src/main.c
@@ -120,7 +120,8 @@ static void _timeout_handler(void) {
int main(void) {
- ph_debug_init(false); // No UART
+ //ph_debug_act_init();
+ //ph_debug_uart_init();
ph_outputs_init();
ph_usb_init();
@@ -135,7 +136,7 @@ int main(void) {
ph_usb_task();
if (!_reset_required) {
_COMM(task);
- ph_debug_act_pulse(100);
+ //ph_debug_act_pulse(100);
}
}
return 0;
diff --git a/hid/pico/src/ph_debug.c b/hid/pico/src/ph_debug.c
index 79eb64a3..ee497a31 100644
--- a/hid/pico/src/ph_debug.c
+++ b/hid/pico/src/ph_debug.c
@@ -33,10 +33,11 @@
#define _ACT_PIN 25
-void ph_debug_init(bool enable_uart) {
- if (enable_uart) {
- stdio_uart_init_full(_UART, _SPEED, _TX_PIN, _RX_PIN);
- }
+void ph_debug_uart_init(void) {
+ stdio_uart_init_full(_UART, _SPEED, _TX_PIN, _RX_PIN);
+}
+
+void ph_debug_act_init(void) {
gpio_init(_ACT_PIN);
gpio_set_dir(_ACT_PIN, GPIO_OUT);
}
diff --git a/hid/pico/src/ph_debug.h b/hid/pico/src/ph_debug.h
index 4dd92ce3..32dcd691 100644
--- a/hid/pico/src/ph_debug.h
+++ b/hid/pico/src/ph_debug.h
@@ -23,6 +23,7 @@
#include "ph_types.h"
-void ph_debug_init(bool enable_uart);
+void ph_debug_uart_init();
+void ph_debug_act_init();
void ph_debug_act(bool flag);
void ph_debug_act_pulse(u64 delay_ms);