File: IRproto.h

package info (click to toggle)
canna 3.7p3-13
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 8,220 kB
  • ctags: 9,776
  • sloc: ansic: 85,928; sh: 2,777; yacc: 403; cpp: 389; lex: 379; makefile: 74; awk: 7
file content (165 lines) | stat: -rw-r--r-- 3,485 bytes parent folder | download | duplicates (10)
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
/* Copyright 1992 NEC Corporation, Tokyo, Japan.
 *
 * Permission to use, copy, modify, distribute and sell this software
 * and its documentation for any purpose is hereby granted without
 * fee, provided that the above copyright notice appear in all copies
 * and that both that copyright notice and this permission notice
 * appear in supporting documentation, and that the name of NEC
 * Corporation not be used in advertising or publicity pertaining to
 * distribution of the software without specific, written prior
 * permission.  NEC Corporation makes no representations about the
 * suitability of this software for any purpose.  It is provided "as
 * is" without express or implied warranty.
 *
 * NEC CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN 
 * NO EVENT SHALL NEC CORPORATION BE LIABLE FOR ANY SPECIAL, INDIRECT OR
 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF 
 * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR 
 * OTHER TORTUOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 
 * PERFORMANCE OF THIS SOFTWARE. 
 */

/* @(#) NEC UNIX( PC-UX/EWS-UX ) IRproto.h 2.1 91/10/17 13:40:04 */
/* $Id: IRproto.h,v 1.1.1.1 2002/10/19 08:27:53 aida_s Exp $ */

#define RETURN_VERSION_ERROR_STAT   -2

#define OWNER		"bin"
#define EXIT		999

typedef struct _Req0{
    int Type ;
} Req0 ;

typedef struct _Req1{
    int Type ;
    int context ;
} Req1 ;

typedef struct _Req2{		
    int Type ;
    int namelen ;
    char *name ;
} Req2 ;

typedef struct _Req3{
    int Type ;
    int context ;
    int number ;
} Req3 ;

typedef struct _Req4{
    int Type ;
    int context ;
    int number ;
    int *kouho ;
} Req4 ;

typedef struct _Req5{
    int Type ;
    int context ;
    int number ;
    int datalen ;
} Req5 ;

typedef struct _Req6{
    int Type ;
    int context ;
    int mode ;
    int datalen ;
    char *data ;
} Req6 ;

typedef struct _Req7{
    int Type ;
    int context ;
    int diclen ;
    char *dicname ;
    int datalen ;
    char *datainfo ;
} Req7 ;

typedef struct _Req8{
    int Type ;
    int context ;
    int datalen ;
    char *data ;
    int mode ;
 } Req8 ;

typedef struct _Req9{
    int Type ;
    int context ;
    int number ;
    int datalen ;
    char *data ;
} Req9 ;

typedef struct _Req10{
    int Type ;
    int context ;
    int diclen ;
    char *dicname ;
    int textdiclen ;
    char *textdicname ;
    int mode ;
} Req10 ;

typedef struct _Req11{
    int Type ;
    int context ;
    int number ;
    int kouho ;
    int max ;
} Req11 ;

typedef struct _Req12{
    int Type ;
    int datalen ;
    char *data ;
    int number ;
} Req12 ;

typedef union _IRReq {
    Req0 Request0 ;
    Req1 Request1 ;
    Req2 Request2 ;
    Req3 Request3 ;
    Req4 Request4 ;
    Req5 Request5 ;
    Req6 Request6 ;
    Req7 Request7 ;
    Req8 Request8 ;
    Req9 Request9 ;
    Req10 Request10;
    Req11 Request11;
    Req12 Request12;
    BYTE Buffer[4];
} IRReq ;

#define     ACK_BUFSIZE   2048

typedef struct _Ack0 {
    int stat ;
} Ack0 ;

typedef struct _Ack1 {
    int stat ;
    int len ;
    char data[ ACK_BUFSIZE ] ;
} Ack1 ;

typedef struct _Ack2 {
    int stat ;
    int len ;
    int info[ ACK_BUFSIZE/sizeof( int ) ] ;
} Ack2 ;

typedef union _IRAck {
    Ack0 Anck0 ;
    Ack1 Anck1 ;
    Ack2 Anck2 ;

    char SendAckBuffer[ ACK_BUFSIZE + sizeof( int )*2 ] ;
} IRAck ;