1
2
3
4
5
6
7
8
9
10
11
12
13
14 #ifndef EDSS1_H
15 #define EDSS1_H
16
17
18
19 #define ST_NULL 0
20 #define ST_CALL_INIT 1
21 #define ST_OVER_SEND 2
22 #define ST_CALL_PROC 3
23 #define ST_CALL_DELV 4
24 #define ST_CALL_PRES 6
25 #define ST_CALL_RECV 7
26 #define ST_CONN_REQ 8
27 #define ST_INCM_PROC 9
28 #define ST_ACTIVE 10
29 #define ST_DISC_REQ 11
30 #define ST_DISC_IND 12
31 #define ST_SUSP_REQ 15
32 #define ST_RESM_REQ 17
33 #define ST_RELS_REQ 19
34 #define ST_OVER_RECV 25
35
36 #define ST_ACTIVE_SELP 26
37 #define ST_ACTIVE_ACTV 27
38
39 #define MAX_STATE ST_ACTIVE_ACTV
40
41 #define EV_NULL 0
42 #define EV_USR_SETUP_REQ 1
43 #define EV_USR_SETUP_RESP 2
44 #define EV_USR_PROCED_REQ 3
45 #define EV_USR_RELEASE_REQ 4
46 #define EV_USR_REJECT_REQ 4
47
48 #define EV_NET_SETUP 16
49 #define EV_NET_CALL_PROC 17
50 #define EV_NET_SETUP_ACK 18
51 #define EV_NET_CONN 19
52 #define EV_NET_CONN_ACK 20
53
54 #define EV_NET_SELP_RESP 21
55 #define EV_NET_ACTV_RESP 22
56
57 #define EV_NET_DISC 23
58 #define EV_NET_RELEASE 24
59 #define EV_NET_RELEASE_COMP 25
60
61 #define EV_TIMER 26
62 #define EV_ERROR 32
63
64
65
66
67
68
69 #define CAUSE_NORMAL 0x10U
70 #define CAUSE_NOCHAN 0x22U
71
72 struct callb_data {
73 unsigned short type;
74 union {
75 struct ConnInfo {
76 char *CalledPN;
77 char *CallingPN;
78 } setup;
79 unsigned short cause;
80 } data;
81 };
82
83 struct fsm_entry {
84 unsigned short init;
85 unsigned short final;
86 unsigned short event;
87 void (*callb)(struct pcbit_dev *, struct pcbit_chan *, struct callb_data*);
88 };
89
90 struct fsm_timer_entry {
91 unsigned short init;
92 unsigned long timeout;
93 };
94
95
96 extern void pcbit_fsm_event(struct pcbit_dev *, struct pcbit_chan *,
97 unsigned short event, struct callb_data *);
98 #endif
99
100
101