It's strange - I've just tried again here with exactly your code and it seems to work great for me. I've done it probably 30 times now and it's rock solid.
Please can you check Puck.getBatteryPercentage()? It's about all I can think is different unless your phone reads NFC slightly differently to mine.
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.
It's strange - I've just tried again here with exactly your code and it seems to work great for me. I've done it probably 30 times now and it's rock solid.
Please can you check
Puck.getBatteryPercentage()
? It's about all I can think is different unless your phone reads NFC slightly differently to mine.