forked from sPHENIX-Collaboration/rcdaq
-
Notifications
You must be signed in to change notification settings - Fork 0
/
daq_device.cc
63 lines (42 loc) · 922 Bytes
/
daq_device.cc
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
// device_i.cc
/* This defines the device class.
* This module inherits
* its fsm from the activecomponent class
* Its static implementation is inherited from the component class
*
* created June 9,1997
*
* author:
*
* module = %M% date = %D% Version = %I%
* modifications:
* none
*/
#include <iostream>
#include "daq_device.h"
daq_device::daq_device()
{
}
daq_device::~daq_device()
{
}
int daq_device::formatPacketHdr(int * adr)
{
packetdata_ptr sevt = (packetdata_ptr) adr;
sevt->sub_length = 6;
// sevt->hdrversion = 1;
// sevt->hdrlength = 6;
// sevt->status = 0;
sevt->hdrinfo = 0x01060000;
sevt->sub_id =0;
sevt->debug_length =0;
sevt->error_length =0;
// sevt->structure =0;
// sevt->numDescWds =1;
// sevt->endianism=2;
// sevt->sub_padding=0;
sevt->structureinfo = 0x00010200;
sevt->sub_type =4;
sevt->sub_decoding =0;
return 0;
}