Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Minor edits

...

The serial soft reset operation is carried out by opening the OS_Si call. The OS_Si call provides a low level access to the serial port. The call can perform nine different operations depending on the reason code passed to it:

No Format
Reason code    Action
SI_HRD ($00)   Hard reset the serial port
SI_SFT ($03)   Soft reset the serial port
SI_INT ($06)   Interrupt entry point (System use only).
SI_GBT ($09)   Get byte from serial port
SI_PBT ($0C)   Put byte to serial port
SI_ENQ ($0F)   Status enquiry
SI_FTX ($12)   Flush Tx (transmit) buffer
SI_FRX ($15)   Flush Rx (receive) buffer
SI_TMO ($18)   Set timeout
SI_GX  ($1B)   Get multiple bytes from serial port, using default timeout (OZ 4.5)
SI_PX  ($1E)   Put multiple bytes to serial port, using default timeout (OZ 4.5)
SI_GXT ($21)   Get multiple bytes from serial port until terminator using default timeout (OZ 4.5)

...

SI_GBT and SI_PBT are low-level interface for OS_Gbt and OS_Pbt API's. SI_GBT and SI_PBT are unstable for application level in all OZ ROM releases until V4.4. With OZ V4.4 and later, they can be used by applications directly (no need to open a handle to the serial port). The built-in Imp/Export and EazyLink popdowns now uses this interface.

This operating system call used for low level serial port communication uses the following interface, however is unstable for application-level serial port communication (SI_GBT & SI_PBT) and is mainly used by the operating system:

Code Block
languagenone
titleOS_Si, low level serial interface
RST 20H, DEFB $8D

IN:

   IX = handle returned from GN_Opf of ":COM.0"
   L = reason code
   Other register usage depends on L
 
OUT:

   Depends on reason code
   IX will always be unchanged

...