MRPT  1.9.9
cmtscan.h
Go to the documentation of this file.
1 /* +------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | http://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2018, Individual contributors, see AUTHORS file |
6  | See: http://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See details in http://www.mrpt.org/License |
8  +------------------------------------------------------------------------+ */
9 
10 #ifndef _SCANPORTS_H_2006_06_09
11 #define _SCANPORTS_H_2006_06_09
12 
13 #ifndef _CMT_MONOLITHIC
14 #include "xsens_list.hpp"
15 #endif
16 
17 namespace xsens
18 {
19 /*! \brief Scan COM ports for connected Xsens devices.
20 
21  The cmtScanPorts function will scan registered Xsens USB converters and
22  serial COM ports
23  for connected Xsens devices. If the baudrate parameter is 0 (default), it
24  will try to
25  connect at all supported baud rates, starting with the most common 115k2,
26  460k8 and
27  58k6. If the baudrate parameter is non-zero, only the specified baudrate is
28  tried.
29  Any detected devices are returned in the ports list, which is sorted by port
30  nr.
31 
32 */
33 bool cmtScanPorts(
34  List<CmtPortInfo>& ports, uint32_t baudrate = 0,
35  uint32_t singleScanTimeout = 1000, uint32_t scanTries = 1);
36 
37 /*! \brief Scan a single COM port for connected Xsens devices.
38 
39  The cmtScanPort function will scan a single port for connected Xsens
40  devices. If the
41  baudrate parameter is 0 (default), it will try to connect at all supported
42  baud
43  rates, starting with the most common 115k2, 460k8 and 58k6. If the baudrate
44  parameter
45  is non-zero, only the specified baud rate is tried. Any detected devices are
46  returned
47  in the portInfo parameter.
48 
49 */
50 bool cmtScanPort(
51  CmtPortInfo& portInfo, uint32_t baudrate = 0,
52  uint32_t singleScanTimeout = 1000, uint32_t scanTries = 1);
53 
54 //! Set to true from another thread to abort any scan currently in progress.
55 extern bool abortScan;
56 
57 } // end of xsens namespace
58 
59 #endif // _SCANPORTS_H_2006_06_09
bool abortScan
Set to true from another thread to abort any scan currently in progress.
Definition: cmtscan.cpp:58
Structure for storing information about a serial port.
Definition: cmtdef.h:1168
bool cmtScanPort(CmtPortInfo &portInfo, uint32_t baud, uint32_t singleScanTimeout, uint32_t scanTries)
Scan a single COM port for connected Xsens devices.
Definition: cmtscan.cpp:60
The namespace of all Xsens software since 2006.
Definition: cmt1.cpp:95
bool cmtScanPorts(List< CmtPortInfo > &ports, uint32_t baudrate, uint32_t singleScanTimeout, uint32_t scanTries)
Scan COM ports for connected Xsens devices.
Definition: cmtscan.cpp:133
unsigned __int32 uint32_t
Definition: rptypes.h:47



Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 7d5e6d718 Fri Aug 24 01:51:28 2018 +0200 at lun nov 2 08:35:50 CET 2020