Developmental Flight Test Instrumentation
|
Serial driver to acquire data from a VN-200 Inertial Navigation System. More...
#include <vn200.hh>
Public Slots | |
void | readData (void) |
Slot to read in data over serial and parse complete packets. | |
![]() | |
virtual void | readData (void)=0 |
Slot to read in data over serial and parse complete packets. | |
Signals | |
void | gpsAvailable (bool flag) |
Emitted when GPS data is available. | |
void | measurementUpdate (VN200Data data) |
Emitted to share new VN200Data. | |
Public Member Functions | |
VN200 (Settings *_settings, QObject *_parent=nullptr) | |
Constructor. More... | |
![]() | |
SerialSensor (Settings *_settings, QObject *_parent=nullptr) | |
Constructor. More... | |
~SerialSensor () | |
Destructor. | |
void | configureSerial (QString _portName) |
Set the serial port parameters. More... | |
void | init () |
Initialize the serial port. | |
bool | isOpen (void) |
Returns true if the serial port is open. More... | |
virtual void | open (void) |
Opens the serial port. More... | |
void | setBaudRate (quint32 rate) |
Set the serial port baud rate. More... | |
void | threadStart (void) |
Start the sensor in a thread. | |
Public Attributes | |
const QByteArray | header {"\xfa\x01\xfa\x01"} |
VN-200 packet header bytes. More... | |
Additional Inherited Members | |
![]() | |
Settings * | settings = nullptr |
Settings object. | |
QString | portName {""} |
Serial port name. | |
QSerialPort::BaudRate | baudRate {QSerialPort::Baud115200} |
Serial port baud rate. | |
bool | _valid_serial = false |
Indicates if serial port passed validation. | |
QSerialPort * | _port = nullptr |
Serial port object. | |
Serial driver to acquire data from a VN-200 Inertial Navigation System.
Reads in data from a VectorNav VN-200 Inertial Navigation System over serial and parses the data.
The data packet format is binary, with a header consisting of
In the configuration this code assumes, Output Group 1 is selected, and the
fields are selected. The last two bytes are the checksum.
|
explicit |
Constructor.
_settings | Pointer to settings object. |
_parent | Pointer to parent QObject. |
const QByteArray dfti::VN200::header {"\xfa\x01\xfa\x01"} |
VN-200 packet header bytes.