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 > crossassembling
2007-01-02 07:17
null
Account closed

Registered: Jun 2006
Posts: 645
crossassembling

Since I have a laptop running Win2k now, I was looking for a crossassembler... but all I can find are tools to convert a .txt file to a c64 understandable format...(atleast, that's what I think they do...o.O)

Isn't there some kind of complete package running under Win2k, like you have Turbo Assambler on the c64?

and if there isn't... START CODING!!! =P

...nah, just kidding... in that case, I'd like to hear an easy solution for coding on a PC.

Cheers,
Knoeki.
2007-01-02 08:08
Style

Registered: Jun 2004
Posts: 498
Kick Assembler 2.12
2007-01-02 10:05
null
Account closed

Registered: Jun 2006
Posts: 645
Yeah, I have that one... but I can't figure out how it works...o.o
2007-01-02 10:05
QuasaR

Registered: Dec 2001
Posts: 145
or this one...

Relaunch64 V2.0
2007-01-02 10:09
Mace

Registered: May 2002
Posts: 1799
step 1)
Download and install EditPlus.

step 2)
Download 64TASS. Put the files in a subfolder of the EditPlus directory.

step 3)
Configure EditPlus so that CTRL+1 compiles your code using 64TASS.

step 4)
Code 'macro assembly' in EditPlus and compile with 64TASS.
2007-01-02 10:48
null
Account closed

Registered: Jun 2006
Posts: 645
Quote: or this one...

Relaunch64 V2.0


ok, that one is understandable... but everytime I assamble & run, I get a VICE error, saying something about a commandline option... I can't read the whole error, as there is too much text in the window >_<;


/knoeki
2007-01-02 11:01
Scout

Registered: Dec 2002
Posts: 1568
Quote: ok, that one is understandable... but everytime I assamble & run, I get a VICE error, saying something about a commandline option... I can't read the whole error, as there is too much text in the window >_<;


/knoeki


Relaunch is an editor and not a cross-compiler.
I guess that explains it.

For starters, look at Mace's reply and leave that Kick Assembler alone for a year or so (ie. it is not recommended for n00bs).
2007-01-02 11:11
null
Account closed

Registered: Jun 2006
Posts: 645
I know it's not a cross compiler, that's why I have DASM hooked up to it, so I can compile it... the problem is that VICE gives me this damned error...o.O;

something like this:

"Extra arguments on command-line" followed by the dir where I compile to...
2007-01-02 11:14
Scout

Registered: Dec 2002
Posts: 1568
rtfm?
2007-01-02 11:19
null
Account closed

Registered: Jun 2006
Posts: 645
yeah, I got it to work, thanks to scout pointing out that I should "Read The Fine/Fucking/Fantastic/Fabulous Manual" ^_^


/knoeki
2007-01-02 11:21
Scout

Registered: Dec 2002
Posts: 1568
\:D/
2007-01-02 11:23
null
Account closed

Registered: Jun 2006
Posts: 645
Just one more small question:

what should the start adress of my code be? f.ex:

*=$1000

or something like that...


and which SYS code do I use in VICE to run the actual code?


/knoeki
2007-01-02 11:30
Oswald

Registered: Apr 2002
Posts: 5031
*=$1000 is good for a start

sys4096 is teh secret start line :)
2007-01-02 11:43
null
Account closed

Registered: Jun 2006
Posts: 645
Quote: *=$1000 is good for a start

sys4096 is teh secret start line :)


Might be me, but it doesn't work...o.O this is what I do:

step 1 (Code):

*=$1000
inc $d020
jmp $1000

step 2:

Press the Assamble and start source button... this opens Vice.

step 3:

SYS4096

when I do that, the screen is just cleared, and I get the well known READY. message...o.o

Am I overlooking something?
2007-01-02 11:50
Scout

Registered: Dec 2002
Posts: 1568
step 2.5 : does it load your program?
2007-01-02 13:10
null
Account closed

Registered: Jun 2006
Posts: 645
good point... doesn't quite look like it...o.O;


/knoeki
2007-01-02 13:13
algorithm

Registered: May 2002
Posts: 702
or place something such as

*=$0800
!byte $xx,$xx,$xx,$xx,$xx,... etc

where xx is a combination of bytes which create an sys call in basic
2007-01-02 13:19
Frantic

