メインページ
関連ページ
データ構造
ファイル
例
ファイル一覧
グローバル
全て
データ構造
ファイル
関数
変数
型定義
列挙型
列挙型の値
ページ
include
urg_connection.h
説明を見る。
1
#ifndef URG_CONNECTION_H
2
#define URG_CONNECTION_H
3
13
#ifdef __cplusplus
14
extern
"C"
{
15
#endif
16
17
#include "
urg_serial.h
"
18
#include "
urg_tcpclient.h
"
19
20
24
enum
{
25
URG_CONNECTION_TIMEOUT
= -1,
26
};
27
28
32
typedef
enum
{
33
URG_SERIAL
,
34
URG_ETHERNET
,
35
}
urg_connection_type_t
;
36
37
41
typedef
struct
42
{
43
urg_connection_type_t
type
;
44
urg_serial_t
serial
;
45
urg_tcpclient_t
tcpclient
;
46
}
urg_connection_t
;
47
48
90
extern
int
connection_open
(
urg_connection_t
*connection,
91
urg_connection_type_t
connection_type,
92
const
char
*device,
long
baudrate_or_port);
93
94
107
extern
void
connection_close
(
urg_connection_t
*connection);
108
109
111
extern
int
connection_set_baudrate
(
urg_connection_t
*connection,
long
baudrate);
112
113
132
extern
int
connection_write
(
urg_connection_t
*connection,
133
const
char
*data,
int
size);
134
135
164
extern
int
connection_read
(
urg_connection_t
*connection,
165
char
*data,
int
max_size,
int
timeout);
166
167
189
extern
int
connection_readline
(
urg_connection_t
*connection,
190
char
*data,
int
max_size,
int
timeout);
191
192
#ifdef __cplusplus
193
}
194
#endif
195
196
#endif
/* !URG_CONNECTION_H */
Thu May 2 2013 10:55:17に生成されました。
1.8.3.1