Topic : TOS - The Operating System Author : Version : tos.hyp (December 19, 2008) Subject : Programmieren/Atari Nodes : 3010 Index Size : 93790 HCP-Version : 5 Compiled on : Atari @charset : atarist @lang : @default : Title @help : @options : +g -i -s +x +zz -t4 @width : 70 View Ref-File12.1.11.11 atariModePossible TOS This points to a byte indicating whether a switch from the Mac to the Atari MMU-mode is possible at that instant (0=forbidden, 1=allowed). So long as the Macintosh is running without virtual memory (VM) (also without RAM-doubler), the 'modeAtari' call is always possible; however if VM is active and also the 'UnlockMemOnMacSide' flag is non-zero, then on switching from the MagiC to the Mac screen the memory occupied by MM (MagiC Mac) for the TPA will be released for offloading. However, as soon as the VM management offloads a block, the MMU tables calculated by MM are no longer valid and must be calculated anew prior to the next switch to the Atari-mode. This is not done automatically, however, but only when switching back to the Atari screen. For this reason interrupt and other asynchronous routines that are installed under MagiC Mac by MacOS functions may not perform Atari-mode switches under the described circumstances. Atari programs that hook into the Atari vectors (e.g. the VBL vector at $70) need not take all of this into account, since in cases when the MMU tables become invalid the Atari interrupts will not even be simulated any more. In cases where one should take further measures before or after the status of the flags alters one can install also a routine via macAppSwitch that then indicates this event with the values 3 and 4 in d0.W). See also: Program launch and TPA The MagiC Mac cookie