LoRa on Multitech with Semtech mote

Dependencies:   LoRaWAN-lib SX1272Lib lib_gps lib_mma8451q lib_mpl3115a2 mbed

Fork of LoRaWAN-NAMote72-Application-Demo_Multitech by Nagaraj Krishnamurthy

Committer:
nagarajkmurthy
Date:
Wed Jan 18 12:55:33 2017 +0000
Revision:
18:168062d45093
Parent:
9:617844f7fdb1
LoRa on Multitech using Semtech mote

Who changed what in which revision?

UserRevisionLine numberNew contents of line
ubhat 0:69f2e28d12c1 1 /*
ubhat 0:69f2e28d12c1 2 / _____) _ | |
ubhat 0:69f2e28d12c1 3 ( (____ _____ ____ _| |_ _____ ____| |__
ubhat 0:69f2e28d12c1 4 \____ \| ___ | (_ _) ___ |/ ___) _ \
ubhat 0:69f2e28d12c1 5 _____) ) ____| | | || |_| ____( (___| | | |
ubhat 0:69f2e28d12c1 6 (______/|_____)_|_|_| \__)_____)\____)_| |_|
ubhat 0:69f2e28d12c1 7 (C)2015 Semtech
ubhat 0:69f2e28d12c1 8
ubhat 0:69f2e28d12c1 9 Description: Extern declaration of parameters defined in main.cpp
ubhat 0:69f2e28d12c1 10
ubhat 0:69f2e28d12c1 11 License: Revised BSD License, see LICENSE.TXT file include in the project
ubhat 0:69f2e28d12c1 12
ubhat 0:69f2e28d12c1 13 Maintainer: Uttam Bhat
ubhat 0:69f2e28d12c1 14 */
ubhat 0:69f2e28d12c1 15 #ifndef __COMMON_H__
ubhat 0:69f2e28d12c1 16 #define __COMMON_H__
ubhat 0:69f2e28d12c1 17
ubhat 0:69f2e28d12c1 18 #include "Comissioning.h"
ubhat 0:69f2e28d12c1 19 #include "board.h"
ubhat 0:69f2e28d12c1 20
ubhat 0:69f2e28d12c1 21 /*!
ubhat 0:69f2e28d12c1 22 * User application data buffer size
ubhat 0:69f2e28d12c1 23 */
ubhat 0:69f2e28d12c1 24 #define LORAWAN_APP_DATA_MAX_SIZE 64
ubhat 0:69f2e28d12c1 25
ubhat 9:617844f7fdb1 26 /*!
ubhat 9:617844f7fdb1 27 * Current network ID
ubhat 9:617844f7fdb1 28 */
ubhat 9:617844f7fdb1 29 #define LORAWAN_NETWORK_ID ( uint32_t )0
ubhat 9:617844f7fdb1 30
ubhat 0:69f2e28d12c1 31
ubhat 0:69f2e28d12c1 32 #if( OVER_THE_AIR_ACTIVATION != 0 )
ubhat 0:69f2e28d12c1 33 /*!
ubhat 0:69f2e28d12c1 34 * Over the Air Activation
ubhat 0:69f2e28d12c1 35 */
ubhat 0:69f2e28d12c1 36
ubhat 0:69f2e28d12c1 37 extern uint8_t DevEui[];
ubhat 0:69f2e28d12c1 38 extern uint8_t AppEui[];
ubhat 0:69f2e28d12c1 39 extern uint8_t AppKey[];
ubhat 0:69f2e28d12c1 40
ubhat 0:69f2e28d12c1 41 #else
ubhat 0:69f2e28d12c1 42 /*!
ubhat 0:69f2e28d12c1 43 * Activation by Personalization
ubhat 0:69f2e28d12c1 44 */
ubhat 0:69f2e28d12c1 45
ubhat 0:69f2e28d12c1 46 extern uint8_t NwkSKey[];
ubhat 0:69f2e28d12c1 47 extern uint8_t AppSKey[];
ubhat 0:69f2e28d12c1 48 extern uint32_t DevAddr;
ubhat 0:69f2e28d12c1 49
ubhat 0:69f2e28d12c1 50 #endif
ubhat 0:69f2e28d12c1 51
ubhat 0:69f2e28d12c1 52 extern uint8_t AppData[LORAWAN_APP_DATA_MAX_SIZE]; // User application data size
ubhat 0:69f2e28d12c1 53
ubhat 0:69f2e28d12c1 54 extern uint8_t AppPort; // Application port
ubhat 0:69f2e28d12c1 55
ubhat 0:69f2e28d12c1 56 extern uint8_t AppDataSize; // Application size
ubhat 0:69f2e28d12c1 57
ubhat 0:69f2e28d12c1 58 extern uint8_t IsTxConfirmed; // Indicates if the node is sending confirmed or unconfirmed messages
ubhat 0:69f2e28d12c1 59
ubhat 5:6ffeac53b7cb 60 extern bool IsTxIntUpdate; // Indicates if a new transmit interrupt can be set
ubhat 5:6ffeac53b7cb 61
ubhat 0:69f2e28d12c1 62 extern bool NextTx; // Indicates if a new packet can be sent
ubhat 0:69f2e28d12c1 63
ubhat 0:69f2e28d12c1 64 extern bool IsNetworkJoinedStatusUpdate; // Indicates if the MAC layer network join status has changed.
ubhat 0:69f2e28d12c1 65
ubhat 0:69f2e28d12c1 66 extern bool IsTxUpdate; // Indicates if the message sent
ubhat 0:69f2e28d12c1 67
ubhat 0:69f2e28d12c1 68 extern bool IsRxUpdate; // Indicates if the message received in the RX window.
ubhat 0:69f2e28d12c1 69
ubhat 0:69f2e28d12c1 70 extern TimerEvent_t TxNextPacketTimer; // Timer to handle the application data transmission duty cycle
ubhat 0:69f2e28d12c1 71
ubhat 0:69f2e28d12c1 72 #endif // __COMMON_H__