David Empson wrote: > $E00400 - $E007FF Text screen 1 (main memory) > $E00800 - $E00BFF Text screen 2 (main memory) > $E02000 - $E03FFF Hi-res screen 1 (main memory) > $E04000 - $E05FFF Hi-res screen 2 (main memory) > $E10400 - $E107FF Text screen 1 (aux memory) > $E10800 - $E10BFF Text screen 2 (aux memory) > $E12000 - $E13FFF Hi-res screen 1 (aux memory) > $E14000 - $E15FFF Hi-res screen 2 (aux memory) > $E12000 - $E19FFF Super hi-res screen I wanted to explain the video memory areas in more detail, but forgot before posting. The real video buffers are in banks $E0 and $E1, but the IIgs has a shadowing feature which provides a write-through duplication of the video buffers into the same locations in banks 0 and 1. There are several enable bits for different combinations of screens, which are usually set as appropriate by the operating environment. For example, while in GS/OS, the text screen and possibly the super hi-res screens are shadowed, but not text page 2 or the hi-res screen (this allows these memory areas to be used for other purposes in banks 0 and 1). Under ProDOS-8, text page 1 and the hi-res pages are shadowed, but not the super hi-res page. Text page 2 is special. In the original IIgs (256KB/ROM 1) there is no hardware shadowing support for this area, so Apple implemented a Classic Desk Accessory called "Alternate Display Mode", which uses a timer interrupt to regularly copy the contents of $000800-$000BFF to the corresponding region in bank 0. (If you don't enable this CDA, you get a screen full of "2" characters when displaying text page 2.) This has a significant performance hit. In the 1MB/ROM 3 IIgs, Apple added a hardware shadowing bit for text page 2, and the "Alternate Display Mode" CDA simply toggles this bit, eliminating the performance hit. One other detail I neglected to mention is "fast" versus "slow" RAM. The RAM area implemented by the Mega II (banks $E0 and $E1) operates at exactly the same speed as a IIe: 1.023 MHz. The memory is shared between the CPU and video in exactly the same way as 8-bit machines. This is "slow" RAM. If the IIgs is running in "fast" mode, it has to slow down for one cycle to access RAM in this bank. RAM banks $00 through $7F are implemented by the Fast Processor Interface (FPI). There are no video buffers in this area, and the CPU can access this "fast" RAM at the system speed (either "fast" or "slow" as appropriate). The "fast" speed is 2.8 MHz. There is a minor catch: the "fast" RAM has to be refreshed. If the CPU tries to access fast RAM during a refresh cycle, it has to wait until the refresh is complete. This slows down "fast" RAM access to about 2.6 MHz on average. ROM can be accessed at full speed: 2.8 MHz. This is one reason why the ROM 3 IIgs has better native desktop graphics performance than the ROM 1 - the drawing toolset (QuickDraw II) is in ROM. The I/O space ($C000-$CFFF) is mostly accessed in "slow" mode, no matter which bank it is referenced from. There are a couple of exceptions: the speed and shadow registers are implemented by the FPI chip, and can be accessed in fast mode. (This is pretty minor.) Another issue relating to this is a forced slowdown while a Disk ][ controller or equivalent (including the built-in Disk Port) in slots 4 through 7 has the 5.25" drive motor enabled. The system remains in slow mode until the drive motor is disabled again, so that 5.25" disk access timing works correctly. (This isn't an issue for 3.5" disks.) For this reason, you should never use a 5.25" disk controller in slot 1, 2 or 3 in a IIgs (no hardware support to slow down). The card will work if the control panel is set to "Slow" mode, but that is no fun. Shadowing throws another spanner in the works. If the appropriate shadowing is enabled, a write to a shadow video buffer in banks 0 and 1 requires a simultaneous write into bank $E0 or $E1, so the system must slow down to 1 MHz for the cycle. A read from the shadow video buffer can operate at "fast" speed. -- David Empson dempson@actrix.gen.nz Snail mail: P O Box 27-103, Wellington, New Zealand