EricBall Posted October 18, 2005 Share Posted October 18, 2005 Does anyone know of a tool (DOS, Windows, or C++ source) which will reformat 6502 ASM for consistency? For Leprechaun, I've got chunks of code which I've done at different times & I haven't been consistent with my use of upper & lower case. I'd like to be able to run my source through a filter which will reformat everything. I'm thinking stuff like opcodes as lower case, equate labels as upper case, address labels as lower etc. Quote Link to comment Share on other sites More sharing options...
fox Posted October 26, 2005 Share Posted October 26, 2005 There's a Perl script in cc65 that pretty prints 6502 code (and ca65 directives) in HTML. I don't know if it can change formatting or just adds HTML markup. Quote Link to comment Share on other sites More sharing options...
djmips Posted November 12, 2005 Share Posted November 12, 2005 Did you find something? I saw that Beautifer supports some asm types. Quote Link to comment Share on other sites More sharing options...
EricBall Posted November 13, 2005 Author Share Posted November 13, 2005 Did you find something? I saw that Beautifer supports some asm types.964063[/snapback] Nope, didn't find anything, and haven't had the time to create something myself. I also found that I had some semi-contradictory desires on how to handle different labels. (Important, because labels are case sensitive in DASM.) Quote Link to comment Share on other sites More sharing options...
brpocock Posted January 18, 2006 Share Posted January 18, 2006 Did you find something? I saw that Beautifer supports some asm types.964063[/snapback] Nope, didn't find anything, and haven't had the time to create something myself. I also found that I had some semi-contradictory desires on how to handle different labels. (Important, because labels are case sensitive in DASM.) 964844[/snapback] Did you decide on a method or find an utility? -- Be kind to wizards or you shall be replaced with a very small Perl script. Quote Link to comment Share on other sites More sharing options...
+SpiceWare Posted January 22, 2006 Share Posted January 22, 2006 Anything? Inquiring minds want to know I'm documenting Warlords in preparation for hacking it and I'd like to Pretty Print it when I'm done. Quote Link to comment Share on other sites More sharing options...
Schmutzpuppe Posted March 19, 2006 Share Posted March 19, 2006 Here is a little tool that let you format your source. Not very sophisticated but it's a first try. I tested it with some DASM source code and it worked quite well but I am don't use macros or special pseudo op's. You can add instructions or pseudo op's in the corresponding txt files. Just give it a try and let me know what you think. One more note, you need the .NET framework 1.1 to let it run. 6502Formatter.zip Quote Link to comment Share on other sites More sharing options...
+nanochess Posted November 4, 2017 Share Posted November 4, 2017 I've wrote a pretty printer for 6502 assembler code, Aardvark was a mess of tabs and spaces, so I needed something to make it uniform. I hope it's also useful for someone else. REMEMBER: DON'T APPLY IT OVER YOUR ORIGINAL SOURCE CODE, MAKE A BACKUP FIRST!!! (it could have hidden bugs) https://github.com/nanochess/pretty6502 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.