4. PORT SFRs
• Each port has three (3) SFRs associated with it.
• PORTx
• TRISx (TRIState)
• LATx (LATch)
5. TRIS register role
• This makes a given port an input or output port.
• Output write 0s to TRISx (0 stands for Out)
• Input write 1s to TRISx (1 stands for In)
• Unless we activate TRISx bits (set to 0s), the data will not go from port
register to the pins of PIC.
• Ex: