a1200   NEWS   APPS   DOCS   ABOUT
a1200
----
a1200
----
Autodocs
 Devices:
 cd.device
  CD_ADDCHANGEINT
  CD_ADDFRAMEINT
  CD_ATTENUATE
  CD_CHANGENUM
  CD_CHANGESTATE
  CD_CONFIG
  CD_EJECT
  CD_GETGEOMETRY
  CD_INFO
  CD_MOTOR
  CD_PAUSE
  CD_PLAYLSN
  CD_PLAYMSF
  CD_PLAYTRACK
  CD_PROTSTATUS
  CD_QCODELSN
  CD_QCODEMSF
  CD_READ
  CD_READXL
  CD_REMCHANGEINT
  CD_REMFRAMEINT
  CD_SEARCH
  CD_SEEK
  CD_TOCLSN
  CD_TOCMSF
  CloseDevice
  OpenDevice
Include
GuruMeditation
Docs » Autodocs » cd.device » CD_ADDFRAMEINT

NAME

       CD_ADDFRAMEINT -- add a CD-frame software interrupt handler.
IO REQUEST
io_Device preset by the call to OpenDevice()
io_Unit preset by the call to OpenDevice()
io_Command CD_ADDFRAMEINT
io_Length sizeof(struct Interrupt)
io_Data pointer to Interrupt structure

RESULT

       io_Error        0 for success, or an error code as defined in
<devices/cd.h>

FUNCTION

       This command lets you add a software interrupt handler to the
disk device that gets invoked whenever a new frame is encountered
while CD audio is being played.
You must pass in a properly initialized Exec Interrupt structure
and be prepared to deal with frame interrupts immediately.
The interrupt is generated by the exec Cause function, so you must
preserve A6.
To set up the handler, an Interrupt structure must be initialized.
This structure is supplied in io_Data of the CD_ADDFRAMEINT
command. The handler then gets linked into the handler chain and
gets invoked whenever a frame event occurs. You must eventually
remove the handler before you exit.
This command only returns when the handler is removed. That is,
the device holds onto the IO request until the CD_REMFRAMEINT command
is executed with that same IO request. Hence, you must use SendIO()
with this command.

NOTES

       The interrupt handler can be added before or after a play command is
sent. Interrupts will only be generated while CD audio is playing.
Interrupts will not be generated when audio is paused.

SEE ALSO

CD_REMFRAMEINT(), <devices/cd.h>, <exec/interrupts.h>, exec.library/Cause()

Comments

Name:
E-mail: Use this if you want a message if you get a response, will not be shown.
Comment:
Select correct short for:

Sanity

CSL
RZR
SNT
PHA

Comments:

$VER: d0.se 1.14 Copyright © 2011-2024 Tobias Geijersson support at d0 dot se