Demo HCI Implementation for WiMOD-LR Devices  V2.0.3
WiMOD_SAP_LORAWAN_ProLink_IDs.h
Go to the documentation of this file.
1 //------------------------------------------------------------------------------
31 //------------------------------------------------------------------------------
32 
33 
34 /*
35  * THIS IS AN EXAMPLE IMPLEMENTATION ACCORDING THE THE HCI SPEC: V2.0
36  * FOR FIRMWARE: ProLink_
37  *
38  * SEE FILE: ProLink_LoRaWAN_EndNode_Modem_HCI_Spec.pdf (version 2.0)
39  * for detailed information
40  *
41  */
42 
43 
44 #ifndef ARDUINO_SAP_WIMOD_SAP_LORAWAN_PROLINK_IDS_H_
45 #define ARDUINO_SAP_WIMOD_SAP_LORAWAN_PROLINK_IDS_H_
46 
47 #include "utils/WMDefs.h"
48 
49 #include "WiMOD_SAP_LORAWAN_IDs.h"
50 
51 #include "WiMOD_SAP_LORAWAN_IDs_EU868.h" /* Europe */
52 #include "WiMOD_SAP_LORAWAN_IDs_RU868.h" /* Russia */
53 #include "WiMOD_SAP_LORAWAN_IDs_IN865.h" /* India */
54 #include "WiMOD_SAP_LORAWAN_IDs_AS923.h" /* Asia/Pacific */
55 #include "WiMOD_SAP_LORAWAN_IDs_IL915.h" /* Israel */
56 #include "WiMOD_SAP_LORAWAN_IDs_US915.h" /* US */
57 #include "WIMOD_SAP_LORAWAN_IDs_AU915.h" /* Australia */
58 
64 {
65  ProLink_LoRaWAN_FreqBand_EU_868 = LORAWAN_BAND_EU_868,
67  ProLink_LoRaWAN_FreqBand_IN_865 = LORAWAN_BAND_IN_865,
69  ProLink_LoRaWAN_FreqBand_US_915 = LORAWAN_BAND_US_915,
71  ProLink_LoRaWAN_FreqBand_AU_915 = LORAWAN_BAND_AU_915,
73  ProLink_LoRaWAN_FreqBand_AS_923_1 = LORAWAN_BAND_AS_923_1,
74  ProLink_LoRaWAN_FreqBand_AS_923_2 = LORAWAN_BAND_AS_923_2,
75  ProLink_LoRaWAN_FreqBand_AS_923_3 = LORAWAN_BAND_AS_923_3,
77  ProLink_LoRaWAN_FreqBand_RU_868 = LORAWAN_BAND_EU_868,
80  ProLink_LoRaWAN_FreqBand_EU_868_RX2_SF9 = LORAWAN_BAND_EU_868_RX2_SF9,
81  ProLink_LoRaWAN_FreqBand_IN_865_RX2_SF8 = LORAWAN_BAND_IN_865_RX2_SF8,
83  ProLink_LoRaWAN_FreqBand_WW2G4 = GLOBALLINK24_BAND_WW_2G4,
84  ProLink_LoRaWAN_FreqBand_WW2G4_RX2 = GLOBALLINK24_BAND_WW_2G4_RX2,
86 
87 
92 {
93  UINT8 Port;
94  UINT8 Length;
95  UINT8 Payload[WiMODLORAWAN_APP_PAYLOAD_LEN];
96  // only for RX
99 
100 
105 {
106 // UINT8 Status;
109 
110 
115 {
116  UINT8 Status;
117  UINT32 GpsTime;
119 
120 
122 {
123  UINT8 MulticastIndex;
124  UINT32 DeviceAddress;
126  /* only for GET-Operations */
129  /* only for SET-Operations */
130  UINT8 NwkSKey[WiMODLORAWAN_NWK_SESSION_KEY_LEN];
131  UINT8 AppSKey[WiMODLORAWAN_APP_SESSION_KEY_LEN];
133 
134 
135 
140 {
141  // only for RX
142  UINT8 StatusFormat;
144  UINT32 DeviceAddress;
146  UINT8 LoRaWANPort;
148  UINT8 AppPayload[WiMODLORAWAN_APP_PAYLOAD_LEN]; ;
149  UINT8 Length;
150 
151  // optional - see StatusFormat code
152  UINT8 ChannelIndex;
154  INT8 RSSI;
155  INT8 SNR;
156  UINT8 RxSlot;
161 
162 
163 /* bit fields for Multicast error indications */
164 #define PROLINK_MCAST_ERR_WRONG_MTYPE (1 << 0)
165 #define PROLINK_MCAST_ERR_WRONG_DEV_ADR (1 << 1)
166 #define PROLINK_MCAST_ERR_WRONG_MIC (1 << 2)
167 #define PROLINK_MCAST_ERR_UNEXPTECTED_FCNT (1 << 3)
168 #define PROLINK_MCAST_ERR_RX_MAC_CMD (1 << 4)
169 #define PROLINK_MCAST_ERR_WRONG_DOWNLINK (1 << 5)
170 #define PROLINK_MCAST_ERR_MCAST_DOWNLINK_ERR (1 << 6)
171 
172 
177 {
178  // only for RX
179  UINT8 StatusFormat;
181  UINT8 ErrorCode;
183  UINT32 DeviceAddress;
186 
187 
192 {
194  UINT8 TXPowerLevel;
195  UINT8 Options;
198  UINT8 BandIndex;
201  // US915/AU915 Firmware only
202  UINT8 SubBandMask1;
203  UINT8 SubBandMask2;
205  // optional for SetRadioStack cmd
209 
210 
211 
212 #endif /* ARDUINO_SAP_WIMOD_SAP_LORAWAN_PROLINK_IDS_H_ */
TWiMODLORAWAN_DevTimeAnsInfo
info data structure for LoRa device time request MAC command
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:114
TWiMODLORAWAN_McastData::LoRaWANPort
UINT8 LoRaWANPort
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:146
TWiMODLORAWAN_McastNoData
Structure containing a MultiCast Data.
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:176
TWiMODLORAWAN_McastConfig::NwkSKey
UINT8 NwkSKey[WiMODLORAWAN_NWK_SESSION_KEY_LEN]
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:130
TWiMODLORAWAN_McastData
Structure containing a MultiCast Data.
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:139
TWiMODLORAWAN_McastConfig::AppSKey
UINT8 AppSKey[WiMODLORAWAN_APP_SESSION_KEY_LEN]
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:131
TWiMODLORAWAN_McastData::RxSlot
UINT8 RxSlot
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:156
WiMOD_SAP_LORAWAN_IDs.h
TWiMODLORAWAN_McastData::DeviceAddress
UINT32 DeviceAddress
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:144
TWiMODLORAWAN_McastData::RSSI
INT8 RSSI
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:154
WiMOD_SAP_LORAWAN_IDs_AS923.h
WiMOD_SAP_LORAWAN_IDs_IL915.h
TWiMODLORAWAN_McastData::StatusFormat
UINT8 StatusFormat
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:142
TWiMODLORAWAN_McastData::DataRateIndex
UINT8 DataRateIndex
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:153
TWiMODLORAWAN_McastData::AppPayload
UINT8 AppPayload[WiMODLORAWAN_APP_PAYLOAD_LEN]
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:148
TWiMODLORAWAN_DevTimeAnsInfo::GpsTime
UINT32 GpsTime
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:117
TWiMODLORAWAN_McastNoData::StatusFormat
UINT8 StatusFormat
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:179
TWiMODLORAWAN_McastNoData::DeviceAddress
UINT32 DeviceAddress
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:183
TWiMODLORAWAN_DevTimeReqInfo
info data structure for LoRa device time request MAC command
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:104
TWiMODLORAWAN_McastData::SNR
INT8 SNR
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:155
WiMOD_SAP_LORAWAN_IDs_EU868.h
WiMOD_SAP_LORAWAN_IDs_IN865.h
WiMOD_SAP_LORAWAN_IDs_RU868.h
TWiMODLORAWAN_McastConfig
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:121
TWiMODLORAWAN_McastNoData::ErrorCode
UINT8 ErrorCode
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:181
TWiMODLORAWAN_McastData::ChannelIndex
UINT8 ChannelIndex
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:152
TWiMODLORAWAN_McastConfig::MulticastStatus
UINT8 MulticastStatus
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:127
WiMOD_SAP_LORAWAN_IDs_US915.h
TWiMODLORAWAN_McastData::OptionalInfoAvaiable
bool OptionalInfoAvaiable
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:157
TWiMODLORAWAN_DevTimeReqInfo::ChannelBlockTime
UINT32 ChannelBlockTime
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:107
TWiMODLORAWAN_McastConfig::DeviceAddress
UINT32 DeviceAddress
Definition: WiMOD_SAP_LORAWAN_ProLink_IDs.h:124