Skip to content

Commit

Permalink
#1903 P25 Phase 2 audio - resolves 2-second chopped audio segments (#…
Browse files Browse the repository at this point in the history
…1904)

Co-authored-by: Dennis Sheirer <dsheirer@github.com>
  • Loading branch information
DSheirer and Dennis Sheirer committed May 4, 2024
1 parent cbe451a commit 2f0419f
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 48 deletions.
Original file line number Diff line number Diff line change
@@ -1,26 +1,28 @@
/*******************************************************************************
* sdr-trunk
* Copyright (C) 2014-2019 Dennis Sheirer
/*
* *****************************************************************************
* Copyright (C) 2014-2024 Dennis Sheirer
*
* 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 the Free Software Foundation, either version 3 of the License, or (at your option) any
* later version.
* 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
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License along with this program.
* If not, see <http://www.gnu.org/licenses/>
*
******************************************************************************/
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
* ****************************************************************************
*/

package io.github.dsheirer.module.decode.p25.phase1.message.tsbk.harris.isp;

import io.github.dsheirer.bits.CorrectedBinaryMessage;
import io.github.dsheirer.identifier.Identifier;
import io.github.dsheirer.module.decode.p25.phase1.P25P1DataUnitID;
import io.github.dsheirer.module.decode.p25.phase1.message.tsbk.OSPMessage;

import java.util.Collections;
import java.util.List;

Expand All @@ -41,7 +43,7 @@ public String toString()
{
StringBuilder sb = new StringBuilder();
sb.append(getMessageStub());
sb.append(" HARRIS **UNRECOGNIZED ISP OPCODE**");
sb.append(" HARRIS **UNRECOGNIZED ISP OPCODE: ").append(getOpcodeNumber());
sb.append(" MSG:").append(getMessage().toHexString());
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,26 +1,28 @@
/*******************************************************************************
* sdr-trunk
* Copyright (C) 2014-2019 Dennis Sheirer
/*
* *****************************************************************************
* Copyright (C) 2014-2024 Dennis Sheirer
*
* 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 the Free Software Foundation, either version 3 of the License, or (at your option) any
* later version.
* 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
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License along with this program.
* If not, see <http://www.gnu.org/licenses/>
*
******************************************************************************/
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
* ****************************************************************************
*/

package io.github.dsheirer.module.decode.p25.phase1.message.tsbk.harris.osp;

import io.github.dsheirer.bits.CorrectedBinaryMessage;
import io.github.dsheirer.identifier.Identifier;
import io.github.dsheirer.module.decode.p25.phase1.P25P1DataUnitID;
import io.github.dsheirer.module.decode.p25.phase1.message.tsbk.OSPMessage;

import java.util.Collections;
import java.util.List;

Expand All @@ -41,7 +43,7 @@ public String toString()
{
StringBuilder sb = new StringBuilder();
sb.append(getMessageStub());
sb.append(" HARRIS **UNRECOGNIZED OSP OPCODE**");
sb.append(" HARRIS **UNRECOGNIZED OSP OPCODE:").append(getOpcodeNumber());
sb.append(" MSG:").append(getMessage().toHexString());
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public String toString()
{
StringBuilder sb = new StringBuilder();
sb.append(getMessageStub());
sb.append(" MOTOROLA **UNRECOGNIZED ISP OPCODE**");
sb.append(" MOTOROLA **UNRECOGNIZED ISP OPCODE: ").append(getOpcodeNumber());
sb.append(" MSG:").append(getMessage().toHexString());
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* ******************************************************************************
* sdrtrunk
* Copyright (C) 2014-2019 Dennis Sheirer
* *****************************************************************************
* Copyright (C) 2014-2024 Dennis Sheirer
*
* 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
Expand All @@ -15,7 +14,7 @@
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
* *****************************************************************************
* ****************************************************************************
*/

package io.github.dsheirer.module.decode.p25.phase1.message.tsbk.motorola.osp;
Expand All @@ -24,7 +23,6 @@
import io.github.dsheirer.identifier.Identifier;
import io.github.dsheirer.module.decode.p25.phase1.P25P1DataUnitID;
import io.github.dsheirer.module.decode.p25.phase1.message.tsbk.OSPMessage;

import java.util.Collections;
import java.util.List;

Expand All @@ -45,7 +43,7 @@ public String toString()
{
StringBuilder sb = new StringBuilder();
sb.append(getMessageStub());
sb.append(" MOTOROLA **UNRECOGNIZED OSP OPCODE**");
sb.append(" MOTOROLA **UNRECOGNIZED OSP OPCODE: ").append(getOpcodeNumber());
sb.append(" MSG:").append(getMessage().toHexString());
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* ******************************************************************************
* sdrtrunk
* Copyright (C) 2014-2019 Dennis Sheirer
* *****************************************************************************
* Copyright (C) 2014-2024 Dennis Sheirer
*
* 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
Expand All @@ -15,7 +14,7 @@
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
* *****************************************************************************
* ****************************************************************************
*/

package io.github.dsheirer.module.decode.p25.phase1.message.tsbk.standard.isp;
Expand All @@ -24,7 +23,6 @@
import io.github.dsheirer.identifier.Identifier;
import io.github.dsheirer.module.decode.p25.phase1.P25P1DataUnitID;
import io.github.dsheirer.module.decode.p25.phase1.message.tsbk.ISPMessage;

import java.util.Collections;
import java.util.List;

Expand All @@ -45,7 +43,7 @@ public String toString()
{
StringBuilder sb = new StringBuilder();
sb.append(getMessageStub());
sb.append(" **UNRECOGNIZED ISP OPCODE**");
sb.append(" **UNRECOGNIZED ISP OPCODE: ").append(getOpcodeNumber());
sb.append(" MSG:").append(getMessage().toHexString());
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* ******************************************************************************
* sdrtrunk
* Copyright (C) 2014-2019 Dennis Sheirer
* *****************************************************************************
* Copyright (C) 2014-2024 Dennis Sheirer
*
* 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
Expand All @@ -15,7 +14,7 @@
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
* *****************************************************************************
* ****************************************************************************
*/

package io.github.dsheirer.module.decode.p25.phase1.message.tsbk.standard.osp;
Expand All @@ -24,7 +23,6 @@
import io.github.dsheirer.identifier.Identifier;
import io.github.dsheirer.module.decode.p25.phase1.P25P1DataUnitID;
import io.github.dsheirer.module.decode.p25.phase1.message.tsbk.OSPMessage;

import java.util.Collections;
import java.util.List;

Expand All @@ -45,7 +43,7 @@ public String toString()
{
StringBuilder sb = new StringBuilder();
sb.append(getMessageStub());
sb.append(" **UNRECOGNIZED OSP OPCODE**");
sb.append(" **UNRECOGNIZED OSP OPCODE: ").append(getOpcodeNumber());
sb.append(" MSG:").append(getMessage().toHexString());
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1458,7 +1458,10 @@ private void processNullInformation(MacMessage message, MacStructure mac)
* based solely on the null info in the traffic channel. Ultimately, the existing call event will either be
* updated by a subsequent call, or removed via the traffic channel teardown.
*/
continueState(State.ACTIVE);
if(message.getMacPduType() != MacPduType.MAC_4_ACTIVE) //Don't change the state when we're in a call
{
continueState(State.ACTIVE);
}
}

/**
Expand Down

0 comments on commit 2f0419f

Please sign in to comment.