Registered: Mar 2003
Posts: 1633
Like algorithm said.. Something like:

* = $0801

basic: ;"SYS2061"
.byte $0c,$08,$64,$0c,$9e,$32,$30
.byte $36,$31,$00,$00,$00
your_code_starts_here:

...OR use pucrunch or something like that to make it an executable (which includes such a SYS-instruction in its output).
2007-01-02 13:23
Scout

Registered: Dec 2002
Posts: 1568
Guys (algorithm+frantic).. his program has to load first.

Besides that, Knoeki is an absolute n00b regarding assembler so leave the pucrunch/exomizer bells 'n' whistles to rest for a while.
2007-01-02 13:36
Devia

Registered: Oct 2004
Posts: 401
inc $d020 is n00b'ish?
2007-01-02 13:39
null
Account closed

Registered: Jun 2006
Posts: 645
Quote: inc $d020 is n00b'ish?

I just used that as an example to test Relaunch + DASM + VICE... but VICE doesn't load my code, and there's the problem... as soon as I have this fixed, I'm gonna check out the Hex files again...=)
2007-01-02 13:45
Devia

Registered: Oct 2004
Posts: 401
x64.exe -autostart kickassdemo.prg

that will load the kickassdemo.prg and do a RUN, so you'd need that basic header or just ALT+R and then SYS4096 or whatever after loading.

..you "might" need to be in the directory of kickassdemo.prg.. can't remember if Vice handles paths properly or if that was some other emul that fucked that up.
2007-01-02 13:51
null
Account closed

Registered: Jun 2006
Posts: 645
Quote: x64.exe -autostart kickassdemo.prg

that will load the kickassdemo.prg and do a RUN, so you'd need that basic header or just ALT+R and then SYS4096 or whatever after loading.

..you "might" need to be in the directory of kickassdemo.prg.. can't remember if Vice handles paths properly or if that was some other emul that fucked that up.


well, in relaunch64 I alredy configured VICE to have -autostart (that happens automaticly)... It's just that VICE doesn't load the code...o.O


/knoeki
2007-01-02 14:54
Frantic

Registered: Mar 2003
Posts: 1633
perhaps the cross assembler you use doesn't apply a 2 byte load adress to the start of the file? ...but you said DASM, right? I think that one does..

You may need to switch cartridges off in VICE to get it working automatically. Otherwise you'll have to press F1 or so, if it's action replay.. ...and if you don't do it relatively fast, VICE won't go on with the autoload, eh.

(BTW, if you have RR-Net, I'd suggest using that instead, and transfer the code to the real thing instead of VICE.)
2007-01-02 15:22
Oswald

Registered: Apr 2002
Posts: 5031
knoeki: enter monitor in vice and check wether it has loaded your prg (most probably it has not). Anyways you should see the emulated c64 telling you:

load"myprogram.prg",8,1
searching for myprogram.prg
loading
ready
run

if you dont see the above only the basic prompt, then vice havent loaded anything up.

in vice: alt+m, and then d1000 in the monitor prompt. if you dont see inc d020 at the 1000 adress then your prg is not loaded, then doublecheck your commandline settings in relaunch64.
2007-01-02 15:22
null
Account closed

Registered: Jun 2006
Posts: 645
Quote: perhaps the cross assembler you use doesn't apply a 2 byte load adress to the start of the file? ...but you said DASM, right? I think that one does..

You may need to switch cartridges off in VICE to get it working automatically. Otherwise you'll have to press F1 or so, if it's action replay.. ...and if you don't do it relatively fast, VICE won't go on with the autoload, eh.

(BTW, if you have RR-Net, I'd suggest using that instead, and transfer the code to the real thing instead of VICE.)


I don't have an RR-net... I wish I had one...

also, I dont use any carts in VICE...

...strange...o.O;
2007-01-02 15:24
Raf

Registered: Nov 2003
Posts: 343
Quote: step 1)
Download and install EditPlus.

step 2)
Download 64TASS. Put the files in a subfolder of the EditPlus directory.

step 3)
Configure EditPlus so that CTRL+1 compiles your code using 64TASS.

step 4)
Code 'macro assembly' in EditPlus and compile with 64TASS.


