added DEBUG4.

This commit is contained in:
Martin Preuss
2026-03-23 00:22:08 +01:00
parent a727d600f1
commit 41d60f4331

View File

@@ -25,8 +25,8 @@ DEBUG1:
DEBUG2: DEBUG2:
ldi r19, 50 ldi r19, 50
ldi r20, 1 ldi r20, 5
ldi r21, 1 ldi r21, 5
rcall blinkLed rcall blinkLed
rjmp DEBUG2 rjmp DEBUG2
@@ -40,17 +40,32 @@ DEBUG3:
DEBUG4:
ldi r19, 50
ldi r20, 18
ldi r21, 2
rcall blinkLed
ldi r19, 50
ldi r20, 1
ldi r21, 9
rcall blinkLed
rjmp DEBUG4
; @param r19 loop count ; @param r19 loop count
; @param r20 on time ; @param r20 on time
; @param r21 off time ; @param r21 off time
; @clobbers (R16, R18, R22, R24, R25) ; @clobbers (R19, R22)
blinkLed: blinkLed:
sbi LED_SIMPLE_DDR, LED_SIMPLE_PINNUM ; out sbi LED_SIMPLE_DDR, LED_SIMPLE_PINNUM ; out
blinkLed_loop: blinkLed_loop:
cbi LED_SIMPLE_PORT, LED_SIMPLE_PINNUM ; on cbi LED_SIMPLE_PORT, LED_SIMPLE_PINNUM ; on
mov r22, r20 mov r22, r20
rcall waitForMultiple100ms ; (R252 rcall waitForMultiple100ms ; (R22)
sbi LED_SIMPLE_PORT, LED_SIMPLE_PINNUM ; off sbi LED_SIMPLE_PORT, LED_SIMPLE_PINNUM ; off
mov r22, r21 mov r22, r21
rcall waitForMultiple100ms ; (R22) rcall waitForMultiple100ms ; (R22)