Skip to content

A C++ telemetry parser that processes SpaceX launch data to extract the horizontal and vertical velocity. DSP techniques are used to filter the data.

License

Notifications You must be signed in to change notification settings

caojohnny/telem-filter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

telem-filter

A C++ telemetry parser that processes SpaceX launch data to extract the horizontal and vertical velocity. DSP techniques are used to filter the data.

This project is very similar to my other project, caojohnny/liftoff and even uses the same data. However, this project takes a slightly different approach and is not as comprehensive. Rather than simulating physical dynamics, telem-filter parses data and attempts to derive the horizontal and vertical velocity components verbatim from the data rather than using curve fitting.

The data is processed in a 3 step manner: in the first step, the altitude telemetry is interpolated and the initial horizontal and vertical velocities are extracted by "pitching" over when the velocity is greater than that needed to reach the current altitude. In the second step, this data is then passed through a Parks-McClellan low-pass filter with a cutoff-frequency of 1 Hz. In the final step, the filtered velocities are then adjusted to account for velocity error by absorbing the error into the horizontal velocity.

While this produces a surprisingly good result, this is inferior to curve fitting because anything beyond the derivative of position is not accounted for. It is clear from the velocity plots that the acceleration and jerk will not be realistic (will be much higher than in the real- world). However, with further processing and curve-fitting used in caojohnny/liftoff, this data can be salvaged into very good data.

Disclaimer

This is a toy. This is not meant to be functional code. It exists because I thought it would be fun demo code to show that some idea I had somewhat works. It is not meant to be deployed to production.

Demo

filtered-adjusted.png

Building

Prerequisites

This project requires MathGL development headers to be installed on your system with PThreads and FLTK enabled.

Build Commands

git clone https://github.com/caojohnny/telem-plotter
cd telem-plotter

mkdir build && cd build
cmake .. && make

cd ..
./build/telem_filter

MATLAB

I have included along with the C++ code some MATLAB code that I used to prototype the low-pass filter. This is not used in the C++ program, but is here for documentation purposes.

Documentation

This project is extensively documented. The HTML version of the documentation comments can be generated by running Doxygen in the root folder of this project:

doxygen

This produces the output in the doc directory. You can open the doc/html/index.html file in your preferred web browser to view it.

Credits

Built with CLion

Utilizes:

About

A C++ telemetry parser that processes SpaceX launch data to extract the horizontal and vertical velocity. DSP techniques are used to filter the data.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published