currently I'm using textpad (http://www.textpad.com) with DASM 2.20 by IaN Coog + I have 6502 syntax highlight too (also at textpad.com)

and... I setup it so ctrl+1 assembles too ;p



www.vulture.c64.org
2007-01-02 15:27
null
Account closed

Registered: Jun 2006
Posts: 645
Quote: knoeki: enter monitor in vice and check wether it has loaded your prg (most probably it has not). Anyways you should see the emulated c64 telling you:

load"myprogram.prg",8,1
searching for myprogram.prg
loading
ready
run

if you dont see the above only the basic prompt, then vice havent loaded anything up.

in vice: alt+m, and then d1000 in the monitor prompt. if you dont see inc d020 at the 1000 adress then your prg is not loaded, then doublecheck your commandline settings in relaunch64.


well, this all doesn't work...o.O


and also, I was mistaken... I'm not using DASM, but ACME... sorry for the confusion...o.o;
2007-01-02 15:58
hollowman

Registered: Dec 2001
Posts: 474
If I was to begin learning to code assembler on c64 I would start with turbo assembler on the c64, or run it under vice. Sure its nice to have all the memory available and not have to worry about crashing the c64 and trashing the source code in memory, but for trying out stuff its quicker and easier to use turbo assembler than setting up a crossdevelopment enviroment as the first step.
2007-01-02 16:08
Oswald

Registered: Apr 2002
Posts: 5031
why would you worry about loosing source using vice ? loadstate / savestate is ther. (and actually thats how I used to code, since I cannot tear out my tasm roots)
2007-01-02 16:47
cadaver

Registered: Feb 2002
Posts: 1154
To be honest I wouldn't trust an IDE, just make some one-letter bat files, one for running the editor and other for compiling+launching the emulator. Then hone your Alt+W reflex and I don't think the speed difference to using tasm is that much. Plus that way you can't screw up when you save a state instead of load.
2007-01-02 16:53
Mace

Registered: May 2002
Posts: 1799
Knoeki, if you want some fast help from your Dutch friends, turn to 64TASS. You know where to find us.

You are being impractical and stubborn now ;-)
2007-01-02 16:53
Oswald

Registered: Apr 2002
Posts: 5031
tastes are different. pressing accidentally save is a stupid argument, you can the same way not save your src when closing the editor or one can come up with 27 similar stupid arguments. there are much better arguments pro real cross asming than pressing accidentally alt-s :)
2007-01-02 18:24
Slammer

Registered: Feb 2004
Posts: 416
>Yeah, I have that one... but I can't figure out how it works...o.o

Hey Knoeki, I'm a bit curious. What was it you didn't get to work?
2007-01-02 19:54
Marauder/GSS
Account closed

Registered: Jul 2006
Posts: 224
guess it's not running your file in vice, because your source-code doesn't get compiled...

I have tested it with Relaunch/ACME 0.90 and it works fine after changing commandline parameters for ACME to:

-f CBM -o OUTPUT INPUT

(and for VICE just -autostart)

after compiling the emulator should start and load your output-file like Oswald has posted before... and then you only need to run it by typing SYS 4096 (*=$1000 in your example)

2007-01-02 21:36
Melkor

Registered: Apr 2006
Posts: 11
If your using ACME have you defined your output filename with !TO "filename.prg",cbm ?
2007-01-02 22:20
Devia

Registered: Oct 2004
Posts: 401
oh for crying out loud... screw that relaunch and fancy editor stuff until you know wtf you're doing. Notepad, write code, save code, start cmd.exe, assemble by hand with the assembler of your choice, THEN start Vice and load the assembled prg MANUALLY. When THAT works, THEN try to cut corners with fancy editors, makefiles and whatnots.

If I was to start all over again, I'd use TMP on the real shit. You won't need the comfy xdev environment until much much later ;-)

2007-01-02 23:00
Marauder/GSS
Account closed

Registered: Jul 2006
Posts: 224
Quote: If your using ACME have you defined your output filename with !TO "filename.prg",cbm ?

no, on my test I haven't used the !TO "filename.prg",cbm option in the source-code, as Relaunch automaticly uses the name of source-code file + changing extension to .prg then I think...

btw, I'm not using ACME, so I'm not an expert in that... I've just executed acme.exe direcly to find out the parameters (as it didn't work with the default params provided by that Relaunch-thingy) and then just used them in Relaunch-settings for the test...

