blueroomelectronics
Well-Known Member
Gotta get that indent (space or tab) before, PS that version of the 16F877A was completly wrong, don't know how it slipped past me.
Although "org 0" works but it lazy coding(zero is zero in any base), org 0x000 is surefire (hex 000). if you want to use base 10 then put a decimal in front like this .0
Although "org 0" works but it lazy coding(zero is zero in any base), org 0x000 is surefire (hex 000). if you want to use base 10 then put a decimal in front like this .0
Code:
;*** WDT reset toggles RB0
list p=16F877A
include <p16F877A.inc>
__CONFIG 0x3F7D
org 0
bsf STATUS, RP0
movlw b'00001110'
movwf OPTION_REG
movlw b'11111110'
movwf TRISB
bcf STATUS, RP0
movlw 1
xorwf PORTB, f
sleep
end
Last edited: