| Motor de Búsqueda de Datasheet de Componentes Electrónicos |
|
93LC66 Datasheet(PDF) 13 Page - Microchip Technology |
|
|
|||||||||||||||||||||||||||||
93LC66 Datasheet(HTML) 13 Page - Microchip Technology |
|
13 / 22 page ![]() © 1994 Microchip Technology Inc. DS00560D-page 13 Using the 93LC56 and 93LC66 8 0125 ; BITOUT routine 0126 ; This routine takes one bit of data in ‘do’ and 0127 ; transmits it to the serial EE device 0128 ;************************************************************* 0129 BITOUT 0130 0013 07CA btfss eeprom,do ; check state of data bit 0131 0014 0A17 goto bitlow ; low, goto bitlow 0132 0015 05C6 bsf port_b,datin ; high, set datain high 0133 0016 0A18 goto clkout ; and clock it 0134 ; 0135 0017 04C6 bitlow bcf port_b,datin ; output a logic low 0136 0018 05A6 clkout bsf port_b,sclk ; set clock line high 0137 0019 0000 nop 0138 001A 04A6 bcf port_b,sclk ; return clock line low 0139 001B 0800 retlw 0 0140 ; 0141 ;**************************************************************** 0142 ; Transmit Data Subroutine 0143 ; This routine takes the byte of data stored in the 0144 ; ‘datao’ register and transmits it to the serial EE device. 0145 ;**************************************************************** 0146 TX 0147 001C 0212 movf bits,w ; set the number of bits to xmit 0148 001D 0031 movwf count 0149 ; 0150 TXLP 0151 001E 04CA bcf eeprom,do ; assume bit 7 is low 0152 001F 06F0 btfsc txbuf,7 ; is bit 7 clear? 0153 0020 05CA bsf eeprom,do ; no, set data bit =1 16c5x/7x Cross-Assembler V4.12 Released Mon Jun 06 10:49:00 1994 Page 4 Line PC Opcode 0154 0021 0913 call BITOUT ; transmit 1 bit to serial EE 0155 0022 0370 rlf txbuf ; rotate txbuf left 0156 0023 02F1 decfsz count ; all bits done? 0157 0024 0A1E goto TXLP ; no, do another bit 0158 0025 0800 retlw 0 ; yes, jump out 0159 ; 0160 ;**************************************************************** 0161 ; POWER-UP ROUTINE 0162 ; This is the program entry point, which in this case simply 0163 ; sets the port_a I/O lines and directs control to the 0164 ; erase/write enable routine. 0165 ;***************************************************************** 0166 PWRUP 0167 ; 0168 0026 0C00 movlw b’00000000' 0169 0027 0005 tris port_a ; set port_a as all output 0170 0028 0065 clrf port_a ; all lines low 0171 0172 0029 0C80 movlw b’10000000' 0173 002A 0006 tris port_b ; set RB7 as input, rest output; 0174 ; 0175 ; Fall through and do erase/write enable 0176 ; 0177 ;**************************************************************** 0178 ; EWEN (Erase/Write ENable Routine) 0179 ; this routine enables the dut for erasing and 0180 ; writing. This must be done prior to any erase,write 0181 ; eral,wral instructions. 0182 ;**************************************************************** 0183 EWEN 0184 ; 0185 002B 0907 call BSTART ; generate a start bit 0186 ; 0187 002C 0C02 movlw .2 ; set # bits to 2 0188 002D 0032 movwf bits ; 8-111 |
|
|
Enlace URL |
| ¿ALLDATASHEET es útil para Ud.? [ DONATE ] |
Todo acerca de Alldatasheet | Publicidad | Contáctenos | Política de Privacidad | Enlace a la hoja de datos | Intercambio de Enlaces | Lista de Fabricantes 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 |