how can we define different org addresses on xa65?

Programming the 6502 microprocessor and its relatives in assembly and other languages.
Post Reply
nitrofurano
Posts: 4
Joined: 26 Aug 2018

how can we define different org addresses on xa65?

Post by nitrofurano »

hi everyone!

on pasmo (z80) i use to define different org addresses along the code (like org $4000, org $5000, etc.) , and all the empty data lasts there in the exact addresses when compiled

i’m strugglng a lot to do the same on xa65 (6502) - when i set, for example *=$1000 , *=$1010, *=$F800 and *=$FFF8, it seems to consider only one of them (*=$1000) and ignore everything else

what am i doing wrong there?
CurtisP
Posts: 79
Joined: 10 Feb 2011

Re: how can we define different org addresses on xa65?

Post by CurtisP »

Csn you please post some example code?
chitselb
Posts: 232
Joined: 21 Aug 2010
Location: Ontonagon MI
Contact:

Re: how can we define different org addresses on xa65?

Post by chitselb »

CurtisP wrote:
Csn you please post some example code?
I am a huge xa65 fan! Here are the only two places where I do a `*=` in my code.

Code: Select all

#define basic $0401
*=basic-2
basic2pettil
    .word basic                 ; PRG file load address `$0401`
    .word basend
    .word 10
    .byt $9E                    ; SYS token
    .asc "1037",0               ; restart #1 (of 3) `liftoff`
basend
    .word 0

elsewhere...
hitop=VIDRAM-$1900
    .word hitop-2               ; load address
    .word tdictend-hitop        ; size of the transient dictionary in bytes
*=hitop
_studio
    jsr enter
    .word plit
    .word there+2
    .word fetchplus
    .word plus
    .word bl
    .word minus
    .word symtab                ; points to unindexed symbol list
    .word store
    .word _splash
within a block of memory I use ` .dsb ` instead of `*=*+`
Post Reply