jAsm Logo

"If you'll take thunder and lightning, and a steamboat and a buzz-saw, and mix 'em up, and put 'em into a woman, that's jAsm"

Zapac citing Josiah Gilbert Holland

The Assembler

This is the official home for the 6502 and Z80 assembler jAsm. jAsm was written by me, Jonas Hultén, during 7 months in 2015. It is heavily geared towards C64 development, since that's what it's intended to be used for. It currently runs on the 64-bit Linux and Windows platforms but it should be fairly easy to port it to other platforms since it has no dependencies except the standard C++ library.

The Documentation

Have a look at the documentation.

The Binaries

Windows binaries requires the C++ Redistributable for VS2015 to be installed.

The Source

As a tribute to Matthew Dillon, who created DAsm and released the source code to the public, I am releasing the source code to jAsm as well. I have used DAsm for many years and I have made smaller adjustments to suit my needs over the years. That wouldn't have been possible without access to the source code. I am very grateful and I am giving back to the community by releasing the source for free.

The source code is available on BitBucket at https://bitbucket.org/bjonte/jasm.

Version History

  • 1.13
    • The Z80 instructions adc, add, sbc and sub has mirrored addressing modes to support both immediate value and a register or only the immediate value.
    • An unstable variable state is considered an error now.
  • 1.12
    • Fixed setting word registers to negative values in Z80.
    • Fixed a parsing bug in Z80 indirect addressing mode instructions.
  • 1.11
    • Changed operator precendence so that &, | and ^ has higher priority than compare operators. This basically abandons the C-style precendence and adopts the Rust one.
    • Added a warning for a code path passing through the end of a subroutine.
    • Fixed a serious bug where local and global constants or variables with the same name could be mixed up in the root scope.
  • 1.10
    • Stderr is no longer used
    • Select function like ternary if
    • Modulo and remainder functions
    • Multi bank mode truncates word arguments and definitions
  • 1.9
    • Macro function support
  • 1.8
    • List support
    • Range-based for loop
    • Fixed cases where constant could be modified
  • 1.7
    • Z80 support
    • C-style multiline comments
    • Removed the -hraw argument. This is now default.
  • 1.6
    • Tailing comma allowed in enum definitions
    • Ellipsis can be used in data definitions to create repeated patterns
    • Fill byte can be specified when aligning memory
    • Incbin takes optional arguments for start offset and max size
  • 1.5
    • Module import variables
  • 1.4
    • Dynamically generated symbol names
    • Print function
    • Fixed a serious precedence and associativity bug in the expression evaluation
  • 1.3
    • Modules
    • Macro call stack in error messages
  • 1.2
    • Generic predeclared symbols
    • Macro code can use local variables surrounding the macro code
  • 1.1
    • Section parts
    • Section part mappings
    • Syntax highlighting for Sublime Text 3
    • Local subroutines
    • Reservation of zero sized arrays
  • 1.0
    • Initial release