* * USING THE TASM CROSS ASSEMBLER * *
The TASM cross assembler (Windows CLI application) can be used for various CPU. It can be downloaded from here. The on-line manual is here.
Using the TASM cross assembler it is possible setup a toolchain to program the Z80-MBC2, doing all the development on a PC and uploading the code with the serial port and then executing it on the target Z80-MBC2 with iLoad.
After the download of the TASM zip file, unzip it into your working directory (it is the folder where your assembler source files are stored) and to assemble an user source give the command:
tasm -s -h -c -g0 -80 <Your_source.asm> out.hex
It will be created the out.hex file (Intel-hex formatted executable file).
Now you can upload and execute out.hex using the iLoad boot mode of the Z80-MBC2.
Remember that iLoad will take the first address of the Intel-Hex stream as the starting address of the program, and after the loading will jump to it.
At this point you can follow the same steps to create an automated toolchain described in the paragraph "SDCC: SETTING UP AN AUTOMATED TOOLCHAIN (WINDOWS)".
TASM: USING AUTOBOOT
If you want create a binary file to use with the Autoboot boot mode you can generate it with the command:
tasm -s -h -c -g3 -80 <Your_source.asm> out.bin
It will be created a flat binary file out.bin. Then rename out.bin as autoboot.bin and copy it into the root of the SD used by the Z80-MBC2.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.