I've been able to reproduce the issue a couple times and I got your exact symptoms - no logs, only the bluetooth widget frozen, completely unresponsive until I reset by holding BTN1+BTN2.
Looking at the content of the WIDGETS array on my watch, I see that the order of the widgets is bluetooth, batpc, ram. The fact that the ram widgets is consistently the only one visible when it freezes is makes me suspect the issue might somehow be triggered by the battery (with percentage) widget.
I modified your code a bit because I'm impatient, and now it generally hangs within 5 minutes:
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
I've been able to reproduce the issue a couple times and I got your exact symptoms - no logs, only the bluetooth widget frozen, completely unresponsive until I reset by holding BTN1+BTN2.
Looking at the content of the WIDGETS array on my watch, I see that the order of the widgets is bluetooth, batpc, ram. The fact that the ram widgets is consistently the only one visible when it freezes is makes me suspect the issue might somehow be triggered by the battery (with percentage) widget.
I modified your code a bit because I'm impatient, and now it generally hangs within 5 minutes: