sepseel wrote:
However, when i try to assemble the code from:
https://github.com/jefftranter/6502/blob/master/asm/SpeakJet/demo1.s I get an error telling me this: ERROR E017: Missing constant value (number, label, function or '*'). ROW 18
What is this telling me ?
The Kowalski assembler doesn't precisely adhere to the official MOS Technology assembly language syntax, which is definitive for the 6502 family. In the Kowalski simulator's assembler, radices are as follows:
Code:
@ binary
$ hexadecimal
If no radix is present the number is assumed to be decimal. The instruction at line 18, which is
lda #%00011110, is using a binary operand whose format is not understood by the assembler. In order fix this error you would write the same instruction as
lda #@00011110.
One other note: the Kowalski simulator understands the 6502 and Rockwell 65C02 instruction sets, but not the entire instruction set of the Western Design Center 65C02, the latter which is the prototype for the 65C02. In practice, this isn't likely to cause you any problems, but you should be aware of it. So as to make it clear to the simulator which processor you are using, place the following statement at the very beginning of your source code:
Code:
.opt proc65c02,caseinsensitive
The above tells the simulator you are using a 65C02, and also that labels, symbols, operands and mnemonics are case-insensitive. If you are simulating the NMOS 6502 change the above statement accordingly. The simulator will then consider 65C02-specific instructions, such as
BRA and
TSB, as undefined.