solved Task 3d

This commit is contained in:
Schrom01
2022-11-11 11:13:06 +01:00
parent f58771a1b5
commit d637291eb3
10 changed files with 257 additions and 182 deletions
+19
View File
@@ -148,6 +148,25 @@ case_red
; Show Diff on 7-Segment
LDR R3, =ADDR_7_SEG_BIN_DS3_0
STRB R2, [R3]
; Count 0 Bits in diff
LDR R3, =0x9 ; Count down
LDR R4, =0x0 ; Count 0 bits
LDR R5, =0x01 ; Value 1
loop_count_0_bits
SUBS R3, R3, R5
BEQ end_loop_count_0_bits
LSRS R2, R2, #1
BHS loop_count_0_bits
ADDS R4, R4, R5
B loop_count_0_bits
end_loop_count_0_bits
; Show 0 Bits in lcd 2nd line
LDR R3, =ADDR_LCD_ASCII_2ND_LINE
LDR R5, =ASCII_DIGIT_OFFSET
ADDS R4, R4, R5
STRB R4, [R3]
B main_loop
case_green