my current setup for VICE is simple:

- drive#8 for attaching d64-images
- drive#9 for attaching a directory on my hdd
- using my old SpeedDos C64 ROM for having extended functions like f-keys (showing dir, switching drive 8/9, realtime monitor for dumping memory) and hex-number support like "print $1103", @$ for dir, etc.
- TURBO ASSEMBLER (v5.5) - what else? (c;
- (or Turbo Macro Pro maybe, hehe)

2007-01-03 01:38
null
Account closed

Registered: Jun 2006
Posts: 645
Ok, I've tried about everything here, but VICE still doesn't load my program... and I know why...(I think)

Every I press the "Assamble and Run" button in Relaunch64, a command-prompt window pops up for about a second (which is probably ACME running or something), and just now, in a short flash, I saw something like "error" and more blabla...o.o


Also, I already used Turbo Assambler, but crossassambling seems nice...
2007-01-03 06:45
Raf

Registered: Nov 2003
Posts: 343
then invoke acme from commandline by hand , not from relaunch - to ensure what u'r doing wrong ;p

www.vulture.c64.org
2007-01-03 07:01
Marauder/GSS
Account closed

Registered: Jul 2006
Posts: 224
Quote: Ok, I've tried about everything here, but VICE still doesn't load my program... and I know why...(I think)

Every I press the "Assamble and Run" button in Relaunch64, a command-prompt window pops up for about a second (which is probably ACME running or something), and just now, in a short flash, I saw something like "error" and more blabla...o.o


Also, I already used Turbo Assambler, but crossassambling seems nice...


well Knoeki, like I've already mentioned it a few posts before, I had this also on my test with those programs.

And that's why I've compiled the source with ACME in dos-box first... and then I've used these params and just changed compiler-settings for ACME in Relaunch to: -f CBM -o OUTPUT INPUT

and then it works for me that it loads the compiled program in vice also...
2007-01-04 12:13
null
Account closed

Registered: Jun 2006
Posts: 645
Well, thanks to Mace everything works now. thanks!

*goes back to coding*
2007-01-04 15:27
Frantic

Registered: Mar 2003
Posts: 1633
...and what was the problem? Got curious.. :)
2007-01-04 15:28
Scout

Registered: Dec 2002
Posts: 1568
Quote: ...and what was the problem? Got curious.. :)

The problem was solved using Editplus + 64Tass.
We have a happy Knoeki now.
2007-01-04 16:39
Cruzer

Registered: Dec 2001
Posts: 1048
@Knoeki: Always nice to see new people taking up C64 coding. Looking forward to your 1st machine code demo, although it might take a while. It took almost 2 years from I started machine code coding until I released my first demo. So have patience. :)
2007-01-04 17:14
Marauder/GSS
Account closed

Registered: Jul 2006
Posts: 224
Quote: ...and what was the problem? Got curious.. :)

I guess the problem was that ACME didn't compile the source due to wrong commandline-parameters in Relaunch, hence there was no file created and that's why Vice didn't load anything...

I have tested it out and got the same behaviour, but just after changing the parameters in Relaunch all worked fine, like mentioned in my previous posts... ;)

anyway, good luck Knoeki... looking forward to see first demo! (c;
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
AüMTRöN
Slator/Arsenic/Stone..
Guests online: 129
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.7)
5 Edge of Disgrace  (9.7)
6 No Bounds  (9.6)
7 Aliens in Wonderland  (9.6)
8 Comaland 100%  (9.6)
9 Uncensored  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 Layers  (9.6)
2 Cubic Dream  (9.6)
3 Party Elk 2  (9.6)
4 Copper Booze  (9.6)
5 TRSAC, Gabber & Pebe..  (9.5)
6 Rainbow Connection  (9.5)
7 Dawnfall V1.1  (9.5)
8 It's More Fun to Com..  (9.5)
9 Daah, Those Acid Pil..  (9.5)
10 Birth of a Flower  (9.5)
Top Groups
1 Nostalgia  (9.4)
2 Oxyron  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 SHAPE  (9.3)
Top Graphicians
1 Mirage  (9.8)
2 Archmage  (9.7)
3 Talent  (9.6)
4 Facet  (9.6)
5 Hend  (9.6)

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