Hi, how're all of you doing ?
I have a question regarding delays.
How can i calculate the exact time that i use in a delay, without using
any timer ?
This is a function that i made a little time ago for program.
delay
movlw 0xfff
movwf Cont1
again
movlw 0xff
movwf Cont2
loop
decf Cont2
movlw 0x00
xorwf Cont2
btfss STATUS,Z
goto loop
decf Cont1
movlw 0x00
xorwf Cont1
btfss STATUS,Z
goto again
return
I want to know this because i have to use a LCD for a project and on top of that i dont know how to use one yet
So i was reading that i need to use some delays for initializations
and if im going to do those delays i want to do it like the example
that i wrote up there without using a Timer.
And i would like to know how to do it if im going to use a delay of 5ms, 20ms for example.
Thank you again.
I have a question regarding delays.
How can i calculate the exact time that i use in a delay, without using
any timer ?
This is a function that i made a little time ago for program.
delay
movlw 0xfff
movwf Cont1
again
movlw 0xff
movwf Cont2
loop
decf Cont2
movlw 0x00
xorwf Cont2
btfss STATUS,Z
goto loop
decf Cont1
movlw 0x00
xorwf Cont1
btfss STATUS,Z
goto again
return
I want to know this because i have to use a LCD for a project and on top of that i dont know how to use one yet
So i was reading that i need to use some delays for initializations
and if im going to do those delays i want to do it like the example
that i wrote up there without using a Timer.
And i would like to know how to do it if im going to use a delay of 5ms, 20ms for example.
Thank you again.