Vector Nav 300 Driver
Note: This document is unfinished. This document will cover the initial requirements along with the design that will satisfy these requirements.
Initial Questions:
What features of VN will be used (IMU or GPS or both)?
Which IMU measurement set will we be using (2 options)?
Which GPS measurement set will we be using (4 options)?
Is there a minimum incoming data rate that needs to be met? Could this be limited by using both the IMU and GPS at the same time, alternating between the two.
Where will this driver live in the repo?
What should happen in case VN returns an error (of course will depend on the type of error)
Initial Requirements:
Will provide GPS and IMU data to other subsystems
Should this be request based? Where a subsystem requests GPS data or IMU data and the driver then fetches that data and returns it.
OR should this be “grab most recent data based”? Where the driver constantly updates some buffer or data member with the most recent IMU or GPS data and outside subsystems just grab that data.
Will package the data in a readable and easy to use structure (or class). The naming of each data member will likely be identical to the naming given in the user manual for easy reference.
Use error codes from the VN as diagnostic data
There is also possibility for a serial command prompt, used for advanced device configuration and diagnostics. Intended for human use only with a simple serial terminal.
Plan of Implementation:
Configure CubeMX to set up serial communication with VN
Create the driver in <location in repo>, the steps will include:
Create some structures or class holding the information of the VN300 (pin configs, frequently used commands, error codes)
Create driver interface
Main loop:
Establish connection (only done once I assume)
Send command for either GPS or IMU
Check for errors (error codes and CRC check)
Error handling in case of an error
Parse return data into a struct
Present data (return the data to the driver user, update a data member)
Back to step b
Test