We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 77a6f48 commit 4fd88adCopy full SHA for 4fd88ad
1 file changed
test/pinmode/pinmode-asm.c
@@ -39,6 +39,7 @@ __asm
39
clrw x
40
ld a, (3, sp)
41
ld xl, a
42
+ pushw x
43
addw x, #(_digital_pin_to_bit_mask_PGM + 0)
44
ld a, (x)
45
ld yl,a ; yl = bit
@@ -51,12 +52,10 @@ __asm
51
52
; pinmode-c.c: 10: uint8_t port = digitalPinToPort(pin);
53
; pinmode-c.c: 13: if (port == NOT_A_PORT) return;
54
; es könnte auch subw x, #(NUM_DIGITAL_PINS) sein
- clrw x
55
- ld a, (3, sp)
56
- ld xl, a
+ popw x
57
addw x, #(_digital_pin_to_port_PGM + 0)
58
ld a, (x) ; port-ID. Z-Flag wird gesetzt
59
- jreq 010$
+ jreq 032$ ; if (port == NOT_A_PORT) return;
60
61
62
;
@@ -119,7 +118,7 @@ __asm
119
118
BIT_CLEAR(CR2)
120
BIT_SET(DDR)
121
rim
122
- ret
+032$: ret
123
124
125
; case INPUT // 0: input, floating
0 commit comments