;Assembler header file for OSReadSysInfo
;written by DefMod (Mar  9 1999) on Thu Apr  8 03:55:06 1999
;Jonathan Coxhead, jonathan@doves.demon.co.uk, 18 May 1995

        [       :LNOT: :DEF: Get_Types
        GBLS    Get_Types
        ]
        [       :LNOT: :DEF: Types_Hdr
Get_Types                       SETS    "GET OS:Hdr.Types"
        |
Get_Types                       SETS    ""
        ]
        $Get_Types

        [       :LNOT: :DEF: Get_OS
        GBLS    Get_OS
        ]
        [       :LNOT: :DEF: OS_Hdr
Get_OS                          SETS    "GET OS:Hdr.OS"
        |
Get_OS                          SETS    ""
        ]
        $Get_OS

        [       :LNOT: :DEF: OSReadSysInfo_Hdr
        GBLS    OSReadSysInfo_Hdr

;Symbols for constants
OSReadSysInfo_SpecialFunction   *       &FF
OSReadSysInfo_SpecialFunctionShift *       0
OSReadSysInfo_SpecialFunctionNone *       &0
OSReadSysInfo_SpecialFunctionIOEB *       &1
OSReadSysInfo_IOControl         *       &FF00
OSReadSysInfo_IOControlShift    *       8
OSReadSysInfo_IOControlIOC      *       &0
OSReadSysInfo_IOControlIOMD     *       &1
OSReadSysInfo_MemoryControl     *       &FF0000
OSReadSysInfo_MemoryControlShift *       16
OSReadSysInfo_MemoryControlMEMC1 *       &0
OSReadSysInfo_MemoryControlIOMD *       &1
OSReadSysInfo_VideoControl      *       &FF000000
OSReadSysInfo_VideoControlShift *       24
OSReadSysInfo_VideoControlVIDC1a *       &0
OSReadSysInfo_VideoControlVIDC20 *       &1
OSReadSysInfo_IO                *       &FF
OSReadSysInfo_IOShift           *       0
OSReadSysInfo_IONone            *       &0
OSReadSysInfo_IO82C710          *       &1
OSReadSysInfo_LCDControl        *       &FF
OSReadSysInfo_LCDControlShift   *       0
OSReadSysInfo_LCDControlNone    *       &0
OSReadSysInfo_LCDControlType1   *       &1

;Symbols for structure offsets and sizes
OSReadSysInfo_Flags0            *       Bits

OSReadSysInfo_Flags1            *       Bits

OSReadSysInfo_Flags2            *       Bits


;Symbols for SWIs and SWI reason codes
XOS_ReadSysInfo                 *       &20058
OS_ReadSysInfo                  *       &58

OSReadSysInfo_ScreenSize        *       &0
   ;Entry
   ;  R0 = &0
   ;Exit
   ;  R0 = screen_size (Int)

OSReadSysInfo_Mode              *       &1
   ;Entry
   ;  R0 = &1
   ;Exit
   ;  R0 = mode (OS_Mode)
   ;  R1 = monitor_type (Int)
   ;  R2 = sync (Int)

OSReadSysInfo_MachineId         *       &2
   ;Entry
   ;  R0 = &2
   ;Exit
   ;  R0 = config0 (OSReadSysInfo_Flags0)
   ;  R1 = config1 (OSReadSysInfo_Flags1)
   ;  R2 = config2 (OSReadSysInfo_Flags2)
   ;  R3 = id_lo (Bits)
   ;  R4 = id_hi (Bits)

OSReadSysInfo_71XFeatures       *       &3
   ;Entry
   ;  R0 = &3
   ;Exit
   ;  R0 = features (Bits)
   ;  R1 = features_extended0 (Bits)
   ;  R2 = features_extended1 (Bits)
   ;  R3 = features_extended2 (Bits)
   ;  R4 = features_extended3 (Bits)

        ]

        END
