Hello. I'm MetalSlime. You might remember me from
the 4-way Dragon Warrior Scrolling thread. I haven't posted much recently, but I've been lurking.
Working on that Dragon Warrior project taught me a LOT about basic NES programming, and it gave me confidence because everything started clicking. But I bit off more than I could chew. Too much too early. So, I'm starting anew with a smaller, less-ambitious project.
I came up with a concept for a nice little one-screen game and I'm going to spend a lot of time designing it before I start coding. But when I do get there, I think I'm going to want to use a new assembler. I was using NESASM before and there were some things I didn't like about it. It was hard to manage my big project, it didn't have debugging features, no anonymous labels (or if it did have them, I never figured it out). I want something that can handle big projects as well as small projects.
I've read about a bunch of assemblers on these boards: NESASM, CA65, P65, WLA-DX, ASM6. So what assembler do YOU use? What advantages do you think your assembler has? And what disadvantages do you think other assemblers have?
Please help me decide!
(P.S. I've read through
this thread so I actually already know which assemblers some of you use. I'm just looking for more detailed information).
I use WLA-DX. It's pretty good for the most part. Though I can't compare it to CA65 because I haven't ever used CA65. That's what everyone around here seems to use... I will say that to me, it was a huge relief after using NESASM.
But some good features in general are nameless lables (name them with + or - signs), decent macro making capability, handy little things like ".incbin 'blah.bin' SKIP 50", which incbins the file other than the first 50 bytes. I don't know if these are really any "special" features, but they are definitely nice to have.
One of the dumb things about it is that when you do something like "lda label,y" you have to write "lda label.w,y", and I really don't know why.
EDIT: On a side note, I was actually fighting the MetalSlime in DW a few days ago
. I wish I could kill it more often, it gives good experience. Way off topic, sorry.
As I said in that thread, I think ASM6 is the best. Mainly because you can make the most complicated ROM ever (in terms of banks) without going through all that crap of setting up segments and such.
Maybe it's seen as a less professional assembler exactly because of the lack of segments and other features, and some may think it's not very interesting because it's not open source. I still like it though, because it's really easy to organize the source files using "include" and other directives that help with banswitching.
I use WLA-DX. That doesn't mean I think it's the best assembler ever, but after trying a few assembler I just was amazed by its features.
About it I like the fact that you can put stuff into sections, and that the sections in the binary file are not in the same order than in the assembly file (that limitation of NESASM is very annoying). I like the fact you can create sine tables, have some special incbin features as Celius mentionned, and the overwrite feature that allows you to overwrite some CHR data you don't use by other data. I like that WLA allows you to do bankwitching easily, and it even have provisions for having the same routine at the same adress in different banks, which could be usefull for AOROM games. I like the fact you can align sections so that you are sure that a group of bytes does not cross a page bounary and this allows simplifications in the code. There is also the structure feature which is good but not as usefull as it sounds as first (you'll be using indirect adressing anyway). I also like the fact that if you want to do GB-dev, C64-dev, SNES-dev, etc... you can just use the same programm and not worry about syntax and features of a new assembler for days.
I don't like the fact you have to write sta Label.w,X instead of just sta Label,X if you get out of zero-page. If I remember well you could do the other way arround, so that all zero page instuctions should use .b and otherwise .w is assumed, but I use zero page more often (that's what it was meant to), and if I would forget the .b, it would compile without error but waste bytes, and I didn't want that.
I also don't like that there is no provisions for relocatable code, WLA just assumes you'll be only executing code for ROM. On other systems, where the code is always running from RAM such as the Commodore 64, this is *very* annoying, becuase it forces your binary size to a fixed size as if it was ROM, when in fact it's just a file you load in RAM, and you don't want it to be larger than the space it actually takes. You cannot align RAM sections as well, which is an annoyance. Finally, there is no C compiler as there is for CC65 (altough nobody got something working decently for the NES with it yet).
I hope this will give you a good overview of WLA-DX.
I am learning to use ASM6. Well, it doesn't really take much learning, it just basically works.
My favorite thing is that it takes no setup or messing around. It's just a single executable, and takes one command or a batch file to make a NES file.
I don't want to bash other assemblers without having used them but it does seem really inconvenient to have to type something like label.w. Others are more powerful but ask more of the user to know what he is doing.
If nothing else, a simpler assembler is good for learning on and creating demos. You don't want to get hung up on picking an assembler and setting it up, that should be a minor point; you want to get in there and start learning!
Of course there is something to be said for future proofing yourself in case you'll want more power later. I think as you get into more complicated programs you'll naturally figure out what your needs are and if you want something more.
Also note that in that previous thread I do have a WLA-DX NROM setup, so that you can start coding right away. That is, IF you wanted to try WLA-DX.
I don't mean to imply that there aren't solutions to make other compilers simple, and in the end it shouldn't matter what you use (as long as it isn't NESASM
).
If NESASM suits someone's needs, I don't see any problem in someone using it (there isn't any, in fact). However, it most likely ends up that the lack of features (cough cough nameless labels, 16k banks, etc.) outweigh the benefits of the assembler, making a switch desirable.
I do think though that many assemblers are a shindig to set up and just assemble something with the command line. Sometimes I like when you can just go:
Assembler.exe file.asm file.nes
instead of:
wla-6502 -o main.asm file.o
wlalink -v link.txt file.nes
Sometimes I can barely remember what that even means.
Thanks a lot guys! That's a lot of great information. I'd like to hear from the CA65 people too. If you guys don't mind chiming in, it would really help me out. And anybody else who uses one of the other assemblers too of course.
I use CA65 since my background is more higher level language like C/C++, C#, JAVA etc. It has a linker and a compiler and you can create your own make file.
Modules have the concept of public/private members which I think help to reduce bugs in programming. You don't have to worry if module is at address X because the config file will do that for you.
But since it has that much functionality, it can be a little it hard to use from the beginning. I still have a lot to learn about it.
But in the end, I don't think there is any good/bad ones since all of them will produce your nes game if you put the effort in learning it. It all come to personal taste.
P65 has been retired for awhile now, actually; it evolved into "Ophis" and doesn't require extra stuff installed. It's apparently closest to DASM in terms of expressive power, at least from the email I've received.