mirror of
https://github.com/eried/portapack-mayhem.git
synced 2024-10-01 01:26:06 -04:00
Small error correction to PR 1367 (#1368)
This commit is contained in:
parent
853ca2ef53
commit
5cfd7f1dc2
@ -113,7 +113,8 @@ uint32_t RecordView::set_sampling_rate(uint32_t new_sampling_rate) {
|
||||
* They are ok as recorded spectrum indication, but they should not be used by Replay app. (the voice speed will be accelerated)
|
||||
|
||||
* We keep original black background in all the correct IQ .C16 files BW's Options. */
|
||||
if ((actual_sampling_rate > 8'000'000) || (actual_sampling_rate <= 1'280'000)) { // yellow REC button means not ok for REC, BW >1Mhz , BW < 150khz
|
||||
if ((actual_sampling_rate > 8'000'000) || (actual_sampling_rate <= 1'600'000)) { // yellow REC button means not ok for REC, BW >1Mhz , BW <= 100khz due to NG aliasing.
|
||||
// to be updated or removed in the next PR's, according the achieved extended BW's with good quality bandwith REC limits .
|
||||
button_record.set_background(ui::Color::yellow());
|
||||
} else {
|
||||
button_record.set_background(ui::Color::black());
|
||||
|
@ -46,12 +46,11 @@
|
||||
* The oversample rate is used to increase the sample rate to improve SNR and quality.
|
||||
* This is also used as the interpolation rate when replaying captures. */
|
||||
inline OversampleRate get_oversample_rate(uint32_t sample_rate) {
|
||||
if (sample_rate < 50'000) return OversampleRate::x128; // 25kk ,16k, 12k5
|
||||
if (sample_rate < 100'000) return OversampleRate::x64; // 50k
|
||||
if (sample_rate < 150'000) return OversampleRate::x32; // 100k
|
||||
if (sample_rate < 250'000) return OversampleRate::x16; // 150k only
|
||||
if (sample_rate < 50'000) return OversampleRate::x128; // 25kk..12k5, prepared for future, OVS ok, but decim. :128 still not implemented.
|
||||
if (sample_rate < 100'000) return OversampleRate::x64; // 50k, prepared for future, OVS ok, but decim. :64 still not implemented.
|
||||
if (sample_rate < 250'000) return OversampleRate::x16; // Now tentatively applied to 150k..100k - but as soon as we got decim :32, (150k x16, and 100k x32)
|
||||
|
||||
return OversampleRate::x8; // 250k .. 1Mhz
|
||||
return OversampleRate::x8; // 250k .. 1Mhz, that decim :8 , is already applied.(OVS and decim OK)
|
||||
}
|
||||
|
||||
/* Gets the actual sample rate for a given sample rate.
|
||||
|
Loading…
Reference in New Issue
Block a user