Appendix A Instruction Set Introduction Appendix contains all instructions presented separately with examples for their use. Syntax, description and its effects on status bits are given for each instruction. A.1 MOVLW A.2 MOVWF A.3 MOVF A.4 CLRW A.5 CLRF A.6 SWAPF A.7 ADDLW A.8 ADDWF A.9 SUBLW A.10 SUBWF A.11 ANDLW A.12 ANDWF A.13 IORLW A.14 IORWF A.15 XORLW A.16 XORWF A.17 INCF A.18 DECF A.19 RLF A.20 RRF A.21 COMF A.22 BCF A.23 BSF A.24 BTFSC A.25 BTFSS A.26 INCFSZ A.27 DECFSZ A.28 GOTO A.29 CALL A.30 RETURN A.31 RETLW A.32 RETFIE A.33 NOP A.34 CLRWDT A.35 SLEEP A.1 Write constant in W register A.2 Copy W to f A.3 Copy f to d A.4 Write 0 in W A.5 Write 0 in f A.6 Copy the nibbles from f to d crosswise A.7 Add W to a constant A.8 Add W to f A.9 Subtract W from a constant A.10 Subtract W from f A.11 Logic AND W with constant A.12 Logic AND W with f A.13 Logic OR W with constant A.14 Logic ILI W with f A.15 Logic exclusive OR W with constant A.16 Logic exclusive OR W with f A.17 Increment f A.18 Decrement f A.19 Rotate f to the left through CARRY A.20 Rotate f to the right through CARRY A.21 Complement f A.22 Reset bit b in f A.23 Set bit b in f A.24 Test bit b in f, skip if it = 0 A.25 Test bit b in f, skip if =1 A.26 Increment f, skip if=0 A.27 Decrement f, skip if = 0 A.28 Jump to address A.29 Call a program A.30 Return from a subprogram A.31 Return from a subprogram with constant in W A.32 Return from interrupt routine A.33 No operation A.34 Initialize watchdog timer A.35 Stand by mode