Side project, "DMR Station" network radio

ea3ihi
Posts: 87
Joined: Fri Jan 10, 2020 9:28 pm
Location: Barcelona, Spain

Re: Side project, "DMR Station" network radio

Post by ea3ihi » Mon May 04, 2020 11:08 am

Not yet, but the instructions for the STM32..DK2 can be adapted and help as a guide to install in the raspberry. Omit any steps about adding apt sources.

MM6NRK
Posts: 67
Joined: Wed Apr 22, 2020 1:09 pm

Re: Side project, "DMR Station" network radio

Post by MM6NRK » Thu May 07, 2020 10:01 am

ea3ihi wrote:
Mon Apr 27, 2020 5:45 pm
I would like to present a new project I am working on. It is a DMR network radio. It can run on a Raspberry PI. I have borrowed some code (and a lot of inpiration) fro OpenGD77 and other projects.

You can find more about it at http://dmrstation.com

Here you have a video showing some of the features listening to the Spanish TG 214.

http://dmrstation.com/DMRStation_214.mp4

David
Thanks very much for this and is there a video how to do the install on the Rpi 3 ?

ea3ihi
Posts: 87
Joined: Fri Jan 10, 2020 9:28 pm
Location: Barcelona, Spain

Re: Side project, "DMR Station" network radio

Post by ea3ihi » Thu May 07, 2020 11:16 am

So here is my try at giving step by step instructions for the rpi:

Code: Select all

sudo apt-get update
sudo apt-get install -y libpulse-mainloop-glib0 jq
sudo ln -s /lib/ld-linux-armhf.so.3 /lib/ld-linux.so.3

sudo mkdir /opt
cd /opt
sudo wget https://github.com/ea3ihi/DMRStation-release/archive/master.zip
sudo unzip master.zip
sudo mv DMRStation-release-master DMRStation
cd DMRStation
sudo chmod a+x *.sh
sudo chmod a+x DMRstation
Now edit the configuration file DMRStation.ini with your favourite editor (use sudo as convenient)

Place a copy of md380-emu in the /opt/DMRStation folder and make sure it is executable by all users:

Code: Select all

sudo chmod a+x /opt/DMRStation/md380-emu
Test if DMRStation runs:

Code: Select all

DISPLAY=:0 ./start.sh
If it does it is a good time to add a "desktop" entry in your ./config/autostart folder:


Edit the file DMRStation.desktop in ~/.config/autostart with these contents:

Code: Select all

[Desktop Entry]
Version=1.0
Name=PulseAudio Sound System
Exec=/bin/sh -c "cd /opt/DMRStation;./start.sh"
Terminal=false
Type=Application
X-GNOME-Autostart-Phase=Initialization
NotShowIn=KDE;
Please report if all goes well, it might be the case that i have omitted some step or installation of some package that was previously done/installed in my rpi image.

MM6NRK
Posts: 67
Joined: Wed Apr 22, 2020 1:09 pm

Re: Side project, "DMR Station" network radio

Post by MM6NRK » Thu May 07, 2020 11:52 am

ea3ihi wrote:
Thu May 07, 2020 11:16 am
So here is my try at giving step by step instructions for the rpi:

Code: Select all

sudo apt-get update
sudo apt-get install -y libpulse-mainloop-glib0 jq
sudo ln -s /lib/ld-linux-armhf.so.3 /lib/ld-linux.so.3

sudo mkdir /opt
cd /opt
sudo wget https://github.com/ea3ihi/DMRStation-release/archive/master.zip
sudo unzip master.zip
sudo mv DMRStation-release-master DMRStation
cd DMRStation
sudo chmod a+x *.sh
sudo chmod a+x DMRstation
Now edit the configuration file DMRStation.ini with your favourite editor (use sudo as convenient)

Place a copy of md380-emu in the /opt/DMRStation folder and make sure it is executable by all users:

Code: Select all

sudo chmod a+x /opt/DMRStation/md380-emu
Test if DMRStation runs:

Code: Select all

DISPLAY=:0 ./start.sh
If it does it is a good time to add a "desktop" entry in your ./config/autostart folder:


Edit the file DMRStation.desktop in ~/.config/autostart with these contents:

Code: Select all

[Desktop Entry]
Version=1.0
Name=PulseAudio Sound System
Exec=/bin/sh -c "cd /opt/DMRStation;./start.sh"
Terminal=false
Type=Application
X-GNOME-Autostart-Phase=Initialization
NotShowIn=KDE;
Please report if all goes well, it might be the case that i have omitted some step or installation of some package that was previously done/installed in my rpi image.
Ok thanks so i download and put all files on sd card and then do the above .

ea3ihi
Posts: 87
Joined: Fri Jan 10, 2020 9:28 pm
Location: Barcelona, Spain

Re: Side project, "DMR Station" network radio

Post by ea3ihi » Thu May 07, 2020 12:11 pm

You don't have to copy the files to a sd card, just start with a standard rpi image, enter the system via SSH and run the step by step commands.

David

MM6NRK
Posts: 67
Joined: Wed Apr 22, 2020 1:09 pm

Re: Side project, "DMR Station" network radio

Post by MM6NRK » Thu May 07, 2020 12:50 pm

ea3ihi wrote:
Thu May 07, 2020 12:11 pm
You don't have to copy the files to a sd card, just start with a standard rpi image, enter the system via SSH and run the step by step commands.

David
Thanks for all the help and i will let you know how i get on when parts come from ebay . I have downloaded
Raspbian .

ea3ihi
Posts: 87
Joined: Fri Jan 10, 2020 9:28 pm
Location: Barcelona, Spain

Re: Side project, "DMR Station" network radio

