Texas Instruments TMS320C645x manual Direction Register DIR Field Descriptions

Page 17

Registers

5.2Direction Register (DIR)

The GPIO direction register (DIR) determines if a given GPIO pin is an input or an output. The GPDIR is shown in Figure 4 and described in Table 4. By default, all the GPIO pins are configured as input pins.

When GPIO pins are configured as output pins, the GPIO output buffer drives the GPIO pin. If it is necessary to place the GPIO output buffer in a high-impedance state, the GPIO pin must be configured as an input pin (DIRn = 0). At reset, GPIO pins default to input mode.

Figure 4.

Direction Register (DIR)

 

 

 

 

 

 

31

 

 

 

 

 

 

 

 

16

 

 

 

 

 

 

 

 

 

 

 

 

 

Reserved

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

R-0

 

 

 

 

15

14

13

 

12

 

11

10

9

8

 

 

 

 

 

 

 

 

 

 

DIR15

DIR14

DIR13

 

DIR12

 

DIR11

DIR10

DIR9

DIR8

 

 

 

 

 

 

 

 

 

 

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

7

6

5

 

4

 

3

2

1

0

 

 

 

 

 

 

 

 

DIR7

DIR6

DIR5

 

DIR4

 

DIR3

DIR2

DIR1

DIR0

 

 

 

 

 

 

 

 

 

 

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

R/W-1

Legend: R = Read only; R/W = Read/Write; -n= value after reset

 

 

 

 

Table 4.

Direction Register (DIR) Field Descriptions

 

 

 

 

Bit

Field

Value

Description

 

 

 

 

31−16

Reserved

0

Reserved. The reserved bit location is always read as 0. A value written to

 

 

 

this field has no effect.

 

 

 

 

15−0

DIRn

 

Controls the direction of the GPn pin.

 

 

0

GPn pin configured as output pin

 

 

1

GPn pin configured as input pin

 

 

 

 

SPRU724

General-Purpose Input/Output (GPIO)

17

Image 17
Contents Literature Number SPRU724 December Important Notice About This Manual Read This FirstTrademarks Contents Figures Tables This page is intentionally left blank Overview General-PurposeTMS320C645x DSP Block Diagram Gpio Peripheral Block Diagram Gpio Function Interrupt and Event Generation Gpio Interrupt and Edma Event Configuration Options Emulation Halt Operation Gpio Registers RegistersInterrupt Per-Bank Enable Register Binten Interrupt Per-Bank Enable Register BintenDirection Register DIR Field Descriptions Direction Register DIRDirection Register DIR Output Data Register Outdata Field Descriptions Output Data Register OutdataSet Data Register Setdata Field Descriptions Set Data Register SetdataClear Data Register Clrdata Field Descriptions Clear Data Register ClrdataClear Data Register Clrdata Input Data Register Indata Field Descriptions Input Data Register IndataSet Rising Edge Interrupt Register Setristrig Set Rising Edge Interrupt Register SetristrigClear Rising Edge Interrupt Register Clrristrig Clear Rising Edge Interrupt Register ClrristrigSet Falling Edge Interrupt Register Setfaltrig Set Falling Edge Interrupt Register SetfaltrigClear Falling Edge Interrupt Register Clrfaltrig Clear Falling Edge Interrupt Register ClrfaltrigThis page is intentionally left blank Index
Related manuals
Manual 218 pages 2.08 Kb