Seperate MBE Payload Printing from MBE Saving

Seperate MBE Payload Printing from MBE Saving
--seperate the MBE Payload Printing functions from MBE Saving Function
--no longer need to use -d ./MBE/ to print a MBE Payload
--is currently using -Z for payload printing, may further seperate, make new user switch in future
This commit is contained in:
lwvmobile
2022-05-19 22:16:44 -04:00
committed by GitHub
parent 1d30d5ec32
commit e69451b0d7
5 changed files with 106 additions and 55 deletions

View File

@@ -118,6 +118,10 @@ if (state->currentslot == 1 && state->K > 0 && state->dmr_soR & 0x40 && state->p
//
if (state->currentslot == 0)
{
if (opts->payload == 1)
{
fprintf(stderr, "\n"); //line break for AMBE printer
}
for(Frame = 0; Frame < 6; Frame++) //6
{
/* 1 DMR frame contains 3 AMBE voice samples */
@@ -132,30 +136,19 @@ if (state->currentslot == 0)
TSVoiceSupFrameL->TimeSlotAmbeVoiceFrame[Frame].AmbeBit[i],
state->cur_mp, state->prev_mp, state->prev_mp_enhanced, opts->uvquality);
if (opts->payload == 1)
{
PrintAMBEData(opts, state, TSVoiceSupFrameL->TimeSlotAmbeVoiceFrame[Frame].AmbeBit[i]);
}
if (opts->mbe_out_f != NULL)
{
saveAmbe2450Data (opts, state, TSVoiceSupFrameL->TimeSlotAmbeVoiceFrame[Frame].AmbeBit[i]);
}
if (opts->errorbars == 1)
{
//fprintf(stderr, "%s", state->err_str);
}
state->debug_audio_errors += *errs2;
//
//fprintf (stderr, "%X", TSVoiceSupFrameL->TimeSlotDeinterleavedVoiceFrame[Frame].DeInterleavedVoiceSample[i] ); //this set up right?
//
/*
fprintf (stderr, "\nInt RVD ");
for (short o = 0; o < 36; o++)
{
fprintf (stderr, "%X", TSVoiceSupFrameL->TimeSlotDeinterleavedVoiceFrame[Frame].DeInterleavedVoiceSample[i][o] );
}
*/
//wny do I have this running twice for?
//processAudio(opts, state);
processAudio(opts, state);
//playSynthesizedVoice (opts, state);
if (opts->wav_out_f != NULL)
{
@@ -173,6 +166,10 @@ if (state->currentslot == 0)
if (state->currentslot == 1)
{
if (opts->payload == 1)
{
fprintf(stderr, "\n"); //line break for AMBE printer
}
for(Frame = 0; Frame < 6; Frame++)
{
/* 1 DMR frame contains 3 AMBE voice samples */
@@ -187,28 +184,20 @@ if (state->currentslot == 0)
TSVoiceSupFrameR->TimeSlotAmbeVoiceFrame[Frame].AmbeBit[i],
state->cur_mp, state->prev_mp, state->prev_mp_enhanced, opts->uvquality);
if (opts->payload == 1)
{
PrintAMBEData(opts, state, TSVoiceSupFrameR->TimeSlotAmbeVoiceFrame[Frame].AmbeBit[i]);
}
if (opts->mbe_out_f != NULL)
{
saveAmbe2450Data (opts, state, TSVoiceSupFrameR->TimeSlotAmbeVoiceFrame[Frame].AmbeBit[i]);
}
if (opts->errorbars == 1)
{
//fprintf(stderr, "%s", state->err_str);
}
state->debug_audio_errors += *errs2;
//
//fprintf (stderr, "%X", TSVoiceSupFrameR->TimeSlotDeinterleavedVoiceFrame[Frame].DeInterleavedVoiceSample[i] ); //this set up right?
//
/*
fprintf (stderr, "\nInt RVD ");
for (short o = 0; o < 36; o++)
{
fprintf (stderr, "%X", TSVoiceSupFrameR->TimeSlotDeinterleavedVoiceFrame[Frame].DeInterleavedVoiceSample[i][o] );
}
*/
processAudio(opts, state);
//playSynthesizedVoice (opts, state);
if (opts->wav_out_f != NULL)
{