|
The System Configuration Interface On Toshiba Laptops
Jonathan Buzzard jonathan@buzzard.org.uk
April 1999 Version 0.2
DISCLAIMER: The information in this document has been obtained by reverse engineering the software
supplied by Toshiba for their portable computers in strict accordance with the European Council Directive
91/250/ECC on the legal of computer programs and it’s implementation into English Law by the Copyright
(Computer Programs) Regulations 1992 (S.I. 1992 No. 3233). As such it is likely to be incomplete and
comes with no warranties as to it’s accuracy.
1 Overview
The System Configuration Interface (SCI) is a software
interface that allows applications to read or
setup configurations on Toshiba portable computers.
It aims to conceal differences in hardware between
different models from the software.
The System Configuration Interface is implemented
using the System Management Mode
(SMM) of the Intel processor. To call the SCI the
necessary registers are loaded with the values to indicate
what function we wish to ask and a value is
then read from port B2h. On reading from port B2h
the SMM mode of the processor is enabled, whatever
function requested is carried out and execution
of the software
The calls to the SCI can take place at any time
and in whatever mode the processor happens to be
in at the time i.e. real, protected, virtual8086 etc.
While a call to the SCI is in progress all other functions
of the processor are queued pending completion
of the call. This includes all maskable and nonmaskable
interrupts.
2 General
With the SCI the calling software can check whether
SCI is implemented or not on a target machine.
Read the current configuration, and/or set a new
configuration. They can also set the default configuration.
The caller must first open the interface to
the SCI before reading or setting the current configuration
and close the interface after it has finished.
This enables the caller to ensure it has exclusive access
to the SCI, as when the interface is open further
request to open the interface will fail.
When the reading the current configuration, you
can also get all possible configurations on the target
system, if it is possible to change the configuration
and whether any change will require a reboot before
it takes effect.
3 Interface
Reading a byte from port B2h into the AL register
activates the interface. The function that is then executed
depends on the value held in the AX register,
according to the following list.
F000h Support Check
F100h Open Interface
F200h Close Interface
F300h Get System Configuration
F400h Set System Configuration
F500h Set Default Configuration
3.1 Support Check
This function allows the caller to determine if the
system’s BIOS supports the SCI functionality and if
so which version is supported.
Call:
AX = F000h
Return successful:
CF = 0
AX = 0044h
DH = major version number
DL = minor version number
Return unsuccessful:
CF = 1
AH = 86h - SCI not present
1
3.2 Open Interface
This function opens the SCI interface and allows the
calling program to start getting and setting the system
configuration. If another program has already
opened the SCI interface this function will return
with the carry flag set and ah=81h. To ensure that
software has exclusive access to the SCI programs
should halt at this point. After this function has been
called, the Close, Get, Set and Default SCI calls are
activated.
Call:
AX = F100h
Return successful:
CF = 0
AX = 0044h
Return unsuccessful:
CF = 1
AH = 81h - Interface already opened
86h - SCI not present
3.3 Close Interface
When a program has finished getting or setting the
system configuration it should call this function.
Until the interface has been closed other programs
will be unable to open the SCI and will be locked
out. After this function has been called, the Close,
Get, Set and Default SCI calls are disabled.
Call:
AX = F200h
Return successful:
CF = 0
AX = 0044h
Return unsuccessful:
CF = 1
AH = 82h - Interface not opened
86h - SCI not present
3.4 Get System Configuration
This returns the current system configuration information.
The configuration required is selected by
placing the configuration code in the BX register.
Due to the nature by which this document was compiled
it is unlikely that all possible configuration
codes are covered.
The attribute returned in AL shows extra information
of specified function, such as indicating
whether or not modification of system configuration
is valid only after system reboot. The data type returned
in BX defines the format of data stored in
current setting in CX register and possible settings
in DX register. The possible settings shows the
range of valid settings on the target machine. The
SI register holds the factory default for configuration,
and the value it will be set to if the Default SCI
call is made.
Call:
AX = F300h
BX = configuration code
Return successful:
CF = 0
AH = 00h
AL = attribute
BX = data type
CX = current setting
DX = possible settings
SI = default setting
Return unsuccessful:
CF = 1
AH = 80h - Function not supported
82h - Interface not opened yet
86h - SCI not present
8Eh - Device not installed
3.5 Set System Configuration
This function sets a new system configuration. The
new configuration is selected by placing the configuration
code in the BX register, and the setting in the
CX register. Due to the nature by which this document
was compiled it is unlikely that all possible
configuration codes are covered. The attribute returned
in AL indicates if whether the system needs
rebooting before the new configuration takes effect.
Call:
AX = F400h
BX = configuration code
CX = new configuration to be set
Return successful:
CF = 0
AH = 00h
AL = attribute
BX = data type
CX = current setting
DX = possible settings
SI = default setting
Return unsuccessful:
CF = 1
AH = 80h - Function not supported
82h - Interface not opened yet
83h - Input data error
84h - Write Protect error
86h - SCI not present
8Eh - Device not installed
2
3.6 Set Default Configurations
This function sets all system configuration parameters
to their default values and updates the CMOS.
There is no way to set individual configurations to
their default values.
Call:
AX = F500h
Return successful:
CF = 0
AH = 00h
AL = 01h
Return unsuccessful:
CF = 1
AH = 82h - Interface not opened
86h - SCI not present
4 Data Types
5 Configuration Codes
5.1 Power-Up Mode
This setting controls the the power up mode of
the computer is boot or suspend/resume (Case 1).
On models that support hibernation it also controls
whether the power up mode is Hibernation or Quick
Hibernation (Case 2).
Get
Call:
BX = 0100h
Return successful Case 1:
CF = 0
AH = 00h
BX = 0000h - Binary data type
CX = 0000h - Boot mode
0001h - Resume mode
SI = default setting
Return successful Case 2:
CF = 0
AH = 00h
BX = 8009h - Power up mode type
CX = 0000h - Boot mode
0001h - Resume mode
0002h - Hibernation mode
0003h - Quick Hibernation mode
SI = default setting
Return unsuccessful:
CF = 1
AH =80h - Function not supported
82h - Interface not opened
86h - SCI not present
Set
Call:
BX = 0100h
CX = 0000h - Boot mode
0001h - Resume mode
0002h - Hibernation mode
0003h - Quick Hibernation mode
Return successful:
CF = 0
AH = 00h
Return unsuccessful:
CF = 1
AH = 80h - Function not supported
82h - Interface not opened
83h - Input data error
86h - SCI not present
5.2 Alarm Power On (Date)
5.3 Alarm Power On (Time)
This function controls the time of the alarm power
on function. If the system supports Disable and Enable
(hh:mm) it returns DX=0FFFh. When setting
the time it updates the CMOS checksum after storing
the new configuration in the CMOS RAM
Get
Call:
BX = 010Fh
Return successful:
CF = 0
AH = 00h
BX = 8004h - Time data type
CX = the current mode
DX = possible modes
SI = default setting
Return unsuccessful:
CF = 1
AH =80h - Function not supported
82h - Interface not opened
86h - SCI not present
Set
Call:
BX = 012Dh
CX = new configuration
Return successful:
CF = 0
AH = 00h
3
Return unsuccessful:
CF = 1
AH = 80h - Function not supported
82h - Interface not opened
83h - Input data error
86h - SCI not present
5.4 Hibernation Mode
This setting controls whether the hibernation mode
is enabled or disabled.
Get
Call:
BX = 012Dh
Return successful:
CF = 0
AH = 00h
BX = 0000h - Binary data type
CX = 0000h - Disabled
0001h - Enabled
SI = default setting
Return unsuccessful:
CF = 1
AH =80h - Function not supported
82h - Interface not opened
86h - SCI not present
Set
Call:
BX = 012Dh
CX = 0000h - Disable
0001h - Enable
Return successful:
CF = 0
AH = 00h
Return unsuccessful:
CF = 1
AH = 80h - Function not supported
82h - Interface not opened
83h - Input data error
86h - SCI not present |
|