Skip to main content
Version: 2.9.10 - 2.7.7

LoRa

api.loraSend(ack, timeout, msg, port)

Sends buffer msg to LoRa. Acknowledged or non-acknowledged transport can be used using ack parameter. Maximum execution time is limited by timeout in milliseconds.

api.loraJoin(int, dr)

Sends join request.

Rejoin is made automaticaly once per 7 days by default, but it can be changed using following "api.loraSetup" function.

api.loraSetup(s1, s2)

Sets parameters defined by strings s1 and s2.

This function resets previous activation settings. Meaning, if you call repeatedly api.loraSetup("ACTIVATION", "OTAA") it'll send join request each time this function is called.

Before setting up the device to class B or C, verify it's supported/enabled by the Network server you use. Otherwise, it won't switch the class.

api.loraListenClassBC(timeout, class)

Listens for message until received or timeout in class C.

Firstly set the device to class B or C before using this function and verify it's supported by the Network server.

api.loraSetCredential(var1, var2)

Sets only one LoRa credential.

By Calling this function, the converter also sends Join request.

api.loraSetCredentials(devADDR, devEUI, nwsKey, appsKey, appEUI)

Sets LoRa credentials.

By Calling this function, the converter also sends Join request.