Hi - that sounds like a good plan. I think what happens is that once you supply data to setAdvertising on the Puck, it's transmitted as a series of bytes regardless of how it was defined in JS.
Looks like it's being interpreted as a series of hexadecimal digits. If you've got "0000050f" then you should just be able to do msg.payload = parseInt(JSON.parse(msg.payload),16) in a 'function block' in node-red to get the number you want.
msg.payload = parseInt(JSON.parse(msg.payload),16)
© Espruino, powered by microcosm.
Report a problem