💾 Archived View for mirrors.apple2.org.za › archive › ground.icaen.uiowa.edu › MiscInfo › Hardware ›… captured on 2024-07-09 at 03:29:16.
⬅️ Previous capture (2023-01-29)
-=-=-=-=-=-=-
In article <processoroverclocked-1705002203220001@nn-157-22-180-2.napanet.net>, Jon Bettencourt <processoroverclocked@33mhz.com> wrote: >> Also, could someone enlighten me to what card would be in slot 4 with a >> Z80A CPU - the IIe works fine without the card in, and the LED doesnt >> come on on the card. > > That's a CP/M card. The LED comes on when you start using it (i.e. boot > up with a CP/M disk). If the 6502 *writes* to the address where normally the boot ROM code starts ($C400 for a CP/M card in slot 4), then the 6502 is switched off and the Z80 starts executing from Z80 address 0000h. Before doing that though, one had better load some Z80 code at that address, so the Z80 does something sensible. To switch back to 6502 mode, the Z80 must write to the same address (E400h) -- then the Z80 stops and the 6502 resumes executing. Since the 6502 is a dynamic CPU, it cannot remain idle for more than about 50 microseconds, or else it'll "forget" the contents of its internal regusters, and then you'd be in real trouble. To avoid this, the Z80 ticks at 4 Mhz for 2 cycles, then remains idle for two cycles during which the 6502 is refreshed (the 6502 is allowed to fetch one byte, but it doesn't use that byte for anything). The Z80 card contains address translation logic, to avoid having the Z80 address 0000h coincide with the 6502 address $0000. The translation works as follows: Z80 address 6502 address PSP 0000h - 0FFFh $1000 - $1FFF TPA start 1000h - 1FFFh $2000 - $2FFF 2000h - 2FFFh $3000 - $3FFF 3000h - 3FFFh $4000 - $4FFF 4000h - 4FFFh $5000 - $5FFF 5000h - 5FFFh $6000 - $6FFF 6000h - 6FFFh $7000 - $7FFF 7000h - 7FFFh $8000 - $8FFF 8000h - 8FFFh $9000 - $9FFF 9000h - 9FFFh $A000 - $AFFF A000h - AFFFh $B000 - $BFFF End of motherboard RAM B000h - BFFFh $D000 - $DFFF Start of Language Card RAM TPA end C000h - CFFFh $E000 - $EFFF BDOS/BIOS D000h - DFFFh $F000 - $FFFF End of Language Card RAM I/O area E000h - EFFFh $C000 - $CFFF I/O area F000h - F0FFh $0000 - $00FF 6502 page zero F100h - F1FFh $0100 - $01FF 6502 stack I/O drivers F200h - F3FFh $0200 - $03FF Text screen F400h - F7FFh $0400 - $07FF F800h - FFFFh $0800 - $0FFF CP/M RWTS (6502 code) This assumes a Language Card: if a Language Card is present, CP/M enables it and disables the onboard ROM's. If the Language Card is absent, the TPA is 12K smaller. Note how the Z80 ==> 6502 address translation "hides" the "hole" in the memory map due to the Apple II I/O area at $C000-$CFFF, and makes motherboard and Language Card RAM appear as one contiguous RAM area. -- ---------------------------------------------------------------- Paul Schlyter, Swedish Amateur Astronomer's Society (SAAF) Grev Turegatan 40, S-114 38 Stockholm, SWEDEN e-mail: pausch at saaf dot se or paul.schlyter at ausys dot se WWW: http://hotel04.ausys.se/pausch http://welcome.to/pausch