rx: show AGC gain after preamble, header and data
This commit is contained in:
parent
576cdbfac5
commit
04f29b94bf
|
@ -264,8 +264,6 @@ result_t layer1_rx_process(layer1_rx_t *rx, const float complex *samples, size_t
|
||||||
float complex filtered_samples[sample_count];
|
float complex filtered_samples[sample_count];
|
||||||
firfilt_crcf_execute_block(rx->channel_filter, (float complex *)samples, sample_count, filtered_samples);
|
firfilt_crcf_execute_block(rx->channel_filter, (float complex *)samples, sample_count, filtered_samples);
|
||||||
|
|
||||||
//LOG(LVL_DEBUG, "@%zu: agc: %f", rx->sample_index, agc_crcf_get_gain(rx->agc));
|
|
||||||
|
|
||||||
for(unsigned int i = 0; i < sample_count; i++) {
|
for(unsigned int i = 0; i < sample_count; i++) {
|
||||||
rx->sample_index++;
|
rx->sample_index++;
|
||||||
|
|
||||||
|
@ -327,6 +325,8 @@ result_t layer1_rx_process(layer1_rx_t *rx, const float complex *samples, size_t
|
||||||
}
|
}
|
||||||
|
|
||||||
if(acquire_preamble(rx, symsync_out, !is_central_node)) {
|
if(acquire_preamble(rx, symsync_out, !is_central_node)) {
|
||||||
|
LOG(LVL_DEBUG, "@%zu: agc [pre]: %f", rx->sample_index, agc_crcf_get_gain(rx->agc));
|
||||||
|
|
||||||
// Preamble found and frequency corrected!
|
// Preamble found and frequency corrected!
|
||||||
rx->callback(RX_EVT_PREAMBLE_FOUND, rx, NULL, 0);
|
rx->callback(RX_EVT_PREAMBLE_FOUND, rx, NULL, 0);
|
||||||
|
|
||||||
|
@ -365,6 +365,8 @@ result_t layer1_rx_process(layer1_rx_t *rx, const float complex *samples, size_t
|
||||||
uint8_t header_enc[rx->hdr_len_enc_bytes];
|
uint8_t header_enc[rx->hdr_len_enc_bytes];
|
||||||
uint8_t header[HEADER_SIZE_BYTES];
|
uint8_t header[HEADER_SIZE_BYTES];
|
||||||
|
|
||||||
|
LOG(LVL_DEBUG, "@%zu: agc [hdr]: %f", rx->sample_index, agc_crcf_get_gain(rx->agc));
|
||||||
|
|
||||||
// store debug info about the header
|
// store debug info about the header
|
||||||
rx->packet_debug_info.noise_floor_level = rx->noise_floor_level;
|
rx->packet_debug_info.noise_floor_level = rx->noise_floor_level;
|
||||||
rx->packet_debug_info.header_rssi = agc_crcf_get_rssi(rx->agc);
|
rx->packet_debug_info.header_rssi = agc_crcf_get_rssi(rx->agc);
|
||||||
|
@ -457,6 +459,8 @@ result_t layer1_rx_process(layer1_rx_t *rx, const float complex *samples, size_t
|
||||||
dump_array_cf(samples2dump_s, nsamples2dump_s, 1.0f/(SYMBOL_RATE), "/tmp/rx_dbg2.cpx64");
|
dump_array_cf(samples2dump_s, nsamples2dump_s, 1.0f/(SYMBOL_RATE), "/tmp/rx_dbg2.cpx64");
|
||||||
nsamples2dump_s = 0;
|
nsamples2dump_s = 0;
|
||||||
|
|
||||||
|
LOG(LVL_DEBUG, "@%zu: agc [dat]: %f", rx->sample_index, agc_crcf_get_gain(rx->agc));
|
||||||
|
|
||||||
// store debug info about the data
|
// store debug info about the data
|
||||||
rx->packet_debug_info.data_rssi = agc_crcf_get_rssi(rx->agc);
|
rx->packet_debug_info.data_rssi = agc_crcf_get_rssi(rx->agc);
|
||||||
rx->packet_debug_info.data_evm = -1e38f; // FIXME
|
rx->packet_debug_info.data_evm = -1e38f; // FIXME
|
||||||
|
|
Loading…
Reference in a new issue