StRoot
1
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Groups
Pages
RTS
include
RC
RC_MsgDefs.h
1
#ifndef RC_MSGDEFS_HH
2
#define RC_MSGDEFS_HH
3
// These structures define the message parameters for communication
4
// with the DAQ RC handler.
5
6
// The message structure contains
7
// Words 1..3 ICCP header
8
// Words 4... Specific parameters for each command
9
//
10
// The structures in this file are only the specific parameters
11
// Most of these are inherited from MsgParam which contain a
12
// param type which should be filled with one of the values below
13
#include "rc.h"
14
15
#ifdef DEFINE_ONLINE
16
typedef
int
bool;
17
#endif
18
19
#include <sys/types.h>
20
#include <iccp.h>
21
22
#define RCMSGSIZE 120
23
#define RCDATASIZE RCMSGSIZE-sizeof(ic_msg_head)
24
25
// Supporting enums
26
enum
connect_direction {to_handler, from_handler};
27
//enum query_type {all=0, inrun=1, none=2};
28
enum
mask_types {literal=1, bits_on=2, bits_off=3};
29
30
//----------------------------------------
31
// Here are the DAQ message structures....
32
//
33
34
// handler --> handler
35
struct
rc_daq_connect
// Used to be ConnectorParam
36
{
// I will separate to DAQ_CONNECT / DAQ_CHASER_CONNECT
37
// In all connections
38
u_int fd;
39
u_int addr;
40
int
connection_seq;
// sequence number for the connection
41
int
port;
// The port connect
42
};
43
44
struct
rc_daq_error
// Used to be ErrorParam
45
{
46
int
error;
47
int
level;
48
};
49
#define PORTS_USED 1
50
51
52
// handler --> rc
53
struct
rc_cmd_response
54
{
55
int
cheese;
56
int
cid;
57
};
58
struct
rc_drc_send_error
59
{
60
char
text[RCDATASIZE];
61
};
62
63
// rc --> handler
64
struct
rc_drc_connect
65
{
66
int
pid;
// connectors pid
67
connect_direction direction;
68
};
69
struct
rc_cmd_nop
{ uint dummy; };
//
70
struct
rc_drc_ping
{ uint dummy; };
//
71
struct
rc_drc_stophandler
{ uint dummy; };
//
72
struct
rc_drc_clear_handler
//
73
{
74
int
state;
75
};
76
struct
rc_drc_querysystem
//
77
{
78
int
system;
79
int
crates;
80
int
threads;
81
int
status;
82
int
is_caller_cheese;
83
bool
client_threads;
84
bool
ping;
85
};
86
struct
rc_cmd_timeout
{ uint dummy; };
//
87
struct
rc_drc_reconfig
{ uint dummy; };
//
88
struct
rc_drc_add_component
89
{
90
char
daqpath[8];
91
int
in_run;
92
int
rb_mask;
93
mask_types rb_mask_type;
94
};
95
struct
rc_cmd_reboot
{ uint all; };
96
struct
rc_drc_run_start
97
{
98
int
run_number;
99
int
num_triggers;
100
};
101
struct
rc_drc_run_stop
102
{
103
int
run_number;
104
int
junk;
105
};
106
struct
rc_drc_run_pause
107
{
108
int
run_number;
109
};
110
struct
rc_drc_run_resume
111
{
112
int
run_number;
113
int
num_triggers;
114
};
115
struct
rc_drc_set_config
116
{
117
int
seq;
118
int
length;
119
};
120
struct
rc_drc_get_config
121
{
122
int
seq;
123
};
124
struct
rc_drc_send_config
125
{
126
int
dummy;
127
};
128
struct
rc_drc_set_busy
129
{
130
int
run_number;
131
};
132
struct
rc_drc_release_busy
133
{
134
int
run_number;
135
};
136
struct
rc_drc_flush_tokens
137
{
138
int
run_number;
139
int
type;
140
};
141
struct
rc_drc_query_tokens
142
{
143
int
num_tokens;
144
};
145
struct
rc_drc_get_systems
146
{
147
int
seq;
148
int
print;
149
int
all;
150
};
151
struct
rc_drc_get_threads
152
{
153
int
seq;
154
int
all;
155
};
156
struct
rc_drc_get_errors
157
{
158
int
size;
159
};
160
struct
rc_drc_clear_errors
161
{
162
int
dummy;
163
};
164
struct
rc_drc_update_query
165
{
166
int
dummy;
167
};
168
169
enum
cc_command_value { kill_client };
170
struct
rc_drc_client_control
171
{
172
cc_command_value cc_command;
173
int
cid;
174
};
175
176
struct
rc_drc_reconnect
177
{
178
int
addr;
179
int
port;
180
int
system;
181
};
182
183
struct
rc_rts_reconnect
184
{
185
int
addr;
186
int
port;
187
};
188
189
// system --> Handler
190
struct
rc_cmd_ack
{ uint dummy; };
191
struct
rc_cmd_ping
{ uint dummy; };
192
struct
rc_daq_run_start
{
193
uint run_number;
194
int
num_triggers;
195
};
196
197
struct
rc_daq_run_stop
198
{
199
int
run_number;
200
int
num_files;
201
int
num_events;
202
int
junk;
203
};
204
205
struct
rc_daq_run_pause
{ uint run_number; };
206
struct
rc_daq_run_resume
207
{
208
uint run_number;
209
int
num_triggers;
210
};
211
struct
rc_daq_send_config
212
{
213
u_int port;
214
u_int handler_id;
215
};
216
struct
rc_daq_set_busy
{ uint run_number; };
217
struct
rc_daq_release_busy
{ uint run_number; };
218
struct
rc_daq_flush_tokens
{ uint run_number; };
219
struct
rc_daq_query_tokens
220
{
221
uint num_tokens;
222
uint state;
223
uint
rb
[12];
224
};
225
struct
rc_mz_emul_fiber
226
{
227
uint ntriggers;
228
};
229
230
struct
rc_drc_monitor_send
231
{
232
int
gb_tokens_run;
233
int
bb_tokens_run;
234
int
rcc_clock;
235
char
file_name[20];
236
};
237
238
#endif
239
240
241
242
243
244
245
246
247
248
rc_drc_clear_errors
Definition:
RC_MsgDefs.h:160
rc_drc_connect
Definition:
RC_MsgDefs.h:64
rc_daq_release_busy
Definition:
RC_MsgDefs.h:217
rc_drc_add_component
Definition:
RC_MsgDefs.h:88
rc_drc_set_config
Definition:
RC_MsgDefs.h:115
rc_cmd_reboot
Definition:
RC_MsgDefs.h:95
rc_drc_monitor_send
Definition:
RC_MsgDefs.h:230
rc_daq_run_resume
Definition:
RC_MsgDefs.h:206
rc_daq_error
Definition:
RC_MsgDefs.h:44
rc_daq_run_pause
Definition:
RC_MsgDefs.h:205
rc_drc_get_systems
Definition:
RC_MsgDefs.h:145
rc_drc_update_query
Definition:
RC_MsgDefs.h:164
rc_drc_run_pause
Definition:
RC_MsgDefs.h:106
rc_drc_clear_handler
Definition:
RC_MsgDefs.h:72
rc_drc_query_tokens
Definition:
RC_MsgDefs.h:141
rc_drc_run_resume
Definition:
RC_MsgDefs.h:110
rc_drc_querysystem
Definition:
RC_MsgDefs.h:76
rc_drc_client_control
Definition:
RC_MsgDefs.h:170
rc_drc_send_config
Definition:
RC_MsgDefs.h:124
rb
Definition:
rb.hh:21
rc_cmd_timeout
Definition:
RC_MsgDefs.h:86
rc_daq_send_config
Definition:
RC_MsgDefs.h:211
rc_drc_ping
Definition:
RC_MsgDefs.h:70
rc_drc_run_start
Definition:
RC_MsgDefs.h:96
rc_daq_flush_tokens
Definition:
RC_MsgDefs.h:218
rc_drc_release_busy
Definition:
RC_MsgDefs.h:132
rc_drc_send_error
Definition:
RC_MsgDefs.h:58
rc_cmd_nop
Definition:
RC_MsgDefs.h:69
rc_drc_run_stop
Definition:
RC_MsgDefs.h:101
rc_daq_run_start
Definition:
RC_MsgDefs.h:192
rc_mz_emul_fiber
Definition:
RC_MsgDefs.h:225
rc_drc_stophandler
Definition:
RC_MsgDefs.h:71
rc_drc_get_errors
Definition:
RC_MsgDefs.h:156
rc_cmd_response
Definition:
RC_MsgDefs.h:53
rc_drc_reconnect
Definition:
RC_MsgDefs.h:176
rc_daq_set_busy
Definition:
RC_MsgDefs.h:216
rc_daq_connect
Definition:
RC_MsgDefs.h:35
rc_daq_run_stop
Definition:
RC_MsgDefs.h:197
rc_drc_get_threads
Definition:
RC_MsgDefs.h:151
rc_drc_reconfig
Definition:
RC_MsgDefs.h:87
rc_daq_query_tokens
Definition:
RC_MsgDefs.h:219
rc_drc_get_config
Definition:
RC_MsgDefs.h:120
rc_cmd_ack
Definition:
RC_MsgDefs.h:190
rc_rts_reconnect
Definition:
RC_MsgDefs.h:183
rc_drc_set_busy
Definition:
RC_MsgDefs.h:128
rc_cmd_ping
Definition:
RC_MsgDefs.h:191
rc_drc_flush_tokens
Definition:
RC_MsgDefs.h:136
Generated by
1.8.5