aboutsummaryrefslogtreecommitdiffstats
path: root/src/nmt
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2017-08-19 12:27:05 +0200
committerAndreas Eversberg <jolly@eversberg.eu>2017-09-01 18:42:46 +0200
commit743d147d1672837595ae1d6aa024522f4a011614 (patch)
tree50c44e565e00700d90338835e681cbb1dccf8e9b /src/nmt
parent1c2e9180a2db989f26c5cff01eaa6ef12bb45011 (diff)
SDR: Turn TX power off if requested by network
The power level is ramped smoothly within 1 ms up or down. R2000, AMPS and C-Netz turn off power when voice channel is not i use. C-Netz turns off power between OgK timeslots.
Diffstat (limited to 'src/nmt')
-rw-r--r--src/nmt/dsp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/nmt/dsp.c b/src/nmt/dsp.c
index d0063a8..6086d62 100644
--- a/src/nmt/dsp.c
+++ b/src/nmt/dsp.c
@@ -417,11 +417,13 @@ static void dial_tone(nmt_t *nmt, sample_t *samples, int length)
}
/* Provide stream of audio toward radio unit */
-void sender_send(sender_t *sender, sample_t *samples, int length)
+void sender_send(sender_t *sender, sample_t *samples, uint8_t *power, int length)
{
nmt_t *nmt = (nmt_t *) sender;
int count;
+ memset(power, 1, length);
+
again:
switch (nmt->dsp_mode) {
case DSP_MODE_AUDIO: