Welcome to DVSwitch
Purpose
1) Allows “local” networking during an outage of the regional national/international network server.
2) Allows a local network operator to “blend” upstream feeds from different Networks (capital N on purpose). These Networks can’t get their act together and learn how to play nice with each other (everyone guilty as far as we are concerned). They may not like people doing this, but the solution is to grow up and work with each other, and not keep trying to force people to take sides.
3) Allows local segregation of localized traffic with more flexibility.
4) Allows experimentation with linking and how it’s done (part 97 specifies experimentation and advancement of the radio art are a core part of amateur radio).
Mission Statement/Position
WHEREAS the Networks continue to be largely islands and are not working together to create a unified network of Networks.
WHEREAS no firm reason has been given by any of the Networks why a *competent* local network operator cannot make this work effectively.
(US ONLY)
WHEREAS 47 CFR 97 (Amateur Radio Service) specifies that a core component of amateur radio is experimentation and advancement of the radio art [97.1(b)].
BE IT RESOLVED the core group of US amateur radio operators and experimenters organized around the DVSwitch project, and in the spirit of USA 47 CFR 97 and its intentions, support the *responsible* and *thoughtful* use of digital voice networking tools to create localized networks that will interconnect to the national/international Networks, and will support users of its tools in order to do this in the most effective and sustainable way possible.
Re: P25 North America reflector
Miguel
Not sure but maybe this msg should say "net queue" ? Have not yet studied this code enough... https://github.com/g4klx/MMDVMHost/blob/master/P25Control.cpp#L766 Also.... this number may grow too big? https://github.com/g4klx/MMDVMHost/blob/master/P25Control.cpp#L560 My intuition (which could be wrong) tells me that there has not been as much traffic/usage on p25 over mmdvmhost code as there has been with dmr/ysf/dstar and thus there may be "issues" lurking in there... You already know about the two that I found last month.... one of those was pretty bad but it does expose the "maturity" and "time-tested-ness" of the code base. For what is worth though... I had a qso with a station at one point on 10200 then immediately switch to another reflector and no issues.... same hotspot, radios, etc... I guess people can do that test just the same by going to 10201 and see.... Some had said that the number of stations to which the packets need to be reflected may be an influence (the reflector I have only has about 30 active signed on hotspots...). Not sure myself... KC1LKO
|
|
Re: P25 North America reflector
I have not yet forked and patched Jonathan's code. Here is the
change to P25Network.cpp Let me know results.
toggle quoted messageShow quoted text
void CP25Network::clock(unsigned int ms) { unsigned char buffer[BUFFER_LENGTH]; sockaddr_storage address; unsigned int addrLen; int length = m_socket.read(buffer, BUFFER_LENGTH, address, addrLen); if (length <= 0) return; if (!CUDPSocket::match(m_addr, address)) { LogMessage("P25, packet received from an invalid source"); return; } if (!m_enabled) return; if (m_debug) CUtils::dump(1U, "P25 Network Data Received", buffer, length); unsigned char c = length; m_buffer.addData(&c, 1U); m_buffer.addData(buffer, length); } becomes...... void CP25Network::clock(unsigned int ms) { unsigned char buffer[BUFFER_LENGTH]; sockaddr_storage address; unsigned int addrLen; int length = m_socket.read(buffer, BUFFER_LENGTH, address, addrLen); if (length <= 0) return; if (!CUDPSocket::match(m_addr, address)) { LogMessage("P25, packet received from an invalid source"); return; } if (!m_enabled) return; if (m_debug) CUtils::dump(1U, "P25 Network Data Received", buffer, length); while (length > 0) { unsigned char addBytes = 0; int recSize[] = {22, 14, 17, 17, 17, 17, 17, 17, 16, 22, 14, 17, 17, 17, 17, 17, 17, 16}; unsigned char recType = buffer[0]; if ((recType >= 0x62) && (recType <= 0x73)) addBytes = recSize[recType - 0x62]; else if (recType == 0x80) addBytes = 17; else LogMessage("Got a network byte I did not expect %0X, %d", buffer[0], length); if ((addBytes > 0) && (addBytes <= length)) { m_buffer.addData(&addBytes, 1U); m_buffer.addData(buffer, addBytes); } length -= addBytes; } }
On 9/18/21 10:18 AM, Miguel wrote:
|
|
Re: P25 North America reflector
Miguel
What is the change? Have a github branch? thx
|
|
Re: P25 North America reflector
So,
I have had NO response from anyone who can test a change to MMDVMHost. I'll make it a little easier. I will provide a ARM or x86 binary. I can't provide a binary for anyone running Pi-Star at this time. For people reporting packet loss from the Pi-Ster dashboard, check your raw MMDVMHost log for the error message: E: 2021-09-18 13:40:19.719 P25, overflow in the P25 RF queue This is a good indication of what is happening. Here is a comparison of 2 logs: Stock Pi-Star M: 2021-09-18 13:55:21.540 P25, received network transmission from KB0AJQ to TG 10200
M: 2021-09-18 13:55:27.401 P25, network end of transmission from KB0AJQ to TG 10200, 6.5 seconds, 5% packet loss
Modified MMDVMHost M: 2021-09-18 13:55:21.549 P25, received network transmission from 3129130 to TG 10200
M: 2021-09-18 13:55:27.406 P25, network end of transmission from 3129130 to TG 10200, 6.1 seconds, 0% packet loss
I am running a STM32-DVM modem on a CDM repeater. I am listening on a Kenwood NX-5300 This is running the modified code.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
Got it running! USRP audio ports were crossed on the P25 side of Analog_Bridge. Thanks! Todd KB7RQQ
On 9/16/2021 9:51 AM, Todd, KB7RQQ
wrote:
|
|
Re: Macro result was 512
#analog_bridge
Steve,
Don't quite understand what you mean. Not from a Linux background and my knowledge is very limited. Sorry for that. I tried to add one more TG in the macro D script, and it failed to execute. As soon as I removed a TG, it started to work as normal. So there is something that has something to do with the length of the script. Thank you. Geoff On Fri, Sep 17, 2021 at 09:21 AM, Steve N4IRS wrote: I don't know of a limitation on size, but it's possible. Put the command in a script and cal teh script from dvsm.macro Steve, "I don't know of a limitation on size, but it's possible. Put the command in a script and cal teh script from dvsm.macro"
|
|
Re: Macro result was 512
#analog_bridge
I don't know of a limitation on size, but it's possible. Put the
command in a script and cal teh script from dvsm.macro
toggle quoted messageShow quoted text
On 9/16/21 6:17 PM, Geoff wrote:
Steve,
|
|
Re: Macro result was 512
#analog_bridge
Steve,
To answer your question, the latest version of MMDVM_Bridge (V1.6.8) installed to /opt/MMDVM_Bridge. dvswitch.sh is in /opt/Analog_Bridge not in /opt/MMDVM_Bridge so it is in one location only. The version of dvswitch is v1.6.1. What I have tried a few different things this morning :- C=sudo /opt/Analog_Bridge/dvswitch.sh tune "PASSWORD@...:55555:StartRef=4570;RelinkTime=120;UserLink=1;TS2_1=450;TS2_2=518" D=sudo /opt/Analog_Bridge/dvswitch.sh tune "PASSWORD@...:55555:StartRef=4570;RelinkTime=120;UserLink=1;TS1_1=5;TS2_1=505;TS2_2=3802;TS2_3=3803" Above two macro scripts are the original in dvsm.macro file. I have renamed C to D and D to C and tried to execute the macro D connects buit not C. It seemed that there is something wrong with the macro D script. I then tried to shorten the macro D script to :- D=sudo /opt/Analog_Bridge/dvswitch.sh tune "PASSWORD@...:55555:StartRef=4570;RelinkTime=120;UserLink=1;TS2_1=505;TS2_2=3802" Now, I don't have any issues and connects to D. I have tried multiple times and every time it connects. What does this tell? I don't think there was any syntax error in my original macro D script. I just had to remove a couple of TGs to get the D working. Is there any restriction as to how long a script can be? Thank you.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
OK sounds good. Thank you.
On 9/16/2021 9:18 AM, Steve N4IRS
wrote:
One suggestion, DVSwitch.ini should need little to no modification. You will be editing the AB ini files so, make your changes there and leave DVswitch.ini stock.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
One suggestion, DVSwitch.ini should need little to no modification.
You will be editing the AB ini files so, make your changes there and
leave DVswitch.ini stock.
toggle quoted messageShow quoted text
Steve
On 9/16/2021 11:30 AM, Todd, KB7RQQ
wrote:
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
Great diagram! Think I saw that at one point early on and forgot about it. I think I'm armed with the tools I need to figure this out. Still learning and even though this is challenging (for me)... I'm having fun. Thanks again for the tools and all the help. Todd KB7RQQ
On 9/16/2021 8:23 AM, Steve N4IRS
wrote:
<https://dvswitch.groups.io/g/main/wiki/9379>
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
toggle quoted messageShow quoted text
On 9/16/2021 10:43 AM, Todd, KB7RQQ
wrote:
OK... going through it again.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
OK... going through it again.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
DVSwitch.ini defines the AMBE_audio ports AB connects to for each mode.
Sent via smoke signal (AT&T)
From: main@DVSwitch.groups.io <main@DVSwitch.groups.io> on behalf of Todd, KB7RQQ <toddholzman@...>
Sent: Thursday, September 16, 2021 10:32:32 AM To: main@DVSwitch.groups.io <main@DVSwitch.groups.io> Subject: Re: [DVSwitch] P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103 OK... maybe I need to map this out again. Printing off the .ini's involved so I can follow the paths again.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
OK... maybe I need to map this out again. Printing off the .ini's involved so I can follow the paths again.
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
It's a single instance of MB
Sent via smoke signal (AT&T)
From: main@DVSwitch.groups.io <main@DVSwitch.groups.io> on behalf of Todd, KB7RQQ <toddholzman@...>
Sent: Thursday, September 16, 2021 10:16:02 AM To: main@DVSwitch.groups.io <main@DVSwitch.groups.io> Subject: Re: [DVSwitch] P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103 Thanks Steve (again!) Starting to make a little more sense now. Was following some loose instructions that didn't mention two instances of MMDVM_Bridge being needed. And I also don't remember getting into DVSwitch.ini.
Here is my DVSwitch.ini. ; MMDVM_Bridge export / import configuration file.
; This file should be placed along side of MMDVM_Bridge or you can supply
; an absolute path in the DVSWITCH environment variable, e.g:
; DVSWITCH=/etc/MMDVM_Bridge/DVSwitch.ini
; before executing MMDVM_Bridge
;
; Another method to set the enviorment variable is to use the systemd unit file
; by adding:
; Environment=DVSWITCH=/etc/MMDVM_Bridge/DVSwitch.ini
; to /lib/systemd/system/mmdvm_bridge.service
; Configure the Quantar Repeater Partner
; Note that the TX and RX ports are already reversed for MMDVM_Bridge <--> Quantar_Bridge
[QUANTAR]
address = 0.0.0.0 ; Address to send IMBE TLV frames to (export)
txPort = 34103 ; Port to send IMBE TLV frames to (export)
rxPort = 34100 ; Port to listen for IMBE TLV frames on (import)
quantarPort = 1994 ; HDLC frames To/From the Quantar repeater
debug = 0 ; Debug 0 = off, 1 = on (adds lots of additional messages)
logLevel = 2 ; Logging levels, 0=No logging, 1=Debug, 2=Message, 3=Info, 4=Warning, 5=Error, 6=Fatal
logFilePath = /var/log/dvswitch/Quantar_Bridge.log
; Configure the DMR Partner
; Audio format is AMBE 72 bit
[DMR]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 31100 ; Port to send AMBE TLV frames to (export)
rxPort = 31103 ; Port to listen on (import)
slot = 2 ; Export slot
exportTG = 0 ; Which TG to export
hangTimerInFrames = 0 ; Use 50 for 3 seconds of hang time (3000 / 60)
talkerAlias = %callsign %location %description ; Get callsign location and description from MMDVM_Bridge.ini
; Configure the D-Star Partner
; Audio format is AMBE 48 bit (DSAMBE)
[DSTAR]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 32100 ; Port to send AMBE TLV frames to (export)
rxPort = 32103 ; Port to listen on (import)
fallbackID = 1234567 ; In case we can not find a valid DMR id in the database, export this one
exportTG = 9 ; Which TG to export
slot = 2 ; Export slot
RemotePort = 54321 ; Port to send Gateway commands to
message = %location %description ; Get location and description from MMDVM_Bridge.ini
; Configure the NXDN Partner
; Audio format is AMBE 72 bit
[NXDN]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 33100 ; Port to send AMBE TLV frames to (export)
rxPort = 33103 ; Port to listen on (import)
fallbackID = 1234567 ; In case we can not find a valid DMR id in the database, export this one
nxdnFallbackID = 12345 ; Use this ID when the input DMR ID is not found in the database
translate = 1234=4321 ; Translate NXDN TG < -- > DMR TG (bidirectional)
slot = 2 ; Export slot
RemotePort = 6075 ; Port to send Gateway commands to
; Configure the P25 Partner
; Audio format is IMBE 88 bit
[P25]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 34100 ; Port to send AMBE TLV frames to (export)
rxPort = 34103 ; Port to listen on (import)
slot = 2 ; Export slot
RemotePort = 6074 ; Port to send Gateway commands to
; Configure the Yaesu Fusion Partner
; Audio format is AMBE 72 bit
; Audio format is IMBE 88 bit
[YSF]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 35100 ; Port to send AMBE TLV frames to (export)
rxPort = 35103 ; Port to listen on (import)
txWidePort = 35105 ; Port to send IMBE TLV frames to for YSFw (export)
fallbackID = 1234567 ; In case we can not find a valid DMR id in the database, export this one
exportTG = 9 ; Which TG to export
slot = 2 ; Export slot
RemotePort = 6073 ; Port to send Gateway commands to
; Configure the BrandMeister connection
; Simple Terminal Feature Update
; Audio format is AMBE 72 bit
[STFU] ; Brandmeister Open DMR Terminal (ODMRT) Protocol
BMAddress = 3102.repeater.net ; Brandmeister ODMRT server address
BMPort = 54006 ; Brandmeister ODMRT port
BMPassword = passw0rd ; Your Brandmeister password
Address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 36100 ; Port to send AMBE TLV frames to (export)
rxPort = 36103 ; Port to listen on (import)
UserID = 123456789 ; Your DMR ID + SSID
TalkerAlias = N0CALL Name City ; Max 27 characters
StartTG = 3166 ; Startup talk group
LogLevel = 3 ; STFU log level (0=No logging, 1=Debug, 2=Message, 3=Info, 4=Warning, 5=Error)
[ASL]
address = 127.0.0.1
txPort = 30100
rxPort = 30103
|
|
Re: P25 to DMR troubles. error at MMDVM_Bridge - Cannot bind UDP address, err: 98 -and- Cannot open listener port 34103
Thanks Steve (again!) Starting to make a little more sense now. Was following some loose instructions that didn't mention two instances of MMDVM_Bridge being needed. And I also don't remember getting into DVSwitch.ini.
Here is my DVSwitch.ini. ; MMDVM_Bridge export / import configuration file.
; This file should be placed along side of MMDVM_Bridge or you can supply
; an absolute path in the DVSWITCH environment variable, e.g:
; DVSWITCH=/etc/MMDVM_Bridge/DVSwitch.ini
; before executing MMDVM_Bridge
;
; Another method to set the enviorment variable is to use the systemd unit file
; by adding:
; Environment=DVSWITCH=/etc/MMDVM_Bridge/DVSwitch.ini
; to /lib/systemd/system/mmdvm_bridge.service
; Configure the Quantar Repeater Partner
; Note that the TX and RX ports are already reversed for MMDVM_Bridge <--> Quantar_Bridge
[QUANTAR]
address = 0.0.0.0 ; Address to send IMBE TLV frames to (export)
txPort = 34103 ; Port to send IMBE TLV frames to (export)
rxPort = 34100 ; Port to listen for IMBE TLV frames on (import)
quantarPort = 1994 ; HDLC frames To/From the Quantar repeater
debug = 0 ; Debug 0 = off, 1 = on (adds lots of additional messages)
logLevel = 2 ; Logging levels, 0=No logging, 1=Debug, 2=Message, 3=Info, 4=Warning, 5=Error, 6=Fatal
logFilePath = /var/log/dvswitch/Quantar_Bridge.log
; Configure the DMR Partner
; Audio format is AMBE 72 bit
[DMR]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 31100 ; Port to send AMBE TLV frames to (export)
rxPort = 31103 ; Port to listen on (import)
slot = 2 ; Export slot
exportTG = 0 ; Which TG to export
hangTimerInFrames = 0 ; Use 50 for 3 seconds of hang time (3000 / 60)
talkerAlias = %callsign %location %description ; Get callsign location and description from MMDVM_Bridge.ini
; Configure the D-Star Partner
; Audio format is AMBE 48 bit (DSAMBE)
[DSTAR]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 32100 ; Port to send AMBE TLV frames to (export)
rxPort = 32103 ; Port to listen on (import)
fallbackID = 1234567 ; In case we can not find a valid DMR id in the database, export this one
exportTG = 9 ; Which TG to export
slot = 2 ; Export slot
RemotePort = 54321 ; Port to send Gateway commands to
message = %location %description ; Get location and description from MMDVM_Bridge.ini
; Configure the NXDN Partner
; Audio format is AMBE 72 bit
[NXDN]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 33100 ; Port to send AMBE TLV frames to (export)
rxPort = 33103 ; Port to listen on (import)
fallbackID = 1234567 ; In case we can not find a valid DMR id in the database, export this one
nxdnFallbackID = 12345 ; Use this ID when the input DMR ID is not found in the database
translate = 1234=4321 ; Translate NXDN TG < -- > DMR TG (bidirectional)
slot = 2 ; Export slot
RemotePort = 6075 ; Port to send Gateway commands to
; Configure the P25 Partner
; Audio format is IMBE 88 bit
[P25]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 34100 ; Port to send AMBE TLV frames to (export)
rxPort = 34103 ; Port to listen on (import)
slot = 2 ; Export slot
RemotePort = 6074 ; Port to send Gateway commands to
; Configure the Yaesu Fusion Partner
; Audio format is AMBE 72 bit
; Audio format is IMBE 88 bit
[YSF]
address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 35100 ; Port to send AMBE TLV frames to (export)
rxPort = 35103 ; Port to listen on (import)
txWidePort = 35105 ; Port to send IMBE TLV frames to for YSFw (export)
fallbackID = 1234567 ; In case we can not find a valid DMR id in the database, export this one
exportTG = 9 ; Which TG to export
slot = 2 ; Export slot
RemotePort = 6073 ; Port to send Gateway commands to
; Configure the BrandMeister connection
; Simple Terminal Feature Update
; Audio format is AMBE 72 bit
[STFU] ; Brandmeister Open DMR Terminal (ODMRT) Protocol
BMAddress = 3102.repeater.net ; Brandmeister ODMRT server address
BMPort = 54006 ; Brandmeister ODMRT port
BMPassword = passw0rd ; Your Brandmeister password
Address = 127.0.0.1 ; Address to send AMBE TLV frames to (export)
txPort = 36100 ; Port to send AMBE TLV frames to (export)
rxPort = 36103 ; Port to listen on (import)
UserID = 123456789 ; Your DMR ID + SSID
TalkerAlias = N0CALL Name City ; Max 27 characters
StartTG = 3166 ; Startup talk group
LogLevel = 3 ; STFU log level (0=No logging, 1=Debug, 2=Message, 3=Info, 4=Warning, 5=Error)
[ASL]
address = 127.0.0.1
txPort = 30100
rxPort = 30103
|
|
Re: Macro result was 512
#analog_bridge
OK,
toggle quoted messageShow quoted text
So we know the macro is firing the script. Macros A B and C run The MMDVM_Bridge install moved dvswitch.sh from /opt/Analog_Bridge to /opt/MMDVM_Bridge Do you have it in both locations? What is the version of dvswitch you are executing?
On 9/16/2021 8:09 AM, Geoff wrote:
It created an out.txt file in /tmp containing a text "version"
|
|
Re: Macro result was 512
#analog_bridge
It created an out.txt file in /tmp containing a text "version"
|
|
Re: Macro result was 512
#analog_bridge
OK,
toggle quoted messageShow quoted text
Try this: D=sudo echo version >/tmp/out.txt
On 9/16/2021 7:21 AM, Geoff wrote:
I have attached two copies of dvsm.macro files.
|
|