Texas Instruments Development Kit for TM4C129x,Tiva™ ARM® Cortex™ -M4 Microcontroller DK-TM4C129X DK-TM4C129X Datenbogen
Produktcode
DK-TM4C129X
8.
Program each pad in the port to have either pull-up, pull-down, or open drain functionality through
the GPIOPUR, GPIOPDR, GPIOODR register. Slew rate may also be programmed, if needed,
through the GPIOSLR register.
the GPIOPUR, GPIOPDR, GPIOODR register. Slew rate may also be programmed, if needed,
through the GPIOSLR register.
9.
To enable GPIO pins as digital I/Os, set the appropriate
DEN
bit in the GPIODEN register. To
enable GPIO pins to their analog function (if available), set the
GPIOAMSEL
bit in the
GPIOAMSEL register.
10. Program the GPIOIS, GPIOIBE, GPIOBE, GPIOEV, and GPIOIM registers to configure the
type, event, and mask of the interrupts for each port.
11. Optionally, software can lock the configurations of the NMI and JTAG/SWD pins on the GPIO
port pins, by setting the
LOCK
bits in the GPIOLOCK register.
When the internal POR signal is asserted and until otherwise configured, all GPIO pins are configured
to be undriven (tristate): GPIOAFSEL=0, GPIODEN=0, GPIOPDR=0, and GPIOPUR=0Table
10-4 on page 785 shows all possible configurations of the GPIO pads and the control register settings
required to achieve them. Table 10-5 on page 786 shows how a rising edge interrupt is configured
for pin 2 of a GPIO port.
to be undriven (tristate): GPIOAFSEL=0, GPIODEN=0, GPIOPDR=0, and GPIOPUR=0Table
10-4 on page 785 shows all possible configurations of the GPIO pads and the control register settings
required to achieve them. Table 10-5 on page 786 shows how a rising edge interrupt is configured
for pin 2 of a GPIO port.
Table 10-4. GPIO Pad Configuration Examples
GPIO Register Bit Value
a
Configuration
SLR
DR12R
DR8R
DR4R
DR2R
PDR
PUR
DEN
ODR
DIR
AFSEL
X
X
X
X
X
?
?
1
0
0
0
Digital Input
(GPIO)
(GPIO)
?
?
?
?
?
?
?
1
0
1
0
Digital Output
(GPIO)
(GPIO)
?
?
?
?
?
X
X
1
1
1
0
Open Drain Output
(GPIO)
(GPIO)
?
?
?
?
?
X
X
1
1
X
1
Open Drain
Input/Output
(
Input/Output
(
I2CSDA
)
X
X
X
X
X
?
?
1
0
X
1
Digital Input (Timer
CCP)
CCP)
X
X
X
X
X
?
?
1
0
X
1
Digital Input (QEI)
?
?
?
?
?
?
?
1
0
X
1
Digital Output
(PWM)
(PWM)
?
?
?
?
?
?
?
1
0
X
1
Digital Output
(Timer PWM)
(Timer PWM)
?
?
?
?
?
?
?
1
0
X
1
Digital Input/Output
(SSI)
(SSI)
?
?
?
?
?
?
?
1
0
X
1
Digital Input/Output
(UART)
(UART)
X
X
X
X
X
0
0
0
0
0
0
Analog Input
(Comparator)
(Comparator)
?
?
?
?
?
?
?
1
0
X
1
Digital Output
(Comparator)
(Comparator)
a. X=Ignored (don’t care bit)
?=Can be either 0 or 1, depending on the configuration
785
December 13, 2013
Texas Instruments-Advance Information
Tiva
™
TM4C129XNCZAD Microcontroller