fix simulator build by declaring Trng type as a void pointer

This commit is contained in:
Alex Maestas 2023-12-17 22:40:04 +00:00
parent 68f3865227
commit 93d7f38d67
2 changed files with 6 additions and 0 deletions

View file

@ -96,6 +96,10 @@ void watch_reset_to_bootloader(void);
*/
int read(int file, char *ptr, int len);
#ifdef __EMSCRIPTEN__
typedef void* Trng;
#endif
/** @brief Disables the TRNG, working around a silicon erratum.
*/
void watch_disable_TRNG(Trng* hw);

View file

@ -57,6 +57,8 @@ void _watch_disable_tcc(void) {}
void _watch_enable_usb(void) {}
void watch_disable_TRNG(Trng* hw) {}
// this function ends up getting called by printf to log stuff to the USB console.
int _write(int file, char *ptr, int len) {
// TODO: (a2) hook to UI