Latest News
!System updates

Development tools
C/C++ Tools

Writing 32-bit code
32-bit introduction
32-bit overview
32-bit technical
Memory issues
Developer tools
Paul Skirrow's Guide (PDF)
Download area

32-bit APIs
API changes
CallASWI
FileCore

RISC OS 5
Overview
BBC BASIC
CDFS driver
OS_ClaimDeviceVector behaviour
CDFS
Draw clipping
GraphicsV
HAL
Internet
UTF8 & Japanese support
International IME support
MIMEMap
Module PostInit/Final
PCI Manager
PDumper
Podules
Resource allocation
SCSI
Service Calls
UCS fonts
USB
WIMP API Changes
WIMP Flags

IYONIX pc
DDR memory
Help system
Keyboard layout
Miscellaneous
PCI slots

Opportunities

Iyonix Ltd
IYONIX home page
Contact details

   

CDFS Driver

Document version 0.10, December 2002

Introduction

This document describes the new and updated CD API's in RISC OS 5.00.

Note that ATAPI devices, such as CD drives, are controlled using SCSI command packets sent from the host. The SCSI command packets are transported over the ATA interface instead of a SCSI bus. References to SCSI refer to the SCSI command packets and not a SCSI interface.

A useful guide to the ATAPI interface can be found at http://www.ata-atapi.com/index.htm

SWI CD_Register (SWI &41260) / CD_Unregister (SWI &41261)

Bit 21 of the information word may be set to indicate that CDFSDriver should call SWI SCSI_Op to implement SWI CD_SCSIUserOp, instead of calling the soft-loadable driver.

SWI CD_SCSIUserOp (SWI &4126B)

On entry:R0 =  bits 24-25 = 0 => no data transfer
  = 1 => read
  = 2 => write
  = 3 reserved
R1 =  length of control block
R2 ->  control block
R3 ->  buffer for data transfer
R4 =  length of transfer
R5 =  timeout in cs (0 = default)
R7 ->  CDFS control block
On exit:R3,R4  updated
R5-R9  preserved
  NZC flags corrupted
  If V set,
  R0-R2 are as for SWI SCSI_Op
  or R0 -> error not in SCSI range and R1,R2 corrupt
  Else R0-R2 preserved

CD_SCSIUserOp must not be called in the background (for compatibility with ATAPI drives).

"Soft-loadable" drivers

Entry #36 ("SCSIUserOp")

On entry:  R0  bits 24-25:
    = 0 => no data transfer
    = 1 => read
    = 2 => write
    = 3 reserved
  R1 =  length of control block
  R2 ->  control block
  R3 ->  buffer for data transfer
  R4 =  length of transfer
  R5 =  timeout in cs (0 = default)
  R7 ->  CDFS control block
  R11 =  reason code (36)
  R12 =  workspace
On exit:  R3,R4  updated
  R5-R12  may be corrupted
  NZC flags  may be corrupted
  If V set:  R0-R2 are as for SWI SCSI_Op
    or R0 -> error not in SCSI range and R1,R2 may be corrupted
  If V clear:  R0-R2 may be corrupted

© 2006 IYONIX Ltd 32-bit RISC OS