LD A,00H
OUT0 (FFH),A
Then say
IN0 E0H (an S100 port in that range)
or
OUT0 E1H
Then return to the old setup
LD A,C0H
OUT0 (3FH),A
...
One quick question however right now.Many S100 bus board ports reside in the 00-3FH range. In order to address them I was thinking of shifting the Z180 internal ports block to C0-FFH with:-LD A,0C0H ;relocate I/O register to 0xC0OUT0 (3FH),AHowever the are some important S100 bus ports also in the C0-FFH range so I was thinking that to use them I would temporary move the block back. Something like:-
...
...
An out0 will generate the external bus cycle as well so unfortunately
you can't just move the Z180 I/O space up and down to dodge whichever
port you need to use because your writes will also be seen by external
devices.
...
...
From a practical perspective though you either build a tiny bit of
logic that knows where the internal I/O will be placed, or you just
use an internally controlled signal (it has to be internal - eg RTS or
something) and or it with IORQ. One gate of a 74HCT32 but a tiny bit
of software complexity as you have to turn on external I/O use the reg
and turn it back. Much like a Z280.
...
Alan