Created
November 19, 2011 21:52
-
-
Save neuro-sys/1379411 to your computer and use it in GitHub Desktop.
passing function pointer in PIC
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
temp EQU 0x20 | |
movlw HIGH Text1 | |
movwf PCLATH | |
movlw LOW Text1 | |
movwf temp | |
call LCD_String | |
movlw HIGH Text2 | |
movwf PCLATH | |
movlw LOW Text2 | |
movwf temp | |
call LCD_String | |
LCD_String: | |
clrf i | |
L: movf temp,w | |
call $+2 | |
goto $+2 | |
movwf PCL | |
iorlw 0 | |
btfsc STATUS,Z | |
return | |
call LCD_Putc | |
incf i,F | |
LCD_Wait | |
goto L | |
Text1: | |
movf i,w | |
addwf PCL,F | |
dt "neurosys",0 | |
Text2: | |
movf i,w | |
addwf PCL,F | |
dt "Hello",0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment