|
blah2
A real-time passive radar
|
A class to store IQ data. More...
#include <IqData.h>

Public Member Functions | |
| IqData (uint32_t n) | |
| Constructor. More... | |
| uint32_t | get_n () |
| Getter for maximum number of samples. More... | |
| uint32_t | get_length () |
| Getter for current data length. More... | |
| void | lock () |
| Locker for mutex. More... | |
| void | unlock () |
| Unlocker for mutex. More... | |
| std::deque< std::complex< double > > | get_data () |
| Getter for data. More... | |
| void | push_back (std::complex< double > sample) |
| Push a sample to the queue. More... | |
| std::complex< double > | pop_front () |
| Pop the front of the queue. More... | |
| void | print () |
| Print to stdout (debug). More... | |
| void | clear () |
| Clear samples from the queue. More... | |
| void | update_spectrum (std::vector< std::complex< double >> spectrum) |
| Update the time differences and names. More... | |
| void | update_frequency (std::vector< double > frequency) |
| Update the time differences and names. More... | |
| std::string | to_json (uint64_t timestamp) |
| Generate JSON of the signal and metadata. More... | |
Private Attributes | |
| uint32_t | n |
| Maximum number of samples. More... | |
| std::mutex | mutex_lock |
| True if should not push to buffer (mutex). More... | |
| std::deque< std::complex< double > > * | data |
| Pointer to IQ data. More... | |
| double | min |
| Minimum value. More... | |
| double | max |
| Maximum value. More... | |
| double | mean |
| Mean value. More... | |
| std::vector< std::complex< double > > | spectrum |
| Spectrum vector. More... | |
| std::vector< double > | frequency |
| Frequency vector (Hz). More... | |
A class to store IQ data.
Implements a FIFO queue to store IQ samples.
| IqData::IqData | ( | uint32_t | n | ) |
Constructor.
| n | Number of samples. |
| void IqData::clear | ( | ) |
Clear samples from the queue.
| std::deque< std::complex< double > > IqData::get_data | ( | ) |
Getter for data.
| uint32_t IqData::get_length | ( | ) |
Getter for current data length.
| uint32_t IqData::get_n | ( | ) |
Getter for maximum number of samples.
| void IqData::lock | ( | ) |
Locker for mutex.
| std::complex< double > IqData::pop_front | ( | ) |
Pop the front of the queue.
| void IqData::print | ( | ) |
Print to stdout (debug).
| void IqData::push_back | ( | std::complex< double > | sample | ) |
Push a sample to the queue.
| sample | A single sample. |
| std::string IqData::to_json | ( | uint64_t | timestamp | ) |
Generate JSON of the signal and metadata.
| timestamp | Current time (POSIX ms). |
| void IqData::unlock | ( | ) |
Unlocker for mutex.
| void IqData::update_frequency | ( | std::vector< double > | frequency | ) |
Update the time differences and names.
| frequency | Frequency vector. |
| void IqData::update_spectrum | ( | std::vector< std::complex< double >> | spectrum | ) |
Update the time differences and names.
| spectrum | Spectrum vector. |
|
private |
Pointer to IQ data.
|
private |
Frequency vector (Hz).
|
private |
Maximum value.
|
private |
Mean value.
|
private |
Minimum value.
|
private |
True if should not push to buffer (mutex).
|
private |
Maximum number of samples.
|
private |
Spectrum vector.