63 #include <inc/hw_types.h>
64 #include <inc/hw_memmap.h>
65 #include <inc/hw_gpio.h>
73 #ifdef DRIVERLIB_DEBUG
74 #include <inc/hw_fcfg1.h>
78 dioNumberLegal( uint32_t dioNumber )
90 return (( dioNumber > 0 ) && ( dioNumber <= ioCount ));
92 return ( dioNumber < ioCount );
102 #define GPIO_DIO_0_MASK 0x00000001 // GPIO DIO 0 mask
103 #define GPIO_DIO_1_MASK 0x00000002 // GPIO DIO 1 mask
104 #define GPIO_DIO_2_MASK 0x00000004 // GPIO DIO 2 mask
105 #define GPIO_DIO_3_MASK 0x00000008 // GPIO DIO 3 mask
106 #define GPIO_DIO_4_MASK 0x00000010 // GPIO DIO 4 mask
107 #define GPIO_DIO_5_MASK 0x00000020 // GPIO DIO 5 mask
108 #define GPIO_DIO_6_MASK 0x00000040 // GPIO DIO 6 mask
109 #define GPIO_DIO_7_MASK 0x00000080 // GPIO DIO 7 mask
110 #define GPIO_DIO_8_MASK 0x00000100 // GPIO DIO 8 mask
111 #define GPIO_DIO_9_MASK 0x00000200 // GPIO DIO 9 mask
112 #define GPIO_DIO_10_MASK 0x00000400 // GPIO DIO 10 mask
113 #define GPIO_DIO_11_MASK 0x00000800 // GPIO DIO 11 mask
114 #define GPIO_DIO_12_MASK 0x00001000 // GPIO DIO 12 mask
115 #define GPIO_DIO_13_MASK 0x00002000 // GPIO DIO 13 mask
116 #define GPIO_DIO_14_MASK 0x00004000 // GPIO DIO 14 mask
117 #define GPIO_DIO_15_MASK 0x00008000 // GPIO DIO 15 mask
118 #define GPIO_DIO_16_MASK 0x00010000 // GPIO DIO 16 mask
119 #define GPIO_DIO_17_MASK 0x00020000 // GPIO DIO 17 mask
120 #define GPIO_DIO_18_MASK 0x00040000 // GPIO DIO 18 mask
121 #define GPIO_DIO_19_MASK 0x00080000 // GPIO DIO 19 mask
122 #define GPIO_DIO_20_MASK 0x00100000 // GPIO DIO 20 mask
123 #define GPIO_DIO_21_MASK 0x00200000 // GPIO DIO 21 mask
124 #define GPIO_DIO_22_MASK 0x00400000 // GPIO DIO 22 mask
125 #define GPIO_DIO_23_MASK 0x00800000 // GPIO DIO 23 mask
126 #define GPIO_DIO_24_MASK 0x01000000 // GPIO DIO 24 mask
127 #define GPIO_DIO_25_MASK 0x02000000 // GPIO DIO 25 mask
128 #define GPIO_DIO_26_MASK 0x04000000 // GPIO DIO 26 mask
129 #define GPIO_DIO_27_MASK 0x08000000 // GPIO DIO 27 mask
130 #define GPIO_DIO_28_MASK 0x10000000 // GPIO DIO 28 mask
131 #define GPIO_DIO_29_MASK 0x20000000 // GPIO DIO 29 mask
132 #define GPIO_DIO_30_MASK 0x40000000 // GPIO DIO 30 mask
133 #define GPIO_DIO_31_MASK 0x80000000 // GPIO DIO 31 mask
134 #define GPIO_DIO_ALL_MASK 0xFFFFFFFF // GPIO all DIOs mask
143 #define GPIO_OUTPUT_DISABLE 0x00000000 // DIO output is disabled
144 #define GPIO_OUTPUT_ENABLE 0x00000001 // DIO output is enabled
163 __STATIC_INLINE uint32_t
169 ASSERT( dioNumberLegal( dioNumber ));
197 __STATIC_INLINE uint32_t
231 ASSERT( dioNumberLegal( dioNumber ));
232 ASSERT(( value == 0 ) || ( value == 1 ));
271 ( bitVectoredValue & dioMask );
291 ASSERT( dioNumberLegal( dioNumber ));
345 ASSERT( dioNumberLegal( dioNumber ));
399 ASSERT( dioNumberLegal( dioNumber ));
452 __STATIC_INLINE uint32_t
458 ASSERT( dioNumberLegal( dioNumber ));
486 __STATIC_INLINE uint32_t
523 ASSERT( dioNumberLegal( dioNumber ));
567 ( bitVectoredOutputEnable & dioMask );
583 __STATIC_INLINE uint32_t
589 ASSERT( dioNumberLegal( dioNumber ));
618 __STATIC_INLINE uint32_t
649 ASSERT( dioNumberLegal( dioNumber ));
static uint32_t GPIO_getEventDio(uint32_t dioNumber)
Gets the event status of a specific DIO.
static void GPIO_setOutputEnableMultiDio(uint32_t dioMask, uint32_t bitVectoredOutputEnable)
Configures the output enable setting for all specified DIOs.
static uint32_t GPIO_getOutputEnableDio(uint32_t dioNumber)
Gets the output enable status of a specific DIO.
static void GPIO_clearEventDio(uint32_t dioNumber)
Clears the IO event status of a specific DIO.
#define GPIO_DIO_ALL_MASK
#define GPIO_OUTPUT_ENABLE
static void GPIO_clearEventMultiDio(uint32_t dioMask)
Clears the IO event status on the specified DIOs.
static void GPIO_clearMultiDio(uint32_t dioMask)
Clears the specified DIOs to 0 (low).
static void GPIO_clearDio(uint32_t dioNumber)
Clears a specific DIO to 0 (low).
static void GPIO_writeDio(uint32_t dioNumber, uint32_t value)
Writes a value to a specific DIO.
static void GPIO_setMultiDio(uint32_t dioMask)
Sets the specified DIOs to 1 (high).
static void GPIO_toggleMultiDio(uint32_t dioMask)
Toggles the specified DIOs.
static uint32_t GPIO_getOutputEnableMultiDio(uint32_t dioMask)
Gets the output enable setting of the specified DIOs.
static void GPIO_setDio(uint32_t dioNumber)
Sets a specific DIO to 1 (high).
static bool ChipInfo_ChipFamilyIsCC13xx(void)
Returns true if this chip is member of the CC13xx family.
static void GPIO_toggleDio(uint32_t dioNumber)
Toggles a specific DIO.
static uint32_t GPIO_readDio(uint32_t dioNumber)
Reads a specific DIO.
#define GPIO_OUTPUT_DISABLE
static uint32_t GPIO_readMultiDio(uint32_t dioMask)
Reads the input value for the specified DIOs.
static uint32_t GPIO_getEventMultiDio(uint32_t dioMask)
Gets the event status of the specified DIOs.
static void GPIO_writeMultiDio(uint32_t dioMask, uint32_t bitVectoredValue)
Writes masked data to the specified DIOs.
static void GPIO_setOutputEnableDio(uint32_t dioNumber, uint32_t outputEnableValue)
Sets output enable of a specific DIO.