Topics

Analog_Bridge and tune.sh script #analog_bridge


SP2ONG Waldek
 

Hi Steve

I use the attached tuns.sh script to switch groups in Ananlog_Bridge. This script is a part of your tune.sh script.
Sometimes it happens that after using this script, the repeaterID gatewayDmrId is reset to 0
As a result, when it is transmits by AB on the new talk group, the DMRID  for source and transmiter  is 0

I do not know if you also had such situations?

73 Waldek


Steve N4IRS
 

I have not seen this happen.

On 7/10/2019 3:30 AM, Waldek SP2ONG wrote:
Hi Steve

I use the attached tuns.sh script to switch groups in Ananlog_Bridge. This script is a part of your tune.sh script.
Sometimes it happens that after using this script, the repeaterID gatewayDmrId is reset to 0
As a result, when it is transmits by AB on the new talk group, the DMRID  for source and transmiter  is 0

I do not know if you also had such situations?

73 Waldek


SP2ONG Waldek
 

This happens when the mmdv_bridge restart is done and then this script will be used


Steve N4IRS
 

I'll have to test this.

On 7/10/2019 10:44 AM, Waldek SP2ONG wrote:
This happens when the mmdv_bridge restart is done and then this script will be used


Steve N4IRS
 

I don't restart MB. I keep all modes enabled and restart AB with the proper mode enabled.

On 7/10/2019 10:44 AM, Waldek SP2ONG wrote:
This happens when the mmdv_bridge restart is done and then this script will be used


Steve N4IRS
 

Are you sending the tune command to AB or MB?

On 7/10/2019 10:44 AM, Waldek SP2ONG wrote:
This happens when the mmdv_bridge restart is done and then this script will be used


SP2ONG Waldek
 

I have use part of your script tune.sh where is:

_sock.sendto(cmd, ('127.0.0.1', 31100))


Steve N4IRS
 

That does not tell me WHAT program is listening on UDP port 31100. You can send a tune command to either AB or MB.

On 7/10/2019 11:49 AM, Waldek SP2ONG wrote:
I have use part of your script tune.sh where is:

_sock.sendto(cmd, ('127.0.0.1', 31100))


SP2ONG Waldek
 

OK Steve

In AB:

[AMBE_AUDIO]
address = 127.0.0.1                      ; IP address of xx_Bridge.py
TXPort = 31103                          ; Transmit TLV frames to partner on this port
RXPort = 31100                          ; Listen for TLV frames from partner on this port


in  MB DVSwitch:
[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

The script
================================
#!/bin/bash

function tune() {
    echo "Tuning to TG $1"
python - <<END
#!/usr/bin/env python
import sys
import socket
import struct
cmd = "txTg=$1"
_sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
cmd = struct.pack("BB", 0x05, len(cmd))[0:2] + cmd
_sock.sendto(cmd, ('127.0.0.1', 31100))
_sock.close()
END
}

tune $1
======================


It is looks I have sent to AB because RXPort is 31100


Steve N4IRS
 

So,
After all that, you are sending the command to AB which is listening on port 31100.

On 7/10/2019 1:17 PM, Waldek SP2ONG wrote:
OK Steve

In AB:

[AMBE_AUDIO]
address = 127.0.0.1                      ; IP address of xx_Bridge.py
TXPort = 31103                          ; Transmit TLV frames to partner on this port
RXPort = 31100                          ; Listen for TLV frames from partner on this port


in  MB DVSwitch:
[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

The script
================================
#!/bin/bash

function tune() {
    echo "Tuning to TG $1"
python - <<END
#!/usr/bin/env python
import sys
import socket
import struct
cmd = "txTg=$1"
_sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
cmd = struct.pack("BB", 0x05, len(cmd))[0:2] + cmd
_sock.sendto(cmd, ('127.0.0.1', 31100))
_sock.close()
END
}

tune $1
======================


It is looks I have sent to AB because RXPort is 31100


SP2ONG Waldek
 

Yes, exactly.


Steve N4IRS
 

OK,
I'll test when I get a chance.

On 7/10/2019 2:42 PM, Waldek SP2ONG wrote:
Yes, exactly.


Tom Corcoran
 


-- I enter new TG directly in DVSmobile. Can you please advise how I would use scripts?
Tnx ... Tom VE3NY


SP2ONG Waldek
 

Tom,

I use MB / AB to play  newsletters, emcom alerts, etc which are recorded in wav files., and I need to change TG in scripts that are call  in crontab


73 Waldek