| Electronic Components Datasheet Search |
|
7906 Datasheet(PDF) 75 Page - Renesas Technology Corp |
|
|
|||||||||||||||||||||||||||||
7906 Datasheet(HTML) 75 Page - Renesas Technology Corp |
|
75 / 531 page ![]() INPUT/OUTPUT PINS 7906 Group User’s Manual Rev.2.0 5-4 5.2 Programmable I/O ports 5.2.2 Port register Data is input from or output to the external by writing/reading data to/from a port register. A port register consists of a port latch which holds the output data and a circuit which reads the pin state. One bit of the port register corresponds to one pin of the microcomputer. (This is the one-to-one relationship.) Figure 5.2.3 shows the structure of the port Pi (i = 1, 2, 5 to 7) register. q When outputting data from programmable I/O port which has been set to output mode ➀ By writing data to the corresponding bit of the port register, the data is written into the port latch. ➁ The data is output from the pin according to the contents of the port latch. By reading the port register of a port which has been set to the output mode, the contents of the port latch is read out, instead of the pin state. Accordingly, the output data can be correctly read out without being affected by an external load, etc. (See “Figures 5.2.4 and 5.2.5.”) q When inputting data from programmable I/O port which has been set to input mode ➀ A pin which has been set to the input mode enters the floating state. ➁ By reading the corresponding bit of the port register, the data which has been input from the pin can be read out. By writing data to a port register of a programmable I/O port which has been set to the input mode, the data is written only into the port latch and is not output to the external (Note). This pin remains floating state. Note: When executing a read-modify-write instruction to a port register of a programmable I/O port which has been set to the input mode, the instruction will be executed to the data which has been input from the pin and the result will be written into the port register. Fig. 5.2.3 Structure of port Pi (i = 1, 2, 5 to 7) register RW RW RW RW RW RW RW RW Bit name Bit 0 1 2 3 4 5 6 7 Port Pi register (i = 1, 2, 5 to 7) (Addresses 316, 616, B16, E16, F16) Funtion At reset R/W Port pin Pi0 Port pin Pi1 Port pin Pi2 Port pin Pi3 Port pin Pi4 Port pin Pi5 Port pin Pi6 Port pin Pi7 Undefined Undefined Undefined Undefined Undefined Undefined Undefined Undefined b7 b6 b5 b4 b3 b2 b1 b0 Notes 1: Nothing is assigned for bits 0 to 4 of the port P5 register. These bits are undefined at reading. 2: Nothing is assigned for bits 6 and 7 of the port P6 register. These bits are undefined at reading. 3: Nothing is assigned for bits 5 to 7 of the port P7 register. These bits are undefined at reading. Data is input from or output to a pin by reading from or writing to the corresponding bit. 0 : “L” level 1 : “H” level |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |