
MUST select Z80EMU+HARD32/PIO or load IO Map - IMSAI.IOM 

New IO map file (IMSAI.iom) will do most of the work for you. IT will set the right IO Map and the right CPU.

The IMSAI MIO board at 0-3 is used for all. The serial port is 
mapped to DEV-0. It does not matter how the Status register I/O properties 
for DEV 0 are set. The MIO board returns fixed format/values.

NOTE - the underlying ports for the MIO can be changed via the menu Configure IO Devices

The parallel ports are mapped to DEV-8 and DEV-9. Again fixed values.

The Cassette Interface is permanently mapped to ACR. Again fixed values.

The IMSAI stuff seems to work fine with instruction set 8080 or Z80

(find manuals at www.unix4fun.org)


Use IO Map IMSAI.IOM for all.

======

To run Self Contained Monitor

(MUST USE ALL CAPS)

set io Properties for DEV-0 7-bit p=0 

============

To run Imsai 4k, 8K OR 9K basic 

set io Properties for DEV-0 7-bit p=0  

IMPORTANT-MUST TYPE "NEW" BEFORE DOING ANYTHING 

DATA CORRUPTION CAN OCCUR IF YOU FORGET TO TYPE "NEW"

Load memory (bank 0) with BASIC8Kgood.hex or BASIC9Kgood.hex or BASIC4k.hex
Then GOTO 0 in bank 0
 (the "good" means the typos are fixed)

(The CBASIC9K.COM is the 9k basic assembled to run on CPM. It uses CPM's I/O)

NOTES

IF Z80EMU+Hard32/PIO is selected, No Need for an IO map because all programs use the MIO board at 0-3

Should use IMSAI.IOM..only required ports are there, + tarbell sdfdc

The MIO board exists in the Z80EMU+hard32 (not in the Z80SIM Ports or the combined Ports)

(MUST USE ALL CAPS) (remember to type "NEW")

To make IMSAI 9k basic, you need to edit the 8k basic file and re-assemble.
 
 Change "LARGE equ 0" to "LARGE equ 1"

 Also, there are two typographical errors in the Source file, 
	probably made when the Basic source code was transcribed 
	from the original paper manual.

   Following the Label RECI1 you must add "INX  D" 
                    between the "STAX  D" and the "CALL  CKSUM"

 RECI1: CALL    CASI    ;INPUT BYTE
        STAX    D       ;STORE IT
        INX     D	;Add this line
        CALL    CKSUM   ;UPDATE CKSUM, PUT ADDR IN LIGHTS

   Following Label NOTCO, you must change "JNZ NOTCH" to "JNZ NOTBS"

 NOTCO:  CPI     7FH     ;TEST IF RUBOUT
         JNZ     NOTBS   ;BRIF NOT	(change this line)
         LDA     TAPES   ;GET PAPER TAPE SW

The ABOVE changes make the file match the manual.

HOWEVER to fix a bug in the CPM 9k version you must also add an ORA A immediately after CALL BTSTAT

        ; PUSH AND POP IF FOUND TO CREATE BUGS.
        CALL    BTSTAT  ;CALL BIOS
	ORA     A
        RZ              ;RETURN ON NO CHAR

ALL THE ABOVE CHANGES HAVE ALREADY BEEN MADE TO THE SOURCE INCLUDED.

HINTS

If you have a basic program in a file and want to put on Cassette,
 Open in a text editor. 
 Copy text of program. (try to copy <32k at a time)
 Paste As Input to Basics IO console. 
 CSAVE to Cassette Tape.

If you type in a basic program and want to save to file, 
 LIST.(on a DEV-TTY NOT a CRT) (can use IMSAI SAVE) (chunks <25000 characters)
 Copy Text of program (use right click menu, NOT cntrl-C).
 Save in file.  

NOTE  IMSAI SAVE= Paper Tape Save; TAPE= Paper Tape Load)
use Z80 Emu ports only

Note... Program on Cassette is "Z"