source: trunk/MagicSoft/Cosy/candrv/sdolist.h@ 3210

Last change on this file since 3210 was 2518, checked in by tbretz, 21 years ago
*** empty log message ***
File size: 898 bytes
Line 
1#ifndef COSY_SdoList
2#define COSY_SdoList
3
4#ifdef __CINT__
5typedef Byte_t BYTE_t;
6typedef UShort_t WORD_t;
7#else
8#include <TROOT.h>
9#include "gendef.h"
10#endif
11
12#ifndef ROOT_TMutex
13#include <TMutex.h>
14#endif
15
16class PendingSDO
17{
18public:
19 BYTE_t Node;
20 WORD_t Idx;
21 BYTE_t Subidx;
22 PendingSDO *Next;
23
24 PendingSDO(BYTE_t n=0, WORD_t i=0, BYTE_t s=0)
25 : Node(n), Idx(i), Subidx(s), Next(NULL) {}
26
27 ClassDef(PendingSDO, 0)
28};
29
30class PendingSDOList
31{
32private:
33 PendingSDO *fFirst;
34 PendingSDO *fLast;
35
36 TMutex fMux;
37
38public:
39 PendingSDOList();
40 virtual ~PendingSDOList();
41
42 void Add(BYTE_t node, WORD_t idx, BYTE_t subidx);
43 void Del(BYTE_t node, WORD_t idx, BYTE_t subidx);
44 void DelAll();
45
46 int IsPending() const;
47 int IsPending(BYTE_t node);
48 int IsPending(BYTE_t node, WORD_t idx, BYTE_t subidx);
49
50 ClassDef(PendingSDOList, 0)
51};
52
53#endif
Note: See TracBrowser for help on using the repository browser.