Help me pick an assembler!
- Sheep64
- In Memoriam
- Posts: 311
- Joined: 11 Aug 2020
- Location: A magnetic field
Re: Help me pick an assembler!
Greg816v2 on Thu 31 Mar 2022 wrote:
- Preprocessor directives like #include, #define, #ifdef, etc
Re: Help me pick an assembler!
Maybe I'm late but there still is xa65. Includes preprocessor statements. Lacks macros but those can be defined with #define.
Anonymous labels are there in my dev branch, maybe you can help me convince Cameron Kaiser to include them
Oh, and xa comes with ubuntu Linux
André
Anonymous labels are there in my dev branch, maybe you can help me convince Cameron Kaiser to include them
Oh, and xa comes with ubuntu Linux
André
Author of the GeckOS multitasking operating system, the usb65 stack, designer of the Micro-PET and many more 6502 content: http://6502.org/users/andre/
Re: Help me pick an assembler!
Having said that, in my personal style I'm still using #ifdef, but not defining constants with the preprocessor anymore. I'm using normal labels instead and have the benefit of scoping (yes xa has scopes defined with .( and .) )
Author of the GeckOS multitasking operating system, the usb65 stack, designer of the Micro-PET and many more 6502 content: http://6502.org/users/andre/
Re: Help me pick an assembler!
I've liked using xa. Local labels were very effective and allowed me to easily define modules with public and private symbols, as well as short range jump targets without needing unique names. It was also easy to export a symbol table for my OS so that programs loaded later from SD card could be built against it.
I need to try ca65 sometime though as I'm sure it can also do all of this too. It's on my bucket list.
I need to try ca65 sometime though as I'm sure it can also do all of this too. It's on my bucket list.
Re: Help me pick an assembler!
I think only xa65 and ca65 have the capability to produce relocatable o65 files. I.e. relocatable once on load. I know it's an edge case ...
Author of the GeckOS multitasking operating system, the usb65 stack, designer of the Micro-PET and many more 6502 content: http://6502.org/users/andre/
Re: Help me pick an assembler!
Greg816v2 wrote:
I've been using ACME to write code for a 6502 board, and as the project grows I'm running into more issues with how ACME works (such as very odd behavior when separating the project into different files). I'm trying to look at all the assemblers out there but I just feel like I'm missing something.
Hoping for the following:
- Support for 65C02 and 65816
- Runs on/can be compiled on Linux
- Uses as standard syntax as possible
- Preprocessor directives like #include, #define, #ifdef, etc
- Anonymous labels (i.e. +/-). After using this in ACME I don't think I can do without it.
- The option to generate an output binary that includes a block of address space assembled to. I.e. for an EEPROM, I have code at $8000 and vectors at $FFFA..$FFFF and the output is a 32K binary.
Every assembler I come across is lacking one of these, but I'm sure they exist, so... what are y'all using
Hoping for the following:
- Support for 65C02 and 65816
- Runs on/can be compiled on Linux
- Uses as standard syntax as possible
- Preprocessor directives like #include, #define, #ifdef, etc
- Anonymous labels (i.e. +/-). After using this in ACME I don't think I can do without it.
- The option to generate an output binary that includes a block of address space assembled to. I.e. for an EEPROM, I have code at $8000 and vectors at $FFFA..$FFFF and the output is a 32K binary.
Every assembler I come across is lacking one of these, but I'm sure they exist, so... what are y'all using
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: Help me pick an assembler!
vbc wrote:
FYI, Frank just added support for 65816 to vasm. You may want to have a look at the latest daily snapshot at http://sun.hasenbraten.de/vasm
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
Re: Help me pick an assembler!
GARTHWILSON wrote:
vbc wrote:
FYI, Frank just added support for 65816 to vasm. You may want to have a look at the latest daily snapshot at http://sun.hasenbraten.de/vasm
Re: Help me pick an assembler!
Hi.
Can you help me also, please?
I'm starting to compile some code with the CCA65's CA65. When I compile it without MAcros, all is working ok. But if I use macros the macros don't be compiled (but the process don't give error.
Can you help me also, please?
I'm starting to compile some code with the CCA65's CA65. When I compile it without MAcros, all is working ok. But if I use macros the macros don't be compiled (but the process don't give error.
- BigDumbDinosaur
- Posts: 9426
- Joined: 28 May 2009
- Location: Midwestern USA (JB Pritzker’s dystopia)
- Contact:
Re: Help me pick an assembler!
6502user wrote:
Hi.
Can you help me also, please?
I'm starting to compile some code with the CCA65's CA65. When I compile it without MAcros, all is working ok. But if I use macros the macros don't be compiled (but the process don't give error.
Can you help me also, please?
I'm starting to compile some code with the CCA65's CA65. When I compile it without MAcros, all is working ok. But if I use macros the macros don't be compiled (but the process don't give error.
Are you compiling C code, or are you assembling? Compiling and assembling are two different things.
x86? We ain't got no x86. We don't NEED no stinking x86!
Re: Help me pick an assembler!
can you post some example code and the commands you use to assemble?
Re: Help me pick an assembler!
A listing output from a small example would be helpful too.
Re: Help me pick an assembler!
6502user wrote:
Hi.
Can you help me also, please?
I'm starting to compile some code with the CCA65's CA65. When I compile it without MAcros, all is working ok. But if I use macros the macros don't be compiled (but the process don't give error.
Can you help me also, please?
I'm starting to compile some code with the CCA65's CA65. When I compile it without MAcros, all is working ok. But if I use macros the macros don't be compiled (but the process don't give error.
Then you should see the macro expansion - however note that ca66 will only show the bytes gnerated and not the actual assembler macro expansion..
Here is an example of a macro definition:
Code: Select all
.macro waitBaud
.local loop
ldy sBaud
loop: dey
bne loop
.endmacroCode: Select all
; Delay 1 bit time
waitBaudAnd this is what it looks like in the listing file:
Code: Select all
00005Br 1 ; Delay 1 bit time
00005Br 1
00005Br 1 A4 rr 88 D0 waitBaud
00005Fr 1 FD Code: Select all
ldy $EA
L109C: dey
bne L109CHope that helps.
-Gordon
--
Gordon Henderson.
See my Ruby 6502 and 65816 SBC projects here: https://projects.drogon.net/ruby/
Gordon Henderson.
See my Ruby 6502 and 65816 SBC projects here: https://projects.drogon.net/ruby/
Re: Help me pick an assembler!
drogon wrote:
You need .....
Here is an example of a macro definition: .....and what it looks like in the code:.....
Hope that helps. Gordon
Here is an example of a macro definition: .....and what it looks like in the code:.....
Hope that helps. Gordon
That helped me. Thanks.
Last edited by 6502user on Sat Jan 13, 2024 11:29 am, edited 2 times in total.