I am trying to implement a decrement counter for the seconds register
It works quite fine.
But I have the following issue.
When I am in the edit mode my seconds value should keep blinking on LCD
It works fine for all other values except 00
When the value 00 should keep blinking somehow '5A' blinks in place of 00
If anyone has an idea please let me know.
Thanks
label921:
movlw 0x01
subwf SECS1,0
btfss STATUS,DC
addlw -0x06
movwf SECS1
movlw 0xC6/////////position on display
movwf PORTD
call SND_CMD//////////send command to LCD
movf SECS1,0
call writebcd//////display data on LCD
movf SECS1,0
btfsc ZERO
call label_S0
return
label_S0:
movlw 0x00
movwf SECS1
movlw 0xC6
movwf PORTD
call SND_CMD
movf SECS1,0
call writebcd//////display data on LCD
movlw h'5A'
movwf SECS1
return
It works quite fine.
But I have the following issue.
When I am in the edit mode my seconds value should keep blinking on LCD
It works fine for all other values except 00
When the value 00 should keep blinking somehow '5A' blinks in place of 00
If anyone has an idea please let me know.
Thanks
label921:
movlw 0x01
subwf SECS1,0
btfss STATUS,DC
addlw -0x06
movwf SECS1
movlw 0xC6/////////position on display
movwf PORTD
call SND_CMD//////////send command to LCD
movf SECS1,0
call writebcd//////display data on LCD
movf SECS1,0
btfsc ZERO
call label_S0
return
label_S0:
movlw 0x00
movwf SECS1
movlw 0xC6
movwf PORTD
call SND_CMD
movf SECS1,0
call writebcd//////display data on LCD
movlw h'5A'
movwf SECS1
return