DV4mini and Raspberry Pi 
How to install and operate

DV4mini (70cm or 2m) is a tiny but powerful USB stick that can change any PC into a HOTSPOT.
It does not require its own power supply as it is powered through the USB interface. It is being shipped with a comprehensive but simple to use software package which allows for the linking with DCS reflectors for D-Star,C4FM and DMR reflectors.

Supported operating modes:

D-Star, DMR+, C4FM-Fusion
and experimental versions:
...read more on the official homepage of the DV4mini.

You can either follow my instructions and use your own distribution or you can download a preconfigured RasPi Operating System from DARC Ortsverband A-23 to start operation more quickly.

What to need, and what to do:

We need a Raspberry Pi 3B, a 5V 2.5A power supply with micro-USB connector, a LAN patch cable with RJ-45 connectors and an DV4mini stick (in this case for 70cm band) with antenna.
For a permanent and mobile installation eventually a power bank and at least a case for the RasPi.
To store the operating system a 16GB SD card (class 10) is recommended.

Prepare Operating System:
Download the image of Ubuntu Mate 16.04.2 from Ubuntu Download page.
Unpack the archive
$ unxz Ubuntu-mate-xxx.img.xz # to get the .img file

Installing Image on SD Card:

$ df -h       # which devices are installed ? #
/dev/sd?1       7.5G   32K  7.5G   1% /media/suslab/31E9-9026

If you have identified dev name of the SD Card please change the name in the 
following lines accordingly to /dev/????...

$ umount /dev/sd?1    # don't click om the arrow in the file manager to unmount

$ cd Downloads

$ sudo dd bs=4M if=Ubuntu-mate-xxx.img of=/dev/sd?
331+1 records in
331+1 records out
1390411776 bytes (1.4 GB, 1.3 GiB) copied, 106.118 s, 13.1 MB/s

$ sync                 # write buffer to card
Now the operating system is ready to boot the RasPi. Attaching screen, keyboard and mouse makes the following work a little bit easier. I had forgotten to check if SSH is enabled, so I had some steps more to do.

Installing SSH
see Enable SSH on boot in Raspberry Pi Ubuntu MATE

Setting up SSH
$    sudo apt-get update
$    sudo apt-get install openssh-server
$    sudo ufw allow 22
$    sudo /etc/init.d/ssh restart
Enabling SSH on boot
$    sudo systemctl enable ssh

Installing XRDP for Remote Access from Linux

$    sudo apt-get install xrdphttps://www.remmina.org/wp/

Access from Linux system is possible using REMMINA or a similar program.

Network manual installation:
First check with $ ifconfig the names of your network ports. Then follow the instructions on page Configure static IP address on Ubuntu 16.04 LTS.

Stabilizing Clock:
Since Ubuntu 15.04 the standard mechanism for adjusting the clock has changed. But switch back to NTP should be an advantage, so please follow How To Set Up Time Synchronization on Ubuntu 16.04 to synchronize the clock.
use following entry instead of the proposal for time server:
server 0.at.pool.ntp.org iburst
server 1.at.pool.ntp.org iburst
server 2.at.pool.ntp.org iburst
server 3.at.pool.ntp.org iburst
"at" stands for Austria and can be replaced depending of location of the computer.
If there are more special necessity for time precision use the IEEE PTP protocol (ask Google) and eventually an external GPS module.

After reboot of the system check if NTPD (NTP daemon ) is running:
$ ps -ef |grep ntpd
user 10635 1432 0 16:07 pts/0 00:00:00 grep --color=auto ntpd

In this case NTPD is not running.
$ sudo systemctl start ntp.service # start NTP service

Check from new if NTPD process is running. If not please follow the special remarks.

Install DV4mini Software:
Download the Software from DV4mini home.

$    mkdir dv4mini      # create new folder
$    cd dv4mini
$    cp /home/{user}/Downloads/DV4mini.zip .
$    unzip DV4mini.zip

Install "Mono" to execute dv4mini:
$    sudo apt-get install mono-complete

First start 
$    ./dv_serial        # searches for the stick
                        # must have be started in advance of
                        # dv4mini.exe
$    mono dv4mini.exe
and follow the hints for setting up DV4mini Software and your radio or handy talker.
After each restart of the operating system dv_serial has to be started first. It is possible to automate this function creating a service.

Create file dv4serial.service in folder /etc/systemd/system



Add symbolic link in folder
$    cd /etc/systemd/system/default.target.wants
$    sudo ln -s /etc/systemd/system/dv4serial.service

$    sudo systemctl daemon-reload    # rerun daemon

Now the start while system startup should work.

Start and stop your service using
$    sudo systemctl stop dv4serial.service
$    sudo systemctl start dv4serial.service

Configure DMR Operation:
DMR uses the same frequency for RX/TX. Choose a possible simplex frequency from band plan!

screen shot
Extended Configuration page for DMR operation - click for more information

screen shot
Main Configuration page for DMR operation - click for more information

Configure DMR Radio:
To make it possible to change between two reflectors I programmed two entries as you see in the following pictures. Changes where in the field "Contact Name", TX and RX frequency is always the same. Power should be minimum possible.

View into Codeplug - click for more information

View into Codeplug - click for more information

Configure C4FM Operation:
For C4FM operation I used a repeater frequency not used in my region because I had not to change programming of the handy talker. The same repeater shift as already programmed can be used.

Extended Configuration page for C4FM operation - click for more information

Main Configuration page for C4FM operation - click for more information

Configure C4FM Radio:
In my case there was nothing to do. Maybe for changing rooms.

Further information to the same topic:
see also draft-3-of-how-to by KB8AOB.

Last changes 2017-12-25 G. Pechoc


OE1GPA Homepage

DV4mini home
DV4mini RasPi Operating System
DV4mini Windows Installation
RadioPimonitor_v3.5 by OE1GPA

Register Callsign