File tree Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -35,21 +35,17 @@ GLABEL TIMER0_OVF_vect
3535 push ZH
3636 ldi ZH , hi8(t0_fract)
3737 ld r16 , Z
38- //subi r16 , lo8( - (FRACT_INC)) ; add millis fraction
39- //cpi r16 , FRACT_MAX ; C set when fract < FRACT_MAX
4038 subi r16 , lo8(FRACT_INC) ; subtract millis fraction
4139 brcc _no_underflow
4240 subi r16 , lo8( - FRACT_MAX) ; add FRACT_MAX, clears Carry
43- rjmp 2f
41+ rjmp 1f
4442_no_underflow:
4543 sec ; invert Carry
46- 2 :
44+ 1 :
4745 st Z +, r16
4846 ; add one more to millis LSB when fractional counter underflows
4947 ld r16 , Z
5048 sbci r16 , lo8( - (MILLIS_INC + 1 )) ; r16 += MILLIS_INC + NOT Carry
51- ;adc r16, r1 ; r16 += Carry
52- ;sbci r16, lo8(-(MILLIS_INC)) ; r16 += MILLIS_INC
5349 rjmp _save
5450_add1: ; handle most significant bytes
5551 ld r16 , Z
You can’t perform that action at this time.
0 commit comments