Improve watch_tcc to decouple leds and buzzer as much as allowed

As a positive side effect, the led will stop emitting the faintiest
of blinks when the buzzer starts playing.
This commit is contained in:
Alessandro Genova
2025-08-17 23:14:25 -04:00
parent 1b9624d042
commit 04276c1999
6 changed files with 76 additions and 108 deletions
-4
View File
@@ -1,9 +1,5 @@
#include "watch.h"
bool watch_is_buzzer_or_led_enabled(void) {
return false;
}
bool watch_is_usb_enabled(void) {
return true;
}
@@ -51,8 +51,6 @@ int _gettimeofday(struct timeval *tv, void *tzvp) {
return 0;
}
void _watch_disable_tcc(void) {}
void _watch_enable_usb(void) {}
void watch_disable_TRNG() {}
@@ -46,8 +46,6 @@ static watch_cb_t _cb_start_global = NULL;
static watch_cb_t _cb_stop_global = NULL;
static volatile bool _buzzer_is_active = false;
void _watch_enable_tcc(void) {}
static inline void _em_interval_stop() {
emscripten_clear_interval(_em_interval_id);
_em_interval_id = 0;