Based on SX1276Lib. Simplified and targeted for Modtronix inAir modules. All pins can now be specified to use interrupts or general purpose I/O pins.

Committer:
modtronix
Date:
Sun Aug 30 09:39:25 2015 +1000
Revision:
1:64a9c4a03244
Child:
7:4d242a6ca693
Initial version

Who changed what in which revision?

UserRevisionLine numberNew contents of line
modtronix 1:64a9c4a03244 1 /**
modtronix 1:64a9c4a03244 2 * File: inair_default_defines.h
modtronix 1:64a9c4a03244 3 *
modtronix 1:64a9c4a03244 4 * Author: Modtronix Engineering - www.modtronix.com
modtronix 1:64a9c4a03244 5 *
modtronix 1:64a9c4a03244 6 * Description:
modtronix 1:64a9c4a03244 7 *
modtronix 1:64a9c4a03244 8 * Software License Agreement:
modtronix 1:64a9c4a03244 9 * This software has been written or modified by Modtronix Engineering. The code
modtronix 1:64a9c4a03244 10 * may be modified and can be used free of charge for commercial and non commercial
modtronix 1:64a9c4a03244 11 * applications. If this is modified software, any license conditions from original
modtronix 1:64a9c4a03244 12 * software also apply. Any redistribution must include reference to 'Modtronix
modtronix 1:64a9c4a03244 13 * Engineering' and web link(www.modtronix.com) in the file header.
modtronix 1:64a9c4a03244 14 *
modtronix 1:64a9c4a03244 15 * THIS SOFTWARE IS PROVIDED IN AN 'AS IS' CONDITION. NO WARRANTIES, WHETHER EXPRESS,
modtronix 1:64a9c4a03244 16 * IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
modtronix 1:64a9c4a03244 17 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. THE
modtronix 1:64a9c4a03244 18 * COMPANY SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL OR
modtronix 1:64a9c4a03244 19 * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
modtronix 1:64a9c4a03244 20 */
modtronix 1:64a9c4a03244 21 #ifndef MODTRONIX_INAIR_INAIR_DEFAULT_CONFIG_H_
modtronix 1:64a9c4a03244 22 #define MODTRONIX_INAIR_INAIR_DEFAULT_CONFIG_H_
modtronix 1:64a9c4a03244 23
modtronix 1:64a9c4a03244 24 //This file is used to configure the "modtronix_inAir" library. The recommended way to change the defines
modtronix 1:64a9c4a03244 25 //in this file is to create a copy of this file in your main project folder. Name it "inair_config.h".
modtronix 1:64a9c4a03244 26 //To use the defines from this new file, comment the following line. This makes it easier when
modtronix 1:64a9c4a03244 27 //upgrading to newer version of this library, seeing that this file with modifications will be
modtronix 1:64a9c4a03244 28 //overwritten. After upgrade, all that has to be done is to uncomment following line again.
modtronix 1:64a9c4a03244 29 #define USE_CUSTOM_INAIR_CONFIG //Uncomment this line after creating "inair_config.h" in project
modtronix 1:64a9c4a03244 30
modtronix 1:64a9c4a03244 31 #if defined(USE_CUSTOM_INAIR_CONFIG)
modtronix 1:64a9c4a03244 32 #include "inair_config.h"
modtronix 1:64a9c4a03244 33 #else
modtronix 1:64a9c4a03244 34 //To use custom config, uncomment "USE_CUSTOM_INAIR_CONFIG" define above, and create "inair_config.h" file
modtronix 1:64a9c4a03244 35 //#warning "Using default configuration for 'modtronix_inAir' library!"
modtronix 1:64a9c4a03244 36 #endif
modtronix 1:64a9c4a03244 37
modtronix 1:64a9c4a03244 38 // Copy from here to custom inair_defines.h file //////////////////////////////
modtronix 1:64a9c4a03244 39
modtronix 1:64a9c4a03244 40 //When selecting "Non Interrupt" based DIO0, following times were measured:
modtronix 1:64a9c4a03244 41 // - Measuring time DIO0 pin stays high, indicates how long code takes to get to "Clear Irq" in OnDio0Irq(). DIO0 pin
modtronix 1:64a9c4a03244 42 // stays high for about 20-40uS with interrupts disabled. Is about 18uS when interrupts enabled.
modtronix 1:64a9c4a03244 43 #if !defined(INAIR_DIO0_IS_INTERRUPT)
modtronix 1:64a9c4a03244 44 #define INAIR_DIO0_IS_INTERRUPT 0
modtronix 1:64a9c4a03244 45 #endif
modtronix 1:64a9c4a03244 46
modtronix 1:64a9c4a03244 47 #if !defined(INAIR_DIO1_IS_INTERRUPT)
modtronix 1:64a9c4a03244 48 #define INAIR_DIO1_IS_INTERRUPT 0
modtronix 1:64a9c4a03244 49 #endif
modtronix 1:64a9c4a03244 50
modtronix 1:64a9c4a03244 51 #if !defined(INAIR_DIO2_IS_INTERRUPT)
modtronix 1:64a9c4a03244 52 #define INAIR_DIO2_IS_INTERRUPT 0
modtronix 1:64a9c4a03244 53 #endif
modtronix 1:64a9c4a03244 54
modtronix 1:64a9c4a03244 55 #if !defined(INAIR_DIO3_IS_INTERRUPT)
modtronix 1:64a9c4a03244 56 #define INAIR_DIO3_IS_INTERRUPT 0
modtronix 1:64a9c4a03244 57 #endif
modtronix 1:64a9c4a03244 58
modtronix 1:64a9c4a03244 59
modtronix 1:64a9c4a03244 60 // End of contents to copy to custom inair_defines.h file /////////////////////
modtronix 1:64a9c4a03244 61
modtronix 1:64a9c4a03244 62 #endif /* MODTRONIX_INAIR_INAIR_DEFAULT_CONFIG_H_ */