Re: ZX81 emulator "command-line edition"
Posted: Mon Mar 10, 2014 7:34 pm
Yes, environment variables cannot be set directly. The report code may perhaps be useful, which is the available as "$?" in bash:
Using ZX81 scripts (with PHP) is an interesting idea. I've added a first example on the project web page.
Currently, the "-r0" option may be used for a command-line mode with case sensitivity, and the PRINTed and INPUTed strings should match. Indeed, inverted characters are used for upper case ones. In other modes, characters should always be printed upper case.
RAMTOP is set 32 bytes lower than the maximum. The first 16 bytes provide the patch for the "str$" function as discussed before. The other 16 bytes are used for various purposes; I've put some information on this in the README.
The routines in the code are called using extended Z80 instructions, which need to be put at specific places in the ROM, so using other ROMs is not straightforward.
Code: Select all
10 let theanswer = 81
20 poke 16384, theanswer-1
30 rem not run
Currently, the "-r0" option may be used for a command-line mode with case sensitivity, and the PRINTed and INPUTed strings should match. Indeed, inverted characters are used for upper case ones. In other modes, characters should always be printed upper case.
RAMTOP is set 32 bytes lower than the maximum. The first 16 bytes provide the patch for the "str$" function as discussed before. The other 16 bytes are used for various purposes; I've put some information on this in the README.
The routines in the code are called using extended Z80 instructions, which need to be put at specific places in the ROM, so using other ROMs is not straightforward.