Go to the source code of this file.
◆ HEURISTICS_SIZE
| #define HEURISTICS_SIZE 200 |
◆ contribute_to_heuristics()
This method contributes valuable information from dibits whose value we are confident is correct. We take the dibits and corresponding analog signal values to model the Gaussians for each dibit (and previous dibit if enabled).
- Parameters
-
| rf_mod | Indicates the modulation used. The previous dibit is only used on C4FM. |
| heuristics | Pointer to the P25Heuristics module with all the needed state information. |
| analog_signal_array | Sequence of AnalogSignal which contain the cleared dibits and analog values. |
| count | number of cleared dibits passed (= number of elements to use from analog_signal_array). |
◆ estimate_symbol()
| int estimate_symbol |
( |
int | rf_mod, |
|
|
P25Heuristics * | heuristics, |
|
|
int | previous_dibit, |
|
|
int | analog_value, |
|
|
int * | dibit ) |
Important method that estimates the most likely symbol for a given analog signal value and previous dibit. This is called by the digitizer.
- Parameters
-
| rf_mod | Indicates the modulation used. The previous dibit is only used on C4FM. |
| heuristics | Pointer to the P25Heuristics module with all the needed state information. |
| previous_dibit | The previous dibit. |
| analog_value | The signal's analog value we want to interpret as a dibit. |
| dibit | Address were to store the estimated dibit. |
- Returns
- A boolean set to true if we are able to estimate a dibit. The reason why we might not be able to estimate it is because we don't have enough information to model the Gaussians (not enough data has been passed to contribute_to_heuristics).
◆ get_P25_BER_estimate()
Returns the estimate for the BER (bit error rate).
- Returns
- The estimated BER. This is just the percentage of errors over the processed bits.
◆ initialize_p25_heuristics()
Initializes the heuristics state.
- Parameters
-
◆ update_error_stats()
| void update_error_stats |
( |
P25Heuristics * | heuristics, |
|
|
int | bits, |
|
|
int | errors ) |
Updates the estimate for the BER (bit error rate). Mind this is method is not called for every single bit in the data stream but only for those bits over which we have an estimate of its error rate, specifically the bits that are protected by Reed-Solomon codes.
- Parameters
-
| heuristics | The heuristics state. |
| bits | The number of bits we have read. |
| errors | The number of errors we estimate in those bits. |