Skip to content

xsystemgr/dmrlib

Repository files navigation

dmrlib

C library for Digital Mobile Radio

Build Status

About

dmrlib is a C library for building Digital Mobile Radio applications, included are a couple of utilities that build on dmrlib.

These applications are for educational purposes and should be used by licensed HAM radio operators, commercial use is strictly prohibited.

Compiling

The following software is required to compile dmrlib:

If you enable the mbelib proto (--enable-mbe-proto):

If you enable the dmrdump utility (--enable-dmrdump):

To compile dmrlib, you just run scons:

$ scons

To compile dmrlib for debugging:

$ scons --with-debug

This should result with libdmr built in the build directory.

Compiling on Linux

On Debian (compatible) systems, you need the following packages:

~$ sudo apt-get install gcc scons git libtalloc-dev

For the mbe proto:

~$ sudo apt-get install libpcap-dev

For the dmrdump utility:

~$ sudo apt-get install portaudio-dev

Now clone the repository and build the software:

~$ git clone https://github.com/pd0mz/dmrlib
...
~$ cd dmrlib
dmrlib$ scons
...

Compiling on OS X

Using Homebrew, you need the following packages:

~$ brew install scons talloc

For the mbe proto:

~$ brew install portaudio

For the dmrdump utility:

~$ brew install pcap

See compiling on Linux on how to build dmrlib.

Compiling on Windows

Tested to work with the Minimalist GNU for Windows (MinGW) compiler. You also need to get these packages:

Make sure you install the Git Bash shell when prompted in the installer.

Start the Git Bash shell, then enter:

~$ git clone https://github.com/pd0mz/dmrlib
...
~$ cd dmrlib
dmrlib$ /c/Python27/Scripts/scons.bat
...

Contributing

Check out https://github.com/pd0mz/dmrlib

Supported features

Cyclic Redundancy Checks

Algorithm Encoding Decoding
CRC-5
CRC-9 👍 👍
CRC-16 (CCITT) 👍 👍
CRC-32 👍 👍

(Forward) Error Correction

Algorithm Encoding Decoding
Block Product Turbo Code (196, 96) 👍 👍
Hamming (7,4,3) 👍 👍
Hamming (13,9,3) 👍 👍
Hamming (15,11,3) 👍 👍
Hamming (16,11,4) 👍 👍
Hamming (17,12,3) 👍 👍
Golay (20, 8) 👍 👍
Quadratic Residue (16, 7, 6) 👍 👍
Reed-Solomon (12, 9, 4) 2 👍 👍
Rate ¾ Trellis
Variable length BPTC 👍 👍
  1. Full Hamming error correction not yet available
  2. Simplified form, shortened syndrome not implemented

DMR Data Types

Data Type Encoding Decoding
Privacy Indicator
Voice Link Control 👍 👍
Terminator with Link Control
Control Signaling Block
Multiple Block Control
Data Header
Rate
Rate ¾ Data
Idle
Voice 1 👍 👍
  1. Depends on the availability of compatible hardware and/or software

Acknowledgements

The development of dmrlib wasn't possible without the help of the following people:

Bugs

You can use the issue tracker to file bug reports and feature requests.