RflySimSDK v3.05
RflySimSDK说明文档
载入中...
搜索中...
未找到
vrpn_ADBox.h
1// -*- Mode:C++ -*-
2
3/*
4 * ad-box driver
5 * works with Fraunhofer IMK AD-Box and Fakespace Cubic Mouse
6 *
7 * for additional information see:
8 * http://www.imk.fraunhofer.de
9 * http://www.fakespace.com
10 *
11 * written by Sascha Scholz <sascha.scholz@imk.fraunhofer.de>
12 */
13
14#ifndef VRPN_ADBOX_H
15#define VRPN_ADBOX_H
16
17#include "vrpn_Analog.h" // for vrpn_Analog
18#include "vrpn_Button.h" // for VRPN_BUTTON_BUF_SIZE, etc
19#include "vrpn_Configure.h" // for VRPN_API
20#include "vrpn_Shared.h" // for timeval
21
22class VRPN_API vrpn_Connection;
23
24class VRPN_API vrpn_ADBox : public vrpn_Analog, public vrpn_Button_Filter {
25
26 public:
27 vrpn_ADBox(char* name, vrpn_Connection *c,
28 const char *port="/dev/ttyS1/", long baud=9600);
29
31
32 void mainloop();
33
34 private:
35 int ready;
36
37 struct timeval timestamp; // time of the last report from the device
38
39 int serial_fd;
40 unsigned char buffer[VRPN_BUTTON_BUF_SIZE];
41
42 int iNumBytes;
43 int iNumDigBytes;
44 int iFilter[8][30];
45 int iFilterPos;
46};
47
48#endif // #ifndef VRPN_ADBOX
定义 vrpn_ADBox.h:24
void mainloop()
定义 vrpn_Analog.h:28
定义 vrpn_Button.h:66
Generic connection class not specific to the transport mechanism.
定义 vrpn_Connection.h:562