Skip to main content
Version: 2.14.4 - 2.14.0

LoRa

This category contains functions specific to LoRaWAN devices.

api.loraSend(ack, timeout, msg)

Sends and receives LoRaWAN frames.

api.loraJoin()

Sends join request.

info

Rejoining occurs automatically every 7 days by default. This interval can be modified using the api.loraSetup() function.

api.loraSetup(parameter, ...)

Configures LoRaWAN parameters.

warning

This function resets the previous activation settings. This means that if you repeatedly call api.loraSetup("ACTIVATION", "OTAA"), a join request will be sent each time the function is executed.

info

Before setting up the device to class B or C, verify it's supported/enabled by the network server you use. Otherwise, the device will not switch to the specified class.

api.loraListenClassBC(timeout)

Listens for message until timeout in class B or C.

warning

The device needs to be set to Class B or Class C before using this function. Ensure that it is supported by the Network Server.

api.loraSetCredential(credential, ...)

Sets one LoRa credential.

info

When this function is called, the device automatically sends a Join Request.

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

Sets LoRa credentials.

info

When this function is called, the device automatically sends a Join Request.

api.loraGetDevEui(format)

Retrieves the devEUI.