Atob() function in javascript uplink decoder

I’m using the followind uplink decoder:

image

But I got this error when trying to decode a payload:

image

How can atob be called in V3 or which alternatives do you recommend?

Thanks a lot!

Apart from the fact that there is no window as the JS doesn’t run in a browser, the input is an object and the input.bytes is a binary array - ie it’s already decoded for you.

Please read: Javascript | The Things Stack for LoRaWAN

Also, your code implies you are sending strings of numbers - please don’t, it is highly inefficient, please read: https://www.thethingsnetwork.org/docs/devices/bytes/

EDIT: Actually, for atob, that implies you think you have a binary array that you want to turn in to Base64. So I suspect you are doing something beyond my understanding.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.