Re: Using 74xx574 D FF to expand PIC outputs



<snip>

Start

BUF0 equ 0x30 ; - 0x33
ADDRESSBUFFER equ 0x40

Setup
bsf STATUS,5 ; set bank 1
movlw b'00000000'
movwf TRISA
movlw b'00000000'
movwf TRISB
bcf STATUS,5 ; set bank 0

clrf PORTA

clrf BUF0
clrf BUF0+1
clrf BUF0+2
clrf BUF0+3

Loop

I think you need to set the comparator config register (CMCON) to 0x07 (00000111) to disable the comparators.
The power on default is for the register is 0 which enables the comparators and configures A0-A3 analog
inputs.

Mike C



If there is no absolute truth then nothing can be known.
.


Quantcast