Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Peter Norton Programmer's Guide - Norton Guide http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]

  Service 02H (decimal 2) reads one or more cassette data blocks. Cassette
  data is transferred in standard-size 256-byte blocks, just as diskette
  data normally uses a standard 512-byte sector. The number of bytes to be
  read is placed in the CX register. Although data is placed on tape in
  256-byte blocks, any number of bytes can be read or written. Consequently,
  the number of bytes placed in the CX register need not be a multiple of
  256. The register pair ES:BX is used as a pointer to the memory area where
  the data is to be placed.

  After the service is completed, DX contains the actual number of bytes
  read, ES:BX points to the byte immediately after the last byte
  transferred, and the carry flag (CF) is set or cleared to report the
  success or failure of the operation. On failure, AH returns an error code.
  (See Figure 12-7.)

  Code               Meaning
  --------------------------------------------------------------------------
  01H                Cyclical redundancy check (CRC) error
  02H                Lost data transitions: bit signals scrambled
  04H                No data found on tape
  --------------------------------------------------------------------------

  Figure 12-7.  The error code returned by service 02H in register AH if the
  CF indicates a failure to read the data blocks.

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson