From 1771ee8da7530c6ce55439f75763635bdad48d33 Mon Sep 17 00:00:00 2001 From: Virgil Dupras Date: Sun, 22 Dec 2019 15:01:08 -0500 Subject: [PATCH] avra: add SER --- apps/zasm/avr.asm | 9 ++++++--- tools/tests/avra/test1.asm | 1 + tools/tests/avra/test1.expected | Bin 30 -> 32 bytes 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/apps/zasm/avr.asm b/apps/zasm/avr.asm index 0a65537..d750339 100644 --- a/apps/zasm/avr.asm +++ b/apps/zasm/avr.asm @@ -83,6 +83,7 @@ instrNames: .db "SEH", 0 .db "SEI", 0 .db "SEN", 0 +.db "SER", 0 .db "SES", 0 .db "SET", 0 .db "SEV", 0 @@ -92,7 +93,7 @@ instrNames: .db "SWAP", 0 .db "WDR", 0 .db "XCH", 0 -.equ I_ANDI 77 +.equ I_ANDI 78 .db "ANDI", 0 .db "CBR", 0 .db "CPI", 0 @@ -101,10 +102,10 @@ instrNames: .db "SBCI", 0 .db "SBR", 0 .db "SUBI", 0 -.equ I_RCALL 85 +.equ I_RCALL 86 .db "RCALL", 0 .db "RJMP", 0 -.equ I_CBI 87 +.equ I_CBI 88 .db "CBI", 0 .db "SBI", 0 .db "SBIC", 0 @@ -187,6 +188,7 @@ instrTbl: .db 0x00, 0b10010100, 0b01011000 ; SEH .db 0x00, 0b10010100, 0b01111000 ; SEI .db 0x00, 0b10010100, 0b00101000 ; SEN +.db 0x0a, 0b11101111, 0b00001111 ; SER Rd .db 0x00, 0b10010100, 0b01001000 ; SES .db 0x00, 0b10010100, 0b01101000 ; SET .db 0x00, 0b10010100, 0b00111000 ; SEV @@ -483,6 +485,7 @@ argSpecs: .db 'R', 'A' ; Rd(5) + A(6) .db 'D', 0 ; K(12) .db 'a', 'b' ; A(5) + bit + .db 'r', 0 ; Rd(4) ; Parse arguments from I/O according to specs in HL ; H for first spec, L for second spec diff --git a/tools/tests/avra/test1.asm b/tools/tests/avra/test1.asm index bd70276..65b66a0 100644 --- a/tools/tests/avra/test1.asm +++ b/tools/tests/avra/test1.asm @@ -16,3 +16,4 @@ out 0x2e, r12 in r0, 0x9 cbr r31, 0xff sbis 22, 5 +ser r19 diff --git a/tools/tests/avra/test1.expected b/tools/tests/avra/test1.expected index 5e1c99142f29dc7d12b8b921debe1e1d1cd24372..738c7434afb01f9f04eec39416988024ba6e2ca5 100644 GIT binary patch delta 7 Ocmb1Bm>|bw{~iDaR016U delta 4 LcmY$8n;-`O0vrJC