Moved constant specifying sample rate for M17 baseband decoding from hwconfig.h files to M17Demodulator class
This commit is contained in:
parent
e5b5daba85
commit
fda0fed5e7
|
|
@ -111,6 +111,7 @@ private:
|
||||||
static constexpr size_t M17_FRAME_SYMBOLS = 192;
|
static constexpr size_t M17_FRAME_SYMBOLS = 192;
|
||||||
static constexpr size_t M17_SYNCWORD_SYMBOLS = 8;
|
static constexpr size_t M17_SYNCWORD_SYMBOLS = 8;
|
||||||
static constexpr size_t M17_CONV_THRESHOLD = 50000;
|
static constexpr size_t M17_CONV_THRESHOLD = 50000;
|
||||||
|
static constexpr size_t M17_RX_SAMPLE_RATE = 48000;
|
||||||
static constexpr size_t M17_SAMPLES_PER_SYMBOL = M17_RX_SAMPLE_RATE / M17_SYMBOL_RATE;
|
static constexpr size_t M17_SAMPLES_PER_SYMBOL = M17_RX_SAMPLE_RATE / M17_SYMBOL_RATE;
|
||||||
static constexpr size_t M17_INPUT_BUF_SIZE = 2 * M17_FRAME_SAMPLES_24K;
|
static constexpr size_t M17_INPUT_BUF_SIZE = 2 * M17_FRAME_SAMPLES_24K;
|
||||||
static constexpr size_t M17_FRAME_BYTES = M17_FRAME_SYMBOLS / 4;
|
static constexpr size_t M17_FRAME_BYTES = M17_FRAME_SYMBOLS / 4;
|
||||||
|
|
|
||||||
|
|
@ -301,7 +301,7 @@ void radio_updateConfiguration()
|
||||||
C6000.setModAmplitude(0, Q);
|
C6000.setModAmplitude(0, Q);
|
||||||
|
|
||||||
// Set bandwidth, force 12.5kHz for DMR mode
|
// Set bandwidth, force 12.5kHz for DMR mode
|
||||||
if((config->bandwidth == BW_12_5) || (config->opMode == DMR))
|
if((config->bandwidth == BW_12_5) || (config->opMode == OPMODE_DMR))
|
||||||
{
|
{
|
||||||
at1846s.setBandwidth(AT1846S_BW::_12P5);
|
at1846s.setBandwidth(AT1846S_BW::_12P5);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
* Copyright (C) 2020 by Federico Amedeo Izzo IU2NUO, *
|
* Copyright (C) 2020 - 2022 by Federico Amedeo Izzo IU2NUO, *
|
||||||
* Niccolò Izzo IU2KIN *
|
* Niccolò Izzo IU2KIN *
|
||||||
* Silvano Seva IU2KWO *
|
* Silvano Seva IU2KWO *
|
||||||
* *
|
* *
|
||||||
* This program is free software; you can redistribute it and/or modify *
|
* This program is free software; you can redistribute it and/or modify *
|
||||||
* it under the terms of the GNU General Public License as published by *
|
* it under the terms of the GNU General Public License as published by *
|
||||||
|
|
@ -143,9 +143,6 @@ extern "C" {
|
||||||
#define GPS_EN GPIOD,8
|
#define GPS_EN GPIOD,8
|
||||||
#define GPS_DATA GPIOD,9
|
#define GPS_DATA GPIOD,9
|
||||||
|
|
||||||
/* M17 demodulation */
|
|
||||||
#define M17_RX_SAMPLE_RATE 48000
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,9 @@
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
* Copyright (C) 2021 by Federico Amedeo Izzo IU2NUO, *
|
* Copyright (C) 2021 - 2022 by Federico Amedeo Izzo IU2NUO, *
|
||||||
* Niccolò Izzo IU2KIN, *
|
* Niccolò Izzo IU2KIN, *
|
||||||
* Frederik Saraci IU2NRO, *
|
* Frederik Saraci IU2NRO, *
|
||||||
* Silvano Seva IU2KWO *
|
* Silvano Seva IU2KWO *
|
||||||
* Mathis Schmieder DB9MAT *
|
* Mathis Schmieder DB9MAT *
|
||||||
* *
|
* *
|
||||||
* This program is free software; you can redistribute it and/or modify *
|
* This program is free software; you can redistribute it and/or modify *
|
||||||
* it under the terms of the GNU General Public License as published by *
|
* it under the terms of the GNU General Public License as published by *
|
||||||
|
|
@ -83,7 +83,4 @@
|
||||||
#define SOFTPOT_RX 0x2E
|
#define SOFTPOT_RX 0x2E
|
||||||
#define SOFTPOT_TX 0x2F
|
#define SOFTPOT_TX 0x2F
|
||||||
|
|
||||||
/* M17 demodulation */
|
|
||||||
#define M17_RX_SAMPLE_RATE 48000
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
* Copyright (C) 2020 by Frederik Saraci IU2NRO *
|
* Copyright (C) 2020 - 2022 by Frederik Saraci IU2NRO *
|
||||||
* *
|
* *
|
||||||
* This program is free software; you can redistribute it and/or modify *
|
* This program is free software; you can redistribute it and/or modify *
|
||||||
* it under the terms of the GNU General Public License as published by *
|
* it under the terms of the GNU General Public License as published by *
|
||||||
|
|
@ -62,9 +62,6 @@ extern "C" {
|
||||||
/* Push-to-talk switch */
|
/* Push-to-talk switch */
|
||||||
#define PTT_SW "PTT_SW",11
|
#define PTT_SW "PTT_SW",11
|
||||||
|
|
||||||
/* M17 demodulation */
|
|
||||||
#define M17_RX_SAMPLE_RATE 48000
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue