LMIC transmit example for NAmote-72 with GPS

Dependencies:   lib_gps lib_mpl3115a2 lmic_MOTE_L152RC mbed

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers config.h Source File

config.h

00001 // Organizationally Unique Identifier
00002 #define OUI         0x00, 0x00, 0x00
00003 
00004 /* DEVEUI = {[OUI] [5 bytes of Unique ID]}
00005 if last 4 bytes of DEVEUI equals 0, then the firmware will assign a unique ID
00006 */
00007 #define DEVEUI      OUI, 0x00, 0x00, 0x00, 0x00, 0x00
00008 
00009 #define APPEUI      0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
00010 #define DEVKEY      0x00, 0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77, 0x88, 0x99, 0xAA, 0xBB, 0xCC, 0xDD, 0xEE, 0xFF
00011 
00012 // Time between transmissions in msec
00013 #define MS_DELAY_NEXT_TX        3000
00014 
00015 // Length of payload (Must be within the Maximum Length as defined in 7.2.6 of LoRaWAN 1.0 Specification
00016 #define PAYLOAD_LENGTH          11  
00017 
00018 /* DR_SF10 = 0, DR_SF9 = 1, DR_SF8 = 2, DR_SF7 = 3, DR_SF8C = 4  [as defined in Table 18 of Section 7 of LoRaWAN 1.0 Specification */
00019 #define FIXED_DR                DR_SF10 
00020 
00021 /* US 915MHz ISM Band */
00022 #define CFG_us915
00023 
00024 /* SX1272 chip */
00025 #define CFG_sx1272_radio
00026 
00027 // 0-7 to select block of 8 channels (Block A = 0, Block B = 1 ... Block H = 7). Comment this line to enable all 64 channels
00028 #define CHNL_HYBRID     0       
00029 
00030 // Set Tx Power in dBm (Max = 30dBm for frequency hopping over 50channels; 26dBm with Digital Modulation; 21dBm in Hybrid mode)
00031 #define FIXED_TX_POWER  20