mirror of
https://github.com/lwvmobile/dsd-fme.git
synced 2026-11-19 20:27:26 -05:00
Permit MAC_SIGNAL on bad CRC with -F option
This commit is contained in:
@@ -703,9 +703,11 @@ usage ()
|
|||||||
printf (" -mg Use only GFSK modulation optimizations\n");
|
printf (" -mg Use only GFSK modulation optimizations\n");
|
||||||
printf (" -mq Use only QPSK modulation optimizations\n");
|
printf (" -mq Use only QPSK modulation optimizations\n");
|
||||||
printf (" -m2 Use Phase 2 6000 sps CQPSK modulation optimizations (testing, not fully implemented) \n");
|
printf (" -m2 Use Phase 2 6000 sps CQPSK modulation optimizations (testing, not fully implemented) \n");
|
||||||
// printf (" -F Enable DMR TDMA Stereo Passive Frame Sync\n");
|
printf (" -F Relax P25 Phase 2 MAC_SIGNAL CRC Checksum Pass/Fail\n");
|
||||||
// printf (" This feature will attempt to resync less often due to excessive voice errors\n");
|
printf (" Use this feature to allow MAC_SIGNAL even if bad CRC errors.\n");
|
||||||
// printf (" Use if skipping occurs, but may cause wonky audio due to loss of good sync\n");
|
printf (" -F Enable DMR BS Stereo Passive Frame Sync\n");
|
||||||
|
printf (" This feature will attempt to resync less often due to excessive voice errors\n");
|
||||||
|
printf (" Use if skipping occurs, but may cause wonky audio due to loss of good sync\n");
|
||||||
printf (" -Z Log MBE/Frame Payloads to console\n");
|
printf (" -Z Log MBE/Frame Payloads to console\n");
|
||||||
printf ("\n");
|
printf ("\n");
|
||||||
printf (" -K <dec> Manually Enter DMRA Privacy Key (Decimal Value of Key Number)\n");
|
printf (" -K <dec> Manually Enter DMRA Privacy Key (Decimal Value of Key Number)\n");
|
||||||
|
|||||||
@@ -76,18 +76,20 @@ void process_SACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[180]
|
|||||||
{
|
{
|
||||||
//fprintf (stderr, " NULL ");
|
//fprintf (stderr, " NULL ");
|
||||||
}
|
}
|
||||||
else //permit MAC_SIGNAL on CRC ERR for now until demodulator is working better? tests show tons of falsing, so leave on
|
else //permit MAC_SIGNAL on CRC ERR if -F option called
|
||||||
{
|
{
|
||||||
fprintf (stderr, " CRC16 ERR L");
|
if (opts->aggressive_framesync == 1)
|
||||||
state->p2_is_lcch = 0; //turn flag off here
|
{
|
||||||
// if (state->currentslot == 0) state->dmrburstL = 14;
|
fprintf (stderr, " CRC16 ERR L");
|
||||||
// else state->dmrburstR = 14;
|
state->p2_is_lcch = 0; //turn flag off here
|
||||||
goto END_SMAC;
|
if (state->currentslot == 0) state->dmrburstL = 14;
|
||||||
|
else state->dmrburstR = 14;
|
||||||
|
goto END_SMAC;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//remember, slots are inverted here, so set the opposite ones
|
//remember, slots are inverted here, so set the opposite ones
|
||||||
//monitor, test, and remove these if they cause issues due to inversion
|
//monitor, test, and remove these if they cause issues due to inversion
|
||||||
if (opcode == 0x0)
|
if (opcode == 0x0)
|
||||||
@@ -217,7 +219,7 @@ void process_SACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[180]
|
|||||||
}
|
}
|
||||||
fprintf (stderr, "%s", KNRM);
|
fprintf (stderr, "%s", KNRM);
|
||||||
}
|
}
|
||||||
if (opcode == 0x3)
|
if (opcode == 0x3 && err == 0)
|
||||||
{
|
{
|
||||||
if (state->currentslot == 1) state->dmrburstL = 24;
|
if (state->currentslot == 1) state->dmrburstL = 24;
|
||||||
else state->dmrburstR = 24;
|
else state->dmrburstR = 24;
|
||||||
@@ -226,7 +228,7 @@ void process_SACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[180]
|
|||||||
process_MAC_VPDU(opts, state, 1, SMAC);
|
process_MAC_VPDU(opts, state, 1, SMAC);
|
||||||
fprintf (stderr, "%s", KNRM);
|
fprintf (stderr, "%s", KNRM);
|
||||||
}
|
}
|
||||||
if (opcode == 0x4)
|
if (opcode == 0x4 && err == 0)
|
||||||
{
|
{
|
||||||
if (state->currentslot == 1) state->dmrburstL = 21;
|
if (state->currentslot == 1) state->dmrburstL = 21;
|
||||||
else state->dmrburstR = 21;
|
else state->dmrburstR = 21;
|
||||||
@@ -235,7 +237,7 @@ void process_SACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[180]
|
|||||||
process_MAC_VPDU(opts, state, 1, SMAC);
|
process_MAC_VPDU(opts, state, 1, SMAC);
|
||||||
fprintf (stderr, "%s", KNRM);
|
fprintf (stderr, "%s", KNRM);
|
||||||
}
|
}
|
||||||
if (opcode == 0x6)
|
if (opcode == 0x6 && err == 0)
|
||||||
{
|
{
|
||||||
if (state->currentslot == 1) state->dmrburstL = 22;
|
if (state->currentslot == 1) state->dmrburstL = 22;
|
||||||
else state->dmrburstR = 22;
|
else state->dmrburstR = 22;
|
||||||
@@ -427,7 +429,7 @@ void process_FACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[156]
|
|||||||
}
|
}
|
||||||
fprintf (stderr, "%s", KNRM);
|
fprintf (stderr, "%s", KNRM);
|
||||||
}
|
}
|
||||||
if (opcode == 0x3)
|
if (opcode == 0x3 && err == 0)
|
||||||
{
|
{
|
||||||
//what else should we zero out here?
|
//what else should we zero out here?
|
||||||
//disable any of the lines below if issues are observed
|
//disable any of the lines below if issues are observed
|
||||||
@@ -456,7 +458,7 @@ void process_FACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[156]
|
|||||||
process_MAC_VPDU(opts, state, 0, FMAC);
|
process_MAC_VPDU(opts, state, 0, FMAC);
|
||||||
fprintf (stderr, "%s", KNRM);
|
fprintf (stderr, "%s", KNRM);
|
||||||
}
|
}
|
||||||
if (opcode == 0x4)
|
if (opcode == 0x4 && err == 0)
|
||||||
{
|
{
|
||||||
if (state->currentslot == 0) state->dmrburstL = 21;
|
if (state->currentslot == 0) state->dmrburstL = 21;
|
||||||
else state->dmrburstR = 21;
|
else state->dmrburstR = 21;
|
||||||
@@ -465,7 +467,7 @@ void process_FACCH_MAC_PDU (dsd_opts * opts, dsd_state * state, int payload[156]
|
|||||||
process_MAC_VPDU(opts, state, 0, FMAC);
|
process_MAC_VPDU(opts, state, 0, FMAC);
|
||||||
fprintf (stderr, "%s", KNRM);
|
fprintf (stderr, "%s", KNRM);
|
||||||
}
|
}
|
||||||
if (opcode == 0x6)
|
if (opcode == 0x6 && err == 0)
|
||||||
{
|
{
|
||||||
if (state->currentslot == 0) state->dmrburstL = 22;
|
if (state->currentslot == 0) state->dmrburstL = 22;
|
||||||
else state->dmrburstR = 22;
|
else state->dmrburstR = 22;
|
||||||
|
|||||||
Reference in New Issue
Block a user