osSetEventMesg.3p
2.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
.TH osSetEventMesg 3P local "Silicon Graphics, Inc."
.SH NAME
.upperok
osSetEventMesg \- associate a message queue and message with an event
.SH SYNOPSIS
.nf
\f3
.Op c
#include <ultra64.h>
.sp .8v
void osSetEventMesg(OSEvent e, OSMesgQueue *mq, OSMesg m);
.Op
\f1
.fi
.SH DESCRIPTION
The
.I osSetEventMesg
associates a message queue and a message with an event,
which usually corresponds to an interrupt or an exception of some kind.
When an event occurs, the message registered with
.I osSetEventMesg
is sent to the associated message queue.
The message sending is of the non-blocking form;
if the message queue is full the message will be dropped.
.PP
The following events are supported:
.TP 10
.B OS_EVENT_SW1
CPU software interrupt 1;
although supported by the CPU,
this is not expected to be widely used.
.TP
.B OS_EVENT_SW2
CPU software interrupt 2;
not expected to be widely used.
.TP
.B OS_EVENT_CART
Indy has written to GIO bus register;
intended for use by
.I rmon.
.TP
.B OS_EVENT_COUNTER
CPU COUNT register has reached COMPARE value;
intended for use by the VI/Timer manager.
.TP
.B OS_EVENT_SP
Signal Processor (SP) interrupt;
intended for application use to indicate SP task completion.
.TP
.B OS_EVENT_SI
Serial Interface (SI) interrupt;
intended for application use to indicate controller input is available.
.TP
.B OS_EVENT_AI
Audio Interface (AI) interrupt;
intended for application use to indicate audio buffer has been consumed.
.TP
.B OS_EVENT_VI
Video Interface (VI) interrupt;
intended for application use to indicate vertical retrace.
.TP
.B OS_EVENT_PI
Parallel Interface (PI) interrupt to indicate DMA done;
intended for use by the PI manager.
.TP
.B OS_EVENT_DP
Display Processor (DP) interrupt triggered by DP FullSync command;
intended for application use to indicate end of display processing.
.TP
.B OS_EVENT_PRENMI
An NMI has been requested and will occur in 0.5 seconds;
intended for application use to begin graceful shutdown.
.TP
.B OS_EVENT_CPU_BREAK
The CPU has hit a breakpoint;
intended for use by
.I rmon.
.TP
.B OS_EVENT_SP_BREAK
The SP has hit a breakpoint;
intended for use by
.I rmon.
.TP
.B OS_EVENT_FAULT
The CPU has encountered an unrecoverable exception;
intended for use by
.I rmon.
.TP
.B OS_EVENT_THREADSTATUS
A thread has been created or destroyed;
intended for use by
.I rmon.
.SH "SEE ALSO"
.IR osCreateMesgQueue (3P),
.IR osSendMesg (3P),
.IR osSpTaskLoad (3P),
.IR osContInit (3P),
.IR osAiSetNextBuffer (3P),
.IR osViSetEvent (3P),
.IR osPiStartDma (3P),
.IR osDpSetNextBuffer (3P)