![]() |
Demo HCI Implementation for WiMOD-LR Devices
V1.3.1
|
Main class representing the interface to the WiMOD running the firmware LoRaWAN EndNode Modem. More...
#include <WiMODLoRaWAN.h>
Public Member Functions | |
WiMODLoRaWAN (Stream &s) | |
Constructor. More... | |
~WiMODLoRaWAN (void) | |
Desctructor. | |
void | begin (void) |
This function must be called once before any other service can be used. More... | |
void | end (void) |
Shut shut down function. | |
bool | Ping (TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Ping Cmd - Checks the serial connection to the WiMOD module. More... | |
bool | Reset (TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Reset Cmd - Reboots the WiMOD module. More... | |
bool | GetDeviceInfo (TWiMODLR_DevMgmt_DevInfo *info, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
GetDeviceInfo Cmd - Gets the basic device information of the WiMOD. More... | |
bool | GetFirmwareInfo (TWiMODLR_DevMgmt_FwInfo *info, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
GetFirmwareInfo Cmd - Gets the basic information about the firmware of the WiMOD. More... | |
bool | GetSystemStatus (TWiMODLR_DevMgmt_SystemStatus *info, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
GetSystemStatus Cmd - Gets the basic information about the system status of the WiMOD. More... | |
bool | GetRtc (UINT32 *rtcTime, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Gets the current RTC data info from WiMOD module. More... | |
bool | SetRtc (const UINT32 rtcTime, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Sets the current RTC values to WiMOD module. More... | |
bool | GetOperationMode (TWiMOD_OperationMode *opMode, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Gets the current operation mode of the WiMOD module. More... | |
bool | SetOperationMode (const TWiMOD_OperationMode opMode, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Sets the current operation mode of the WiMOD module. More... | |
bool | SetRtcAlarm (const TWiMODLR_DevMgmt_RtcAlarm *rtcAlarm, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Sets and enables the RTC alarm feature of the WiMOD. More... | |
bool | GetRtcAlarm (TWiMODLR_DevMgmt_RtcAlarm *rtcAlarm, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Gets information about the RTC alarm feature of the WiMOD. More... | |
bool | ClearRtcAlarm (TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Clears pending RTC Alarms of the WiMOD. More... | |
void | RegisterPowerUpIndicationClient (TDevMgmtPowerUpCallback cb) |
Register a callback function for the PowerUp Indication - optional -. More... | |
void | RegisterRtcAlarmIndicationClient (TDevMgmtRtcAlarmCallback cb) |
Register a callback function for the RTC Alarm Indication - optional -. More... | |
bool | ActivateDevice (TWiMODLORAWAN_ActivateDeviceData &activationData, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Activates the device via the APB procedure. More... | |
bool | ReactivateDevice (UINT32 *devAdr, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Re-Activates the device via the APB procedure. More... | |
bool | SetJoinParameter (TWiMODLORAWAN_JoinParams &joinParams, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Sets the parameters used for the OTAA activation procedure. More... | |
bool | JoinNetwork (TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Start joining the network via the OTAA procedure. Asynchronous process. More... | |
void | RegisterJoinTxIndicationClient (TJoinTxIndicationCallback cb) |
Register a callback function for the event "TX Join Indication". More... | |
bool | convert (TWiMODLR_HCIMessage &RxMsg, TWiMODLORAWAN_RX_Data *loraWanRxData) |
Convert a received low level HCI-Msg to a high-level Rx Data structure. More... | |
bool | convert (TWiMODLR_HCIMessage &rxMsg, TWiMODLORAWAN_TxIndData *sendIndData) |
Convert a received low level HCI-Msg to a high-level tx ind structure. More... | |
bool | convert (TWiMODLR_HCIMessage &RxMsg, TWiMODLORAWAN_RX_MacCmdData *loraWanMacCmdData) |
Convert a received low level HCI-Msg to a high-level MAC-Cmd structure. More... | |
bool | convert (TWiMODLR_HCIMessage &RxMsg, TWiMODLORAWAN_RX_JoinedNwkData *joinedNwkData) |
Convert a received low level HCI-Msg to a high-level NwkJoined structure. More... | |
bool | convert (TWiMODLR_HCIMessage &RxMsg, TWiMODLORAWAN_RX_ACK_Data *ackData) |
Convert a received low level HCI-Msg to a high-level AckData structure. More... | |
void | RegisterNoDataIndicationClient (TNoDataIndicationCallback cb) |
Register a callback function for the event "TX Join Indication". More... | |
void | RegisterTxCDataIndicationClient (TTxCDataIndicationCallback cb) |
Register a callback function for the event "TX C-Data Indication". More... | |
void | RegisterTxUDataIndicationClient (TTxUDataIndicationCallback cb) |
Register a callback function for the event "TX U Data Indication". More... | |
void | RegisterRxUDataIndicationClient (TRxUDataIndicationCallback cb) |
Register a callback function for the event "RX U-Data Indication". More... | |
void | RegisterRxCDataIndicationClient (TRxCDataIndicationCallback cb) |
Register a callback function for the event "RX C-Data Indication". More... | |
void | RegisterRxMacCmdIndicationClient (TRxMacCmdIndicationCallback cb) |
Register a callback function for the event "RX MAC Cmd Indication". More... | |
void | RegisterJoinedNwkIndicationClient (TJoinedNwkIndicationCallback cb) |
Register a callback function for the event "Joined Nwk Indication". More... | |
void | RegisterRxAckIndicationClient (TRxAckIndicationCallback cb) |
Register a callback function for the event "RX ACK (data) Indication". More... | |
bool | SendUData (const TWiMODLORAWAN_TX_Data *data, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Tries to send transmit U-Data to network server via RF link. More... | |
bool | SendCData (const TWiMODLORAWAN_TX_Data *data, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Tries to send transmit C-Data to network server via RF link. More... | |
bool | SetRadioStackConfig (const TWiMODLORAWAN_RadioStackConfig *data, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Sets a new radio config parameter set of the WiMOD. More... | |
bool | GetRadioStackConfig (TWiMODLORAWAN_RadioStackConfig *data, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Gets the current radio config parameter set of the WiMOD. More... | |
bool | DeactivateDevice (TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Deactivate the device (logical disconnect from lora network) More... | |
bool | FactoryReset (TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Reset all internal settings to default values (incl. DevEUI !!!) More... | |
bool | SetDeviceEUI (const UINT8 *deviceEUI, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Sets a new DeviceEUI (aka. IEEE-Address) to the WiMOD. More... | |
bool | GetDeviceEUI (UINT8 *deviceEUI, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Gets the DeviceEUI (aka. IEEE-Address) of the WiMOD. More... | |
bool | GetNwkStatus (TWiMODLORAWAN_NwkStatus_Data *nwkStatus, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Gets the current status of the network "connection". More... | |
bool | SendMacCmd (const TWiMODLORAWAN_MacCmd *cmd, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Send a MAC command to the server; expert level only. More... | |
bool | SetCustomConfig (const INT8 txPwrOffset, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Setup a custom config for tx power settings; expert level only. More... | |
bool | GetCustomConfig (INT8 *txPwrOffset, TWiMDLRResultCodes *hciResult=NULL, UINT8 *rspStatus=NULL) |
Get the current offet for tx power level; expert level only. More... | |
TWiMDLRResultCodes | GetLastHciResult (void) |
Gets the last HCI result code from the last executed command. More... | |
UINT8 | GetLastResponseStatus (void) |
Gets the last response code of the WiMOD of the last executed command. More... | |
![]() | |
TWiMODLRHCI (Stream &s) | |
Constructor. More... | |
~TWiMODLRHCI (void) | |
Destructor. | |
TWiMDLRResultCodes | SendHCIMessage (UINT8 dstSapID, UINT8 msgID, UINT8 rxMsgID, UINT8 *payload, UINT16 length) |
Generic function for transferring a HCI message to the WiMOD module. More... | |
void | Process (void) |
Handle the receiver path; process all incomming bytes from the WiMOD. More... | |
void | SendWakeUpSequence (void) |
: Send a sequence of dummy chars to give the WiMOD some time to wake up | |
void | RegisterStackErrorClient (TWiMODStackErrorClient cb) |
const TWiMODLR_HCIMessage & | GetRxMessage (void) |
![]() | |
virtual UINT8 * | ProcessRxMessage (UINT8 *, UINT16) |
Protected Member Functions | |
virtual void | ProcessUnexpectedRxMessage (TWiMODLR_HCIMessage &rxMsg) |
bool | copyLoRaWanResultInfos (TWiMDLRResultCodes *hciResult, UINT8 *rspStatus) |
bool | copyDevMgmtResultInfos (TWiMDLRResultCodes *hciResult, UINT8 *rspStatus) |
Protected Attributes | |
WiMOD_SAP_DevMgmt | SapDevMgmt |
WiMOD_SAP_LoRaWAN | SapLoRaWan |
Main class representing the interface to the WiMOD running the firmware LoRaWAN EndNode Modem.
THIS IS AN EXAMPLE IMPLEMENTATION ACCORDING THE THE HCI SPEC: V1.12 FOR FIRMWARE: LoRaWAN This class is the only API class a user should use for interacting with a WiMOD module that runs the IMST LoRaWAN EndNode Modem firmware.
WiMODLoRaWAN::WiMODLoRaWAN | ( | Stream & | s | ) |
Constructor.
This function requires a cpp reference to the serial interface object that is to be used for communication.
bool WiMODLoRaWAN::ActivateDevice | ( | TWiMODLORAWAN_ActivateDeviceData & | activationData, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Activates the device via the APB procedure.
activationData | structure holding the necessary parameters |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
|
virtual |
This function must be called once before any other service can be used.
Reimplemented from TWiMODLRHCI.
bool WiMODLoRaWAN::ClearRtcAlarm | ( | TWiMDLRResultCodes * | hciResult = NULL , |
UINT8 * | rspStatus = NULL |
||
) |
Clears pending RTC Alarms of the WiMOD.
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::convert | ( | TWiMODLR_HCIMessage & | RxMsg, |
TWiMODLORAWAN_RX_Data * | loraWanRxData | ||
) |
Convert a received low level HCI-Msg to a high-level Rx Data structure.
This function should be used by the Rx Data Indication Callback functions prior processing the received data message.
RxMsg | Reference to low-level HCI message. |
loraWanRxData | Pointer to the buffer where to store the received data |
true | if the conversion was successful |
bool WiMODLoRaWAN::convert | ( | TWiMODLR_HCIMessage & | RxMsg, |
TWiMODLORAWAN_TxIndData * | sendIndData | ||
) |
Convert a received low level HCI-Msg to a high-level tx ind structure.
This function should be used by the Tx Data Indication Callback functions prior processing the received data message.
RxMsg | Reference to low-level HCI message. |
sendIndData | Pointer to the buffer where to store the received data |
true | if the conversion was successful |
bool WiMODLoRaWAN::convert | ( | TWiMODLR_HCIMessage & | RxMsg, |
TWiMODLORAWAN_RX_MacCmdData * | loraWanMacCmdData | ||
) |
Convert a received low level HCI-Msg to a high-level MAC-Cmd structure.
This function should be used by the Rx Mac Cmd Indication Callback function prior processing the received data message.
RxMsg | Reference to low-level HCI message. |
loraWanMacCmdData | Pointer to the buffer where to store the received data |
true | if the conversion was successful |
bool WiMODLoRaWAN::convert | ( | TWiMODLR_HCIMessage & | RxMsg, |
TWiMODLORAWAN_RX_JoinedNwkData * | joinedNwkData | ||
) |
Convert a received low level HCI-Msg to a high-level NwkJoined structure.
This function should be used by the JoinedNwk Indication Callback function prior processing the received data message.
RxMsg | Reference to low-level HCI message. |
joinedNwkData | Pointer to the buffer where to store the received data |
true | if the conversion was successful |
bool WiMODLoRaWAN::convert | ( | TWiMODLR_HCIMessage & | RxMsg, |
TWiMODLORAWAN_RX_ACK_Data * | ackData | ||
) |
Convert a received low level HCI-Msg to a high-level AckData structure.
This function should be used by the Rx Ack Indication Callback function prior processing the received data message.
RxMsg | Reference to low-level HCI message. |
ackData | Pointer to the buffer where to store the received data |
true | if the conversion was successful |
bool WiMODLoRaWAN::DeactivateDevice | ( | TWiMDLRResultCodes * | hciResult = NULL , |
UINT8 * | rspStatus = NULL |
||
) |
Deactivate the device (logical disconnect from lora network)
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::FactoryReset | ( | TWiMDLRResultCodes * | hciResult = NULL , |
UINT8 * | rspStatus = NULL |
||
) |
Reset all internal settings to default values (incl. DevEUI !!!)
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetCustomConfig | ( | INT8 * | txPwrOffset, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Get the current offet for tx power level; expert level only.
txPwrOffset | pointer to store the offset value for tx power settings |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetDeviceEUI | ( | UINT8 * | deviceEUI, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Gets the DeviceEUI (aka. IEEE-Address) of the WiMOD.
deviceEUI | pointer for storing the received 64bit address |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetDeviceInfo | ( | TWiMODLR_DevMgmt_DevInfo * | info, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
GetDeviceInfo Cmd - Gets the basic device information of the WiMOD.
info | pointer for storing the requested information (structure) |
hciResult | pointer for storing the the local HCI transfer result. This is an optional parameter. |
rspStatus | pointer to store the response code of the WiMOD This is an optional parameter. |
true | if everything was successful |
bool WiMODLoRaWAN::GetFirmwareInfo | ( | TWiMODLR_DevMgmt_FwInfo * | info, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
GetFirmwareInfo Cmd - Gets the basic information about the firmware of the WiMOD.
info | pointer for storing the requested information (structure) |
hciResult | pointer for storing the the local HCI transfer result. This is an optional parameter. |
rspStatus | pointer to store the response code of the WiMOD This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
TWiMDLRResultCodes WiMODLoRaWAN::GetLastHciResult | ( | void | ) |
Gets the last HCI result code from the last executed command.
If you missed setting the HciResult parameter while executing the last command, this method can recall the last value of that parameter.
UINT8 WiMODLoRaWAN::GetLastResponseStatus | ( | void | ) |
Gets the last response code of the WiMOD of the last executed command.
If you missed setting the rspStatus parameter while executing the last command, this method can recall the last value of that parameter.
bool WiMODLoRaWAN::GetNwkStatus | ( | TWiMODLORAWAN_NwkStatus_Data * | nwkStatus, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Gets the current status of the network "connection".
nwkStatus | pointer for storing the requested information |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetOperationMode | ( | TWiMOD_OperationMode * | opMode, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Gets the current operation mode of the WiMOD module.
opMode | Pointer where to store the information |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetRadioStackConfig | ( | TWiMODLORAWAN_RadioStackConfig * | data, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Gets the current radio config parameter set of the WiMOD.
data | pointer to data structure for storing the requested information |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetRtc | ( | UINT32 * | rtcTime, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Gets the current RTC data info from WiMOD module.
rtcTime | Pointer where to store the RTC information |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetRtcAlarm | ( | TWiMODLR_DevMgmt_RtcAlarm * | rtcAlarm, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Gets information about the RTC alarm feature of the WiMOD.
rtcAlarm | Pointer to a structure where to store the RTC alarm related information |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::GetSystemStatus | ( | TWiMODLR_DevMgmt_SystemStatus * | info, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
GetSystemStatus Cmd - Gets the basic information about the system status of the WiMOD.
info | pointer for storing the requested information (structure) |
hciResult | pointer for storing the the local HCI transfer result. This is an optional parameter. |
rspStatus | pointer to store the response code of the WiMOD This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::JoinNetwork | ( | TWiMDLRResultCodes * | hciResult = NULL , |
UINT8 * | rspStatus = NULL |
||
) |
Start joining the network via the OTAA procedure. Asynchronous process.
This functions starts an asynchronous process of joining to a network. It will take a time until a (final) result is ready. Therefore the callback interface (e.g. RegisterJoinedNwkIndicationClient) should be used.
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::Ping | ( | TWiMDLRResultCodes * | hciResult = NULL , |
UINT8 * | rspStatus = NULL |
||
) |
Ping Cmd - Checks the serial connection to the WiMOD module.
hciResult | pointer for storing the the local HCI transfer result. This is an optional parameter. |
rspStatus | pointer to store the response code of the WiMOD This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
OR:
OR:
bool WiMODLoRaWAN::ReactivateDevice | ( | UINT32 * | devAdr, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Re-Activates the device via the APB procedure.
In case the device has been previously activated (e.g. during manufacturing) the user does not know the security keys. In this case a re-activation procedure must be used in order to use the stored values. (For APB ONLY!)
devAdr | pointer where the store the "received" device address |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
void WiMODLoRaWAN::RegisterJoinedNwkIndicationClient | ( | TJoinedNwkIndicationCallback | cb | ) |
Register a callback function for the event "Joined Nwk Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. ![]() |
void WiMODLoRaWAN::RegisterJoinTxIndicationClient | ( | TJoinTxIndicationCallback | cb | ) |
Register a callback function for the event "TX Join Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. |
void WiMODLoRaWAN::RegisterNoDataIndicationClient | ( | TNoDataIndicationCallback | cb | ) |
Register a callback function for the event "TX Join Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. |
void WiMODLoRaWAN::RegisterPowerUpIndicationClient | ( | TDevMgmtPowerUpCallback | cb | ) |
Register a callback function for the PowerUp Indication - optional -.
cb | Pointer a callback function |
void WiMODLoRaWAN::RegisterRtcAlarmIndicationClient | ( | TDevMgmtRtcAlarmCallback | cb | ) |
Register a callback function for the RTC Alarm Indication - optional -.
cb | Pointer a callback function |
void WiMODLoRaWAN::RegisterRxAckIndicationClient | ( | TRxAckIndicationCallback | cb | ) |
Register a callback function for the event "RX ACK (data) Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. ![]() |
void WiMODLoRaWAN::RegisterRxCDataIndicationClient | ( | TRxCDataIndicationCallback | cb | ) |
Register a callback function for the event "RX C-Data Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. ![]() |
void WiMODLoRaWAN::RegisterRxMacCmdIndicationClient | ( | TRxMacCmdIndicationCallback | cb | ) |
Register a callback function for the event "RX MAC Cmd Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. ![]() |
void WiMODLoRaWAN::RegisterRxUDataIndicationClient | ( | TRxUDataIndicationCallback | cb | ) |
Register a callback function for the event "RX U-Data Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. ![]() |
void WiMODLoRaWAN::RegisterTxCDataIndicationClient | ( | TTxCDataIndicationCallback | cb | ) |
Register a callback function for the event "TX C-Data Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. ![]() |
void WiMODLoRaWAN::RegisterTxUDataIndicationClient | ( | TTxUDataIndicationCallback | cb | ) |
Register a callback function for the event "TX U Data Indication".
This registered callback is called when the specified event is called by the WiMOD stack.
cb | pointer to a callback function that should be called if the event occurs. |
bool WiMODLoRaWAN::Reset | ( | TWiMDLRResultCodes * | hciResult = NULL , |
UINT8 * | rspStatus = NULL |
||
) |
Reset Cmd - Reboots the WiMOD module.
hciResult | pointer for storing the the local HCI transfer result. This is an optional parameter. |
rspStatus | pointer to store the response code of the WiMOD This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SendCData | ( | const TWiMODLORAWAN_TX_Data * | data, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Tries to send transmit C-Data to network server via RF link.
data | pointer to data structure containing the TX-data and options. |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SendMacCmd | ( | const TWiMODLORAWAN_MacCmd * | cmd, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Send a MAC command to the server; expert level only.
cmd | pointer containing the MAC command and parameters |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SendUData | ( | const TWiMODLORAWAN_TX_Data * | data, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Tries to send transmit U-Data to network server via RF link.
data | pointer to data structure containing the TX-data and options. |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetCustomConfig | ( | const INT8 | txPwrOffset, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Setup a custom config for tx power settings; expert level only.
txPwrOffset | new offset value for tx power settings |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetDeviceEUI | ( | const UINT8 * | deviceEUI, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Sets a new DeviceEUI (aka. IEEE-Address) to the WiMOD.
Note: Setting a new DeviceEUI is requires to switch to customer operation mode. In "normal" application mode, this command is locked.
deviceEUI | pointer to data structure containing the new parameters (Must be an pointer of a 64bit address) |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetJoinParameter | ( | TWiMODLORAWAN_JoinParams & | joinParams, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Sets the parameters used for the OTAA activation procedure.
joinParams | structure holding the necessary parameters |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetOperationMode | ( | const TWiMOD_OperationMode | opMode, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Sets the current operation mode of the WiMOD module.
opMode | The new operation mode to set |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetRadioStackConfig | ( | const TWiMODLORAWAN_RadioStackConfig * | data, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Sets a new radio config parameter set of the WiMOD.
data | pointer to data structure containing the new parameters |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetRtc | ( | const UINT32 | rtcTime, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Sets the current RTC values to WiMOD module.
rtcTime | RTC information to setup |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
bool WiMODLoRaWAN::SetRtcAlarm | ( | const TWiMODLR_DevMgmt_RtcAlarm * | rtcAlarm, |
TWiMDLRResultCodes * | hciResult = NULL , |
||
UINT8 * | rspStatus = NULL |
||
) |
Sets and enables the RTC alarm feature of the WiMOD.
rtcAlarm | Pointer to a structure containing the RTC alarm related information |
hciResult | Result of the local command transmission to module This is an optional parameter. |
rspStatus | Status byte contained in the local response of the module This is an optional parameter. |
true | if everything is ok |
false | if something went wrong; see hciResult & rspStatus for details |
|
protected |
Service Access Point for 'DeviceManagement'
|
protected |
Service Access Point for 'LoRaWAN'