【发布时间】:2020-01-29 04:57:59
【问题描述】:
; point FSR0 to address 0x0 and set INDF to 'A'
movlw 0x0
movwf FSR0
movlw A'A'
movwf INDF0
; increment FSR0, then set new INDF to 'B'
incf FSR0
movlw A'B'
movwf INDF0
; decrement FSR0, then show the new INDF to LCD, it should show the letter 'A', but 'B' is shown.
decf FSR0
movf INDF0, 0
call LCD8SendData
为什么显示的是“B”而不是“A”?我已经递减了 FSR0 指针。
【问题讨论】:
-
你有一个模拟器来单步执行你的代码吗?
-
也许你的
LCD8SendData函数有错误。使用调试器来验证每条指令的结果。
标签: assembly microcontroller pic18