Hello,
I'm hoping someone can help me here... I'm working on a project using the PIC16HV785, and seem to be struggling to get the device to recognise inputs. When I build the .ASM, I get an warning when the build gets to the following line:
MOVLW B'00011111'
MOVWF TRISA
saying that the "register in Operand not in Bank0". Which I know. The register is in Bank1, which I have tried to switch to in the configuration section (below). Where might I be going wrong? bit 5 set and clear on the STATUS register is for the bank, correct? I've spent days on this now!
Thanks,
Chris
;CONFIGURATION SECTION
START BSF STATUS,5
MOVLW B'00011111'
MOVWF TRISA
MOVLW B'00000000'
MOVWF TRISB
MOVLW B'00000111'
MOVWF OPTION_R
BCF STATUS,5
CLRF PORTA
CLRF PORTB