Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > 6502 Cross assembler for KPC pascal
2008-11-08 11:43
Bones99

Registered: May 2005
Posts: 29
6502 Cross assembler for KPC pascal

I've been playing with RJ Kuhn's 6502 pascal compiler (http://www.geocities.com/rjkuhn_2000/software.htm#kpc).
I can get it to compile, but i cant seem to find a cross-assembler that likes this format .

Anyone have any idea ?
I suppose I could write a pre-processor for one of the many cross-assemblers out there, but I'd prefer to avoid doing that if I can.

the ASM it generates looks like this :

;;KPC02 Output
BP EQU $F0
BX EQU $F2
BL EQU BX
BH EQU BX+1
AX EQU $F4
AL EQU AX
AH EQU AX+1
DX EQU $F6
DL EQU DX
DH EQU DX+1
CX EQU $F8
CL EQU CX
CH EQU CX+1
R28H EQU CX
R2AH EQU $FA
R2CH EQU $FC
R2EH EQU $FE
ORG $2000
JMP ZMAIN
C DS 2
D DS 2
E DS 2
F DS 2
;;
ZMAIN EQU *
LDY #>D
LDA #<D
STY BX
STA BX+1
LDY E
LDA E+1
STY AX
STA AX+1
LDY F
LDA F+1
STY DX
STA DX+1
LDY #>2
LDA #<2
STY CX
STA CX+1
LDA DX
STA BP
LDA DX+1


etc..
2008-11-08 12:47
Oswald

Registered: Apr 2002
Posts: 5020
looks like the assembler steve judd used on c128. Merlin 128.
2008-11-08 13:06
Bones99

Registered: May 2005
Posts: 29
ok.. DASM seems to handle it , as long as you specify the "processor 6502" directive at the top of the code.
2008-11-08 13:46
iAN CooG

Registered: May 2002
Posts: 3135
No, you don't even need that =)
Get my version of DASM, we have talked about it 2 days ago
2008-11-08 14:08
Bones99

Registered: May 2005
Posts: 29
Quote: No, you don't even need that =)
Get my version of DASM, we have talked about it 2 days ago


Nice one!

I plugged it in to crimson editor and it just worked!
I can now compile from pascal source to .prg with just 2 keypresses, thanks for that Ian.
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
csabanw
Mike
encore
TheRyk/MYD!
psych
Clayboy
Marco/DDM
Dymo/G★P
kbs/Pht/Lxt
oziphantom
Mibri/ATL^MSL^PRX
wil
Guests online: 152
Top Demos
1 Next Level  (9.8)
2 Mojo  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Comaland 100%  (9.6)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 Wonderland XIV  (9.6)
9 Memento Mori  (9.6)
10 Bromance  (9.5)
Top onefile Demos
1 It's More Fun to Com..  (9.7)
2 Party Elk 2  (9.7)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.5)
5 TRSAC, Gabber & Pebe..  (9.5)
6 Rainbow Connection  (9.5)
7 Wafer Demo  (9.5)
8 Dawnfall V1.1  (9.5)
9 Quadrants  (9.5)
10 Daah, Those Acid Pil..  (9.5)
Top Groups
1 Nostalgia  (9.3)
2 Oxyron  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 Crest  (9.3)
Top Organizers
1 Burglar  (9.9)
2 Sixx  (9.8)
3 hedning  (9.7)
4 Irata  (9.7)
5 MWS  (9.6)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.04 sec.