Environs
Environs Get ROM version number and machine type #include <OSUtils.h> Operating System Utilities
short *romVer ; receives ROM version number
short *machine ; receives code identifying computer type
Environs is no longer a recommended way of obtaining information about the environment in which your code will run. Gestalt is now available as glue in development environments so that there is no need to call Environs or SysEnvirons, regardless of what machine or operating system you are running on.
Environs examines a word of ROM to obtain information about the machine on which the caller is running. Use this before executing ROM
version-dependent routines. Use Gestalt with later versions of the system. romVer is the address of an integer. Upon return, it is set to the ROM
version number.
machine is the address of an integer. Upon return, it is set to a code
identifying the type of Macintosh on which the caller is executing. It
will be one of:
macXLMachine (0) Macintosh XL
macMachine (1) Macintosh 128K, 512K, or Macintosh Plus
Notes: Environs can be used to see if you are running on the 64K or 128K ROMs. For later computers, use SysEnvirons, which returns far more information, such as the CPU type, keyboard type, and so forth.