They are all equal.
TMR1H = %01010101
TMR1L = %11110001
Produces;
HighTimes = 10Code:MOVLW 0x55 MOVWF TMR1H MOVLW 0xf1 MOVWF TMR1L
LowTimes = 20 ' loading these vars is the only real time difference
TMR1H = HighTimes
TMR1L = LowTimes
Produces;
The 2nd version of course depends on which bank your vars are in.Code:MOVF _HighTimes, W MOVWF TMR1H MOVF _LowTimes, W MOVWF TMR1L
Could take more code if they're not in bank0.
Bookmarks