| Electronic Components Datasheet Search |
|
STC12LE5616AD Datasheet(PDF) 365 Page - STCmicro Technology Co,.Ltd |
|
|
|||||||||||||||||||||||||||||
STC12LE5616AD Datasheet(HTML) 365 Page - STCmicro Technology Co,.Ltd |
|
365 / 377 page ![]() Appendix E: Using Serial port expand I/O interface STC12C5620AD series MCU serial port mode0 can be used for expand IO if UART is free in your application. UART Mode0 is a synchronous shift register, the baudrate is fixed at fosc/12, RXD pin (P3.0) is the data I/O port, and TXD pin (P3.1) is clock output port, data width is 8 bits, always sent / received the lowest bit at first. (1) Using 74HC165 expand parallel input ports Please refer to the following circuit which using 2 pcs 74HC165 to expand 16 input I/Os H G F E D C B A 10 12 13 14 3 4 5 6 Q H Q H SIN S/L CP 9 7 1 15 2 8 16 Vcc 74HC165 H G F E D C B A 11 12 13 14 3 4 5 6 Q H Q H SIN S/L CP 9 7 1 15 2 8 16 Vcc 74HC165 12Cxx P3.0 P3.1 P1.0 10 104 104 11 74HC165 is a 8-bit parallel input shift register, when S/L (Shift/Load) pin is falling to low level, the parallel port data is read into internal register, and now, if S/L is raising to high and ClockDisable pin (15 pin) is low level, then clock signal from CP pin is enable. At this time register data will be output from the Dh pin (9 pin) with the clock input. … MOV R7,#05H ;read 5 groups data MOV R0,#20H ;set buffer address START: CLR P1.0 ;S/L = 0, load port data SETB P1.0 ;S/L = 1, lock data and enable clock MOV R1,#02H ;2 bytes per group RXDAT:MOV SCON,#00010000B ;set serial as mode 0 and enable receive data WAIT: JNB RI,WAIT ;wait for receive complete CLR RI ;clear receive complete flag MOV A,SBUF ;read data to ACC MOV @R0,A ;save data to buffer INC R0 ;modify buffer ptr DJNZ R1,RXDAT ;read next byte DJNZ R7,START ;read next group … 365 |
|
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 |