mirror of
https://github.com/lwvmobile/dsd-fme.git
synced 2026-11-20 12:45:40 -05:00
P25 P2 ISCH Var Fix;
This commit is contained in:
@@ -1034,7 +1034,7 @@ bool CDMRTrellisDecode(const unsigned char* data, unsigned char* payload);
|
|||||||
int ez_rs28_ess (int payload[96], int parity[168]); //ezpwd bridge for FME
|
int ez_rs28_ess (int payload[96], int parity[168]); //ezpwd bridge for FME
|
||||||
int ez_rs28_facch (int payload[156], int parity[114]); //ezpwd bridge for FME
|
int ez_rs28_facch (int payload[156], int parity[114]); //ezpwd bridge for FME
|
||||||
int ez_rs28_sacch (int payload[180], int parity[132]); //ezpwd bridge for FME
|
int ez_rs28_sacch (int payload[180], int parity[132]); //ezpwd bridge for FME
|
||||||
unsigned long long int isch_lookup (unsigned long long int isch); //isch map lookup
|
int isch_lookup (unsigned long long int isch); //isch map lookup
|
||||||
int bd_bridge (int payload[196], uint8_t decoded[12]); //bridge to Michael Ossmann Block De-interleaver and 1/2 rate trellis decoder
|
int bd_bridge (int payload[196], uint8_t decoded[12]); //bridge to Michael Ossmann Block De-interleaver and 1/2 rate trellis decoder
|
||||||
int crc16_lb_bridge (int payload[190], int len);
|
int crc16_lb_bridge (int payload[190], int len);
|
||||||
int crc12_xb_bridge (int payload[190], int len);
|
int crc12_xb_bridge (int payload[190], int len);
|
||||||
|
|||||||
@@ -312,11 +312,11 @@ void map_isch()
|
|||||||
isch_map["fb063f092"] = 127;
|
isch_map["fb063f092"] = 127;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned long long int isch_lookup (unsigned long long int isch)
|
int isch_lookup (unsigned long long int isch)
|
||||||
{
|
{
|
||||||
map_isch(); //initialize the lookup map
|
map_isch(); //initialize the lookup map
|
||||||
char s[64];
|
char s[64];
|
||||||
unsigned long long int decoded = -2; //initialize lookup to an invalid number
|
int decoded = -2; //initialize lookup to an invalid number
|
||||||
sprintf(s, "%llx", isch);
|
sprintf(s, "%llx", isch);
|
||||||
decoded = isch_map[s];
|
decoded = isch_map[s];
|
||||||
return(decoded);
|
return(decoded);
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ int vc_counter = 0;
|
|||||||
int framing_counter = 0;
|
int framing_counter = 0;
|
||||||
|
|
||||||
unsigned long long int isch = 0;
|
unsigned long long int isch = 0;
|
||||||
unsigned long long int isch_decoded = 0;
|
int isch_decoded = -1;
|
||||||
int p2_duid[8] = {0};
|
int p2_duid[8] = {0};
|
||||||
int16_t duid_decoded = 0;
|
int16_t duid_decoded = 0;
|
||||||
|
|
||||||
@@ -369,7 +369,7 @@ void process_ISCH (dsd_opts * opts, dsd_state * state)
|
|||||||
{
|
{
|
||||||
isch_decoded = isch_lookup(isch);
|
isch_decoded = isch_lookup(isch);
|
||||||
|
|
||||||
if (isch_decoded > 0)
|
if (isch_decoded > -1)
|
||||||
{
|
{
|
||||||
int uf_count = isch_decoded & 0x3;
|
int uf_count = isch_decoded & 0x3;
|
||||||
int free = (isch_decoded >> 2) & 0x1;
|
int free = (isch_decoded >> 2) & 0x1;
|
||||||
@@ -411,6 +411,7 @@ void process_ISCH (dsd_opts * opts, dsd_state * state)
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
isch_decoded = -1; //reset to bad value after running
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user