Main Page
Classes
Files
File List
File Members
include
leptrino
rs_comm.h
Go to the documentation of this file.
1
// =============================================================================
2
// RS232C 用モジュール
3
//
4
// Filename: rs_comm.h
5
//
6
// =============================================================================
7
// Ver 1.0.0 2012/11/01
8
// =============================================================================
9
#include "
pCommon.h
"
10
11
// =============================================================================
12
// マクロ定義
13
// =============================================================================
14
#ifndef _RSCOMM_H
15
#define _RSCOMM_H
16
17
#define PAR_NON 0
18
#define PAR_ODD 1
19
#define PAR_EVEN 2
20
21
#define BIT_LEN_7 7
22
#define BIT_LEN_8 8
23
24
#define CHR_STX 0x02
25
#define CHR_ETX 0x03
26
#define CHR_EOT 0x04
27
#define CHR_ENQ 0x05
28
#define CHR_ACK 0x06
29
#define CHR_LF 0x0A
30
#define CHR_CR 0x0D
31
#define CHR_DLE 0x10
32
#define CHR_NAK 0x15
33
#define CHR_SUB 0x1A
34
35
int
Comm_Open
(
const
char
* dev);
//デバイスオープン
36
void
Comm_Close
(
void
);
//デバイスクローズ
37
void
Comm_Setup
(
long
baud,
int
parity,
int
bitlen,
int
rts,
int
dtr,
char
code);
//ポート設定
38
int
Comm_SendData
(
UCHAR
*buff,
int
l);
39
int
Comm_CheckRcv
(
void
);
//受信有無確認
40
int
Comm_GetRcvData
(
UCHAR
*buff);
//受信データ取得
41
void
Comm_Rcv
(
void
);
42
43
#endif
Comm_CheckRcv
int Comm_CheckRcv(void)
Definition:
rs_comm.cpp:233
Comm_Close
void Comm_Close(void)
Definition:
rs_comm.cpp:66
UCHAR
unsigned char UCHAR
Definition:
pCommon.h:11
Comm_Open
int Comm_Open(const char *dev)
Definition:
rs_comm.cpp:45
Comm_GetRcvData
int Comm_GetRcvData(UCHAR *buff)
Definition:
rs_comm.cpp:210
pCommon.h
Comm_SendData
int Comm_SendData(UCHAR *buff, int l)
Definition:
rs_comm.cpp:192
Comm_Rcv
void Comm_Rcv(void)
Definition:
rs_comm.cpp:246
Comm_Setup
void Comm_Setup(long baud, int parity, int bitlen, int rts, int dtr, char code)
Definition:
rs_comm.cpp:87
leptrino_force_torque
Author(s):
autogenerated on Sun Oct 6 2019 03:45:38