oldMask = AbleICR( Resource, mask )
D0 A6 D0
WORD AbleICR(
struct Library *, WORD );
This function provides a means of enabling and disabling 8520 CIA interrupt control registers. In addition it returns the previous enable mask.
Get the current mask:
Enable both timer interrupts:
Disable serial port interrupt:
EXCEPTIONS
Enabling the mask for a pending interrupt will cause an
immediate processor interrupt (that is if everything else is
enabled). You may want to clear the pending interrupts with
SetICR() prior to enabling them.
The CIA resources are special in that there is more than one of them in the system. Because of this, the C language stubs in amiga.lib for the CIA resources require an extra parameter to specify which CIA resource to use. The synopsys for the amiga.lib stubs is as follows:
oldMask = AbleICR( Resource, mask ) D0 A6 D0
WORD AbleICR(
struct Library *, WORD );