Port Registers


1. Port Open-Drain Registers
 : The port open-drain register(PODR), indicates a normal or wired-OR configuration of the port pins.
 : Determines whethehr the corresponding pin is actively driven as an output or is an open-drain driver.
'0' -> The I/O pin is actively driven as an output.
'1' -> The I/O pin is an open-drain driver. As an output, the pin is driven active-low, otherwise it is three-stated.

2. Port Data Register (PDATx)

3. Port Data Direction Register (PDIRx)
 : Direction. Indicates whether a pin is used as an input or an output.
'0' -> The corresponding pin is an input or is bidirectional
'1' -> The corresponding pin is an output.

4. Port Pin Assignment Register (PPAR)
 : Dedicated enable. Indicates whether a pin is a general-purpose I/O or a dedicated peripheral pin.
'0' -> General-purpose I/O. The peripheral functions of the pin are not used.
'1' -> Dedicated peripheral function.

5. Port Special Options Register (PSORx)
 : Special-option. Determines whether a pin configured for a dedicated function uses option 1 or option 2.
'0' -> Dedicated peripheral function. Option 1
'1' -> Dedicated peripheral function. Option 2




+ Recent posts