OpenCores
URL https://opencores.org/ocsvn/6809_6309_compatible_core/6809_6309_compatible_core/trunk

Subversion Repositories 6809_6309_compatible_core

[/] [6809_6309_compatible_core/] [trunk/] [sim/] [instructions_test.asm] - Blame information for rev 4

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 4 ale500
 
2
; simple instruction excerciser
3
                lda     #$02
4
                ldb     #$00
5
                sta     $0
6
                stb     $1
7
                ldx     $0      ; load saved value
8
                ldy     #$0
9
                cmpx    ,y      ; compare
10
                beq     test_push_pull
11
 
12
error:          bra     error
13
 
14
test_push_pull: lds     #$00ff
15
                pshs    a,b
16
                puls    x
17
                cmpx    ,y      ; compare again
18
                bne     error
19
 
20
                bsr     test_bsr
21
                bne     error   ; push/pull with sub don't work
22
                lbsr    test_lea
23
                bne     error
24
ok:             bra     ok
25
 
26
test_bsr:       pshs    y
27
                puls    y
28
                cmpx    0,y
29
                rts
30
 
31
test_lea:       leau    1,y
32
                leay    0,y
33
                rts

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.