It's a common thing with Espruino - the 'console' moves from USB to Serial1 when USB is disconnected - which lets you connect a totally unprogrammed Pico to something like Bluetooth so you can program it.
When it moves, it then stops you reading back data on Serial1. Easy solution is to just put the following right at the top of your code that runs on initialisation:
function onInit() {
USB.setConsole();
// ...
}
It'll force the console on to USB (even if USB isn't connected)
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.
Have you connected the Huzzah to B6/B7?
It's a common thing with Espruino - the 'console' moves from USB to Serial1 when USB is disconnected - which lets you connect a totally unprogrammed Pico to something like Bluetooth so you can program it.
When it moves, it then stops you reading back data on Serial1. Easy solution is to just put the following right at the top of your code that runs on initialisation:
It'll force the console on to USB (even if USB isn't connected)