DMRlink <-> HBlink communication


Peter M0NWI
 

Mike,

Can I ask about the template file.  Back in time chatting to Cort, we discussed DMRlink having a template based system so adding more repeater manufacturers would be a simpler task, identify the strings required for each type got the template, group voice etc, and hopefully the Ambe data will fit into another manufacturers frame type.

The reason I ask is that I've gotten hold of a Hytera DMR repeater, and wondered if there might be some mileage in adding this to the types offered by DVSwitch?

73,
Peter

Sent from Outlook
From: DVSwitch@groups.io <DVSwitch@groups.io> on behalf of Mike Zingman - N4IRR <mike.zingman@...>
Sent: 13 July 2017 18:55:29
To: DVSwitch@groups.io
Subject: Re: [DVSwitch] DMRlink <-> HBlink communication
 
The template file is a requirement for creating IPSC frames from the bridge.  


Vance, W6SS
 

All appears to be working, THANK YOU very much for all your help.  I have been looking for this functionality for a long time.  It beats putting a repeater in your car when you travel.
--
Vance W6SS


Steve N4IRS
 
Edited

IPSC_Bridge:
-rw-r--r--  1 root root  6543 Jul 13 13:05 dmrlink.cfg
-rwxr-xr-x  1 root root 52232 Jul 13 10:02 dmrlink.py
drwxr-xr-x  2 root root  4096 Jul 13 13:05 ipsc
-rw-r--r--  1 root root   581 Jul 13 10:02 IPSC_Bridge.cfg
-rw-r--r--  1 root root 14482 Jul 13 10:02 IPSC_Bridge.py
-rw-r--r--  1 root root 54622 Jul 13 10:02 template.bin

HB_Bridge:
-rw-r--r--  1 root root   593 Jul 13 10:03 HB_Bridge.cfg
-rw-r--r--  1 root root 10874 Jul 13 10:03 HB_Bridge.py
-rwxr-xr-x  1 root root  8414 Jul 13 10:03 hb_config.py
-rwxr-xr-x  1 root root  1650 Jul 13 10:03 hb_const.py
-rw-r--r--  1 root root  3486 Jul 13 11:17 hblink.cfg
-rwxr-xr-x  1 root root 29037 Jul 13 10:03 hblink.py
-rwxr-xr-x  1 root root  3479 Jul 13 10:03 hb_log.py



On 7/13/2017 1:53 PM, w6ss@... wrote:
Do I need the template.py file?  I can now transmit to the C-Bridge but not getting any audio.

Probably what I need is a listing of files for /opt/dmrlink/bridge and /opt/HBlink
--
Vance W6SS


Mike Zingman - N4IRR
 

The template file is a requirement for creating IPSC frames from the bridge.  


Vance, W6SS
 

Do I need the template.py file?  I can now transmit to the C-Bridge but not getting any audio.

Probably what I need is a listing of files for /opt/dmrlink/bridge and /opt/HBlink
--
Vance W6SS


Mike Zingman - N4IRR
 

In the short term I will make this a fatal error.  In the longer term, I will convert over to use the static values Cort was so kind to convert for me.
HB will not have the same problem since it does not use templates.


Steve N4IRS
 

It goes in the same directory as IPSC_Bridge.py

Mike called it (what a surprise)

Without template.bin
INFO 2017-07-13 13:17:33,862 DMRlink 'IPSC_Bridge.py' (c) 2015 N0MJS & the K0USY Group - SYSTEM STARTING...
INFO 2017-07-13 13:17:33,863 Version 20170620
INFO 2017-07-13 13:17:33,864 ID ALIAS MAPPER: 'peer_ids.csv' is current, not downloaded
INFO 2017-07-13 13:17:33,865 ID ALIAS MAPPER: 'subscriber_ids.csv' is current, not downloaded
INFO 2017-07-13 13:17:33,932 ID ALIAS MAPPER: peer_ids dictionary is available
INFO 2017-07-13 13:17:34,563 ID ALIAS MAPPER: subscriber_ids dictionary is available
INFO 2017-07-13 13:17:34,564 (DMR-MARC) IPSC Instance Created: 311246, 0.0.0.0:50022
INFO 2017-07-13 13:17:34,566 section = DMR-MARC
INFO 2017-07-13 13:17:34,567 Section DMR-MARC was not found, using DEFAULTS
INFO 2017-07-13 13:17:34,568 gateway = 127.0.0.1
INFO 2017-07-13 13:17:34,568 toGatewayPort = 31003
INFO 2017-07-13 13:17:34,569 fromGatewayPort = 31000
INFO 2017-07-13 13:17:34,570 DMRLink IPSC Bridge
ERROR 2017-07-13 13:17:34,572 Can not open template.bin file

Unhandled Error
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/twisted/python/log.py", line 73, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 118, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 81, in callWithContext
    return func(*args,**kw)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/posixbase.py", line 614, in _doReadOrWrite
    why = selectable.doRead()
--- <exception caught here> ---
  File "/usr/lib/python2.7/dist-packages/twisted/internet/udp.py", line 246, in doRead
    self.protocol.datagramReceived(data, addr)
  File "/usr/local/lib/python2.7/dist-packages/dmr_utils/ambe_bridge.py", line 184, in datagramReceived
    self.func(_data, (_host, _port))
  File "/usr/local/lib/python2.7/dist-packages/dmr_utils/ambe_bridge.py", line 261, in import_datagramReceived
    self.send_voice_header(_rx_slot)
  File "/usr/local/lib/python2.7/dist-packages/dmr_utils/ambe_bridge.py", line 526, in send_voice_header
    self.rewriteFrame(self._tempHead[i], _rx_slot.slot, _rx_slot.dst_id, _rx_slot.rf_src, _rx_slot.repeater_id)
  File "/usr/local/lib/python2.7/dist-packages/dmr_utils/ambe_bridge.py", line 562, in rewriteFrame
    _peerid         = _frame[1:5]                 # int32 peer who is sending us a packet
exceptions.TypeError: 'int' object has no attribute '__getitem__'

With template.bin
It works!

Steve N4IRS


On 7/13/2017 1:16 PM, Corey Dean N3FE wrote:
It goes directly in the dmrlink folder.

On Thu, Jul 13, 2017 at 1:14 PM, <w6ss@...> wrote:
I found template.bin, does it go in the /opt/dmrlink/bridge directory?
--
Vance W6SS



Corey Dean N3FE <n3fe@...>
 

It goes directly in the dmrlink folder.

On Thu, Jul 13, 2017 at 1:14 PM, <w6ss@...> wrote:
I found template.bin, does it go in the /opt/dmrlink/bridge directory?
--
Vance W6SS



Vance, W6SS
 

I found template.bin, does it go in the /opt/dmrlink/bridge directory?
--
Vance W6SS


Steve N4IRS
 

On 7/13/2017 1:07 PM, w6ss@... wrote:
I do not have template.bin, where do I find it?
--
Vance W6SS


Vance, W6SS
 

I do not have template.bin, where do I find it?
--
Vance W6SS


Vance, W6SS
 

Than you, not having the rules files make it much easier.  Will wait what to find out from your testing.
--
Vance W6SS


Mike Zingman - N4IRR
 

Just to make sure, you *do* have template.bin in the dmrlink directory, right?
Can you look back at the start of your log for any error message like:
Can not open template.bin file

Mike


Steve N4IRS
 

Vance,
I am chasing it now. Just to be clear:
hb_routing_rules are not used by basic HB to IPSC. Just HB_Bridge and IPSC_Bridge
It looks like this:
MMDVM <---> HB_Bridge <---> IPSC_Bridge <---> C-bridge

The only configuration files involved are:
HB_Bridge.cfg
hblink.cfg

IPSC_Bridge.cfg
dmrlink.cfg

You start HB_Bridge with "python HB_Bridge.py"
You start IPSC_Bridge with python IPSC_Bridge.py"

I am retesting the configuration now.


73, Steve N4IRS


On 7/13/2017 12:34 PM, w6ss@... wrote:
I am running HB_Bridge and IPSC_Bridge and have upgraded the dmr_utils.  I have one TG routed both ways in hb_routing_rules.py and hb_routing_rules.py.   HB_Bridge.cfg the TG has been added.

I can hear the traffic coming from the C-Bridge on the OpenSpot connected to the HB Master.  When I transmit back from the OpenSpot I get the error messages that NZ6D gets.

Any ideas?
--
Vance W6SS


Vance, W6SS
 

I am running HB_Bridge and IPSC_Bridge and have upgraded the dmr_utils.  I have one TG routed both ways in hb_routing_rules.py and hb_routing_rules.py.   HB_Bridge.cfg the TG has been added.

I can hear the traffic coming from the C-Bridge on the OpenSpot connected to the HB Master.  When I transmit back from the OpenSpot I get the error messages that NZ6D gets.

Any ideas?
--
Vance W6SS


Corey Dean N3FE <n3fe@...>
 

screen is a program that you can run up front and then disconnect from it as needed and still keep the software running. It is the same way you can autostart mmdvm. This is totally different from actual display screens.

Sent from my iPhone

On Jul 12, 2017, at 8:43 PM, Bob kc2cwt <kc2cwt@kc2cwt.net> wrote:

I run Kubuntu and have 4 screens

Thanks



On 07/12/2017 08:39 PM, Steve N4IRS wrote:
program called "screen
--
Bob KC2CWT
Carmel NewYork USA
(914)497-5502




Steve N4IRS
 

The program screen runs on the server.

On 07/12/2017 08:43 PM, Bob kc2cwt wrote:
I run Kubuntu and have 4 screens

Thanks



On 07/12/2017 08:39 PM, Steve N4IRS wrote:
program called "screen


Bob kc2cwt
 

I run Kubuntu and have 4 screens

Thanks

On 07/12/2017 08:39 PM, Steve N4IRS wrote:
program called "screen
--
Bob KC2CWT
Carmel NewYork USA
(914)497-5502


Steve N4IRS
 

There were multiple copies of hblink.py running. I ran both with no problem. You should look into the program called "screen" so you can run a program in the foreground and if the connection drops you can re-connect to the screen.

On 07/12/2017 08:24 PM, Bob kc2cwt wrote:

sent it to you telgram



On 07/12/2017 08:00 PM, Steve N4IRS wrote:
What TS/TG?
I assume:
MMDVM <---> HB_Bridge <---> IPSC_Bridge <---> Master

Steve

On 07/12/2017 07:51 PM, David Griffith NZ6D wrote:
All is up to date...No difference. it doesn't crash IPSC_Bridge just logs to console. I still cant TX from client to MASTER but can hear traffic on TG through the client (MMDVM). I will keep looking around. Thank you for all the help guys/

NZ6D Dave


-- 
Bob KC2CWT
Carmel NewYork USA
(914)497-5502


Bob kc2cwt
 

sent it to you telgram



On 07/12/2017 08:00 PM, Steve N4IRS wrote:
What TS/TG?
I assume:
MMDVM <---> HB_Bridge <---> IPSC_Bridge <---> Master

Steve

On 07/12/2017 07:51 PM, David Griffith NZ6D wrote:
All is up to date...No difference. it doesn't crash IPSC_Bridge just logs to console. I still cant TX from client to MASTER but can hear traffic on TG through the client (MMDVM). I will keep looking around. Thank you for all the help guys/

NZ6D Dave


-- 
Bob KC2CWT
Carmel NewYork USA
(914)497-5502