-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheth.h
More file actions
66 lines (55 loc) · 1.23 KB
/
eth.h
File metadata and controls
66 lines (55 loc) · 1.23 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
/*******************************************************************
*
* DESCRIPTION: Atomic Model Ethernet
*
* AUTHOR: Ariel Gonzalez
*
* EMAIL: mailto://egonzalz@dc.uba.ar
* mailto://agonzalez@tecnet-ibermatica.com.ar
*
* DATE: 26/9/2003
*
*******************************************************************/
#ifndef __ETH_H
#define __ETH_H
#include "atomic.h" // class Atomic
#include "datos.h" // tipos de datos y conversiones
#define MAX_DATALINKS 20
class Ethernet : public Atomic
{
public:
Ethernet( const string &name = "Ethernet" ); //Default constructor
virtual string className() const ;
protected:
Model &initFunction();
Model &externalFunction( const ExternalMessage & );
Model &internalFunction( const InternalMessage & );
Model &outputFunction( const InternalMessage & );
private:
const Port &in1;
const Port &in2;
const Port &in3;
const Port &inhabilitar;
const Port &habilitar;
Port &out1;
Port &out2;
Port &out3;
// parametros
Time delay;
int nodo_1;
int nodo_2;
int nodo_3;
// variables de estado
int hab1;
int hab2;
int hab3;
int hay_pedido;
Value pedido;
}; // class Ethernet
// ** inline ** //
inline
string Ethernet::className() const
{
return "Ethernet" ;
}
#endif //__ETH_H