The Interface I is quite complicated. It uses three different I/O ports, and contains logic to page and unpage an 8K ROM if new commands are used. I won't be very detailed here; you could refer to the source code of the emulator if you want to know some details, or read the 'Spectrum Shadow ROM Disassembly' by Gianlura Carri, published by Melbourne House - but don't expect the same level of detail as of Ian Logan and Frank O'Hara in their Rom disassembly book. The ROM is paged if the processor executes the instruction at ROM address 0008 or 1708 hexadecimal, the error and close# routines. It is inactivated when the Z80 executes the RET at address 0700. I/O Port E7 is used to send or receive data to and from the microdrive. Accessing this port will halt the Z80 until the Interface I has collected 8 bits from the microdrive head; therefore, it the microdrive motor isn't running, or there is no formatted cartridge in the microdrive, the Spectrum hangs. This is the famous 'IN 0 crash'. Port EF is used for several things: Bit 7 6 5 4 3 2 1 0 +---+---+----+----+-----+---+-----+-----+ READ| | | |busy| dtr |gap| sync|write| | | | | | | | |prot.| +---+---+----+----+-----+---+-----+-----+ WRITE| | |wait| cts|erase|r/w|comms|comms| | | | | | | | clk | data| +---+---+----+----+-----+---+-----+-----+ Bits DTR and CTS are used by the RS232 interface. The WAIT bit is used by the Network to synchronise, GAP, SYNC, WR_PROT, ERASE, R/_W, COMMS CLK and COMMS DATA are used by the microdrive system. If the microdrive is not being used, the COMMS DATA output selects the function of bit 0 of out-port F7: Bit 7 6 5 4 3 2 1 0 +------+---+---+---+---+---+---+-----------+ READ|txdata| | | | | | | net | | | | | | | | | input | +------+---+---+---+---+---+---+-----------+ WRITE| | | | | | | |net output/| | | | | | | | | rxdata | +------+---+---+---+---+---+---+-----------+ TXDATA and RXDATA are the input and output of the RS232 port. COMMS DATA determines whether bit 0 of F7 is output for the RS232 or the network.