Always use new shortened address assignment protocol if possible.

This commit is contained in:
Martin Preuss
2023-02-06 21:11:24 +01:00
parent b3b5aaba43
commit 2ce2aa03c8

View File

@@ -242,12 +242,10 @@ blinkPattern2: .db 10, 20, 0xff, 0xff ; 1 long blink, 2s pause, restart
; USED: depending on called routines
onSystemStart:
rcall Utils_SetupUid
#ifdef MODULES_COM
rcall Utils_SetupUid
; brcc onSystemStart_l1
onSystemStart_l1:
rcall CPRO_StartReclaimAddrProcedure
#endif
ret
@@ -358,20 +356,15 @@ onEvery30s_l1:
; USED: depending on called routines
onEveryMinute:
in r15, SREG ; debug
cli
push r15
#ifdef MODULES_COM
ldi r16, 219
lds r16, comAddress ; do we have an address assigned?
tst r16
breq onEveryMinute_l1 ; no, do nothing
ldi r16, 0xff ; send stats to everybody
rcall CPRO_EnqueueComSendStats
;ldi r16, 219
;rcall CPRO_EnqueuePing
onEveryMinute_l1:
#endif
pop r15
out SREG, r15
ret