Go to the documentation of this file.
62 std::string
port{
"/tty/USB0"};
105 explicit Driver(
bool _debug =
false);
bool connected_
True if we're connected to the localization unit.
int DecodeUtmFix(utm_fix *, an_packet_t *)
The current api given by kvh incorrectly deals with this packet so we needed to write our own decoder...
bool reversingDetectionEnabled
int RequestPacket(packet_id_e)
This function is used to request packets that you only want once or that cannot be requested through ...
std::vector< std::pair< packet_id_e, uint16_t > > KvhPacketRequest
Helper functions for configuring the hardware.
const uint32_t PACKET_PERIOD
equal packet frequency. See manual for equation on how Packet Period affects packet rate.
bool atmosphericAltitudeEnabled
int SendPacket(an_packet_t *)
Wrapper function for more easily sending an packets via serial port.
bool velocityHeadingEnabled
Driver worker class for the KVH Geo Fog 3D.
global variables used to store packet information.
KvhInitOptions defaultOptions_
If no init options are passed in, use this as the default.
bool debug_
Set true to print debug statements.
KvhPacketStorage packetStorage_
Class responsible for handling packets and ensuring consistency.
an_decoder_t anDecoder_
Decoder for decoding incoming AN encoded packets.
int AddPacket(packet_id_e)
~Driver()
Destructor. Will automatically cleanup the driver.
double odometerVelocityCovariance
uint8_t filterVehicleType
std::vector< packet_id_e > packetRequests_
KVH Packet storing class header.
bool PacketIsUpdated(packet_id_e)
Use this function to determine if new packet data has arrived since the last time you checked.
Driver(bool _debug=false)
Initializes connected status, port to use, and if debug printing is turned on.
int DecodePacket(an_packet_t *)
int GetPacket(packet_id_e _packetId, T &_packet)
Retrieves the requested packets that are currently stored. Use PacketIsUpdated and SetPacketUpdated t...
int GetPacket(packet_id_e _packetId, T &_packet)
int Once()
Do a single data read from the device.
int Cleanup()
Cleanup and close our connections.
int SetPacketUpdated(packet_id_e, bool)
Use this function to set that the packet has been updated (though the driver will usually do that its...
bool motionAnalysisEnabled
int Init(const std::string &_port, KvhPacketRequest &_packetsRequested)
KvhDeviceConfig deviceConfig_
Class responsible for configuring kvh geo fog.
std::string port_
Port to connect to the kvh through. Ex. "/dev/ttyUSB0".