Post by ea3ihi » Thu May 07, 2020 1:12 pm

I have not used one, but I have reports of people using orange pi instead of a raspberry pi. One of the advantages of the orange pi is that it has mic input.

SP2ONG
Posts: 45
Joined: Sat Nov 16, 2019 9:47 am

Re: Side project, "DMR Station" network radio

Post by SP2ONG » Thu May 07, 2020 4:35 pm

David,

I tried and wondered if it is possible to set the display so that the DMRStation window is displayed on my Ubuntu computer.
I logged in to Orange Pi Zero via ssh with the X w option for X11 via ssh forwarding

I set UI 800x480

export DISPLAY="192.168.1.100:0.0"

where ip address 192.168.1.100 is the address of my Ubuntu and set on UBuntu: xhost +

but when I run DMRstation there is a message

root @ ipRadio: /opt/DMRStation # ./DMRstation
Unable to init server: Cannot connect: Connection refused

(DMRstation: 2554): Gtk-WARNING **: 18: 29: 41.144: cannot open display: 192.168.1.100:0.0

It would be nice to display GTK window on our PC and use the mouse to operate instead of LCD TFT as an additional option

Do you think this is possible?

User avatar
F1RMB
Posts: 2608
Joined: Sat Nov 16, 2019 5:42 am
Location: Grenoble, France

Re: Side project, "DMR Station" network radio

Post by F1RMB » Thu May 07, 2020 5:00 pm

Hi,
SP2ONG wrote:
Thu May 07, 2020 4:35 pm
David,

I tried and wondered if it is possible to set the display so that the DMRStation window is displayed on my Ubuntu computer.
I logged in to Orange Pi Zero via ssh with the X w option for X11 via ssh forwarding

I set UI 800x480

export DISPLAY="192.168.1.100:0.0"

where ip address 192.168.1.100 is the address of my Ubuntu and set on UBuntu: xhost +

but when I run DMRstation there is a message

root @ ipRadio: /opt/DMRStation # ./DMRstation
Unable to init server: Cannot connect: Connection refused

(DMRstation: 2554): Gtk-WARNING **: 18: 29: 41.144: cannot open display: 192.168.1.100:0.0

It would be nice to display GTK window on our PC and use the mouse to operate instead of LCD TFT as an additional option

Do you think this is possible?
In order to make X11 exported display to work, you need to check on your server if X11 forwarding is enabled (/etc/ssh/sshd_config).

Then, from a terminal on your host, allow remove connections:

Code: Select all

xhost +
(not that super safe as everyone is allowed to connect your X session)

In the same terminal, ssh to your server

Code: Select all

ssh <user>@<server>
Check if the X11 formwading is set:

Code: Select all

echo $DISPLAY
by default it should be localhost:10.0

Now, from this ssh session, you can start your X11 software. Do not set the DISPLAY envvar with the IP of your host, as the port is closed by default (not that secure), but it should go through the SSH tunnel.


Cheers.
---
Daniel

SP2ONG
Posts: 45
Joined: Sat Nov 16, 2019 9:47 am

Re: Side project, "DMR Station" network radio

Post by SP2ONG » Thu May 07, 2020 5:20 pm

Daniel,

Thanks for information. My error that I set the DISPLAY variable to my Ubuntu IP, is now OK but the DMRStation window does not show up

Code: Select all

./DMRstation 
debug1: client_input_channel_open: ctype x11 rchan 4 win 65536 max 16384
debug1: client_request_x11: request from 127.0.0.1 55056
debug1: channel 1: new [x11]
debug1: confirm x11
debug1: client_input_channel_open: ctype x11 rchan 5 win 65536 max 16384
debug1: client_request_x11: request from 127.0.0.1 55058
debug1: channel 2: new [x11]
debug1: confirm x11
debug1: channel 2: FORCE input drain
debug1: channel 2: free: x11, nchannels 3
debug1: client_input_channel_open: ctype x11 rchan 5 win 65536 max 16384
debug1: client_request_x11: request from 127.0.0.1 55060
debug1: channel 2: new [x11]
debug1: confirm x11
debug1: channel 2: FORCE input drain
**
ERROR:..\src\audio.c:277:audio_init: assertion failed: (r == 0)
debug1: channel 2: free: x11, nchannels 3
debug1: channel 1: FORCE input drain
Przerwane
debug1: channel 1: free: x11, nchannels 2
cat /proc/asound/cards
0 [Codec ]: H3_Audio_Codec - H3 Audio Codec
H3 Audio Codec

aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
jack
JACK Audio Connection Kit
pulse
PulseAudio Sound Server
default
sysdefault:CARD=Codec
H3 Audio Codec, CDC PCM Codec-0
Default Audio Device
dmix:CARD=Codec,DEV=0
H3 Audio Codec, CDC PCM Codec-0
Direct sample mixing device
dsnoop:CARD=Codec,DEV=0
H3 Audio Codec, CDC PCM Codec-0
Direct sample snooping device
hw:CARD=Codec,DEV=0
H3 Audio Codec, CDC PCM Codec-0
Direct hardware device without any conversions
plughw:CARD=Codec,DEV=0
H3 Audio Codec, CDC PCM Codec-0
Hardware device with all software conversions
usbstream:CARD=Codec
H3 Audio Codec
USB Stream Output


aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: Codec [H3 Audio Codec], device 0: CDC PCM Codec-0 [CDC PCM Codec-0]
Subdevices: 1/1
Subdevice #0: subdevice #0

arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: Codec [H3 Audio Codec], device 0: CDC PCM Codec-0 [CDC PCM Codec-0]
Subdevices: 1/1
Subdevice #0: subdevice #0

Post Reply