Skip to content

Commit af2e7c9

Browse files
authored
R04H30 Merge to Master (#88)
* implement support for LC_GROUP_UPDT (this includes the RPC between the CC and VC's to announce active TG lists); completely and entirely refactor how packet handling threads are done, use a new method introduced for this, thread pool resources. this will ultimately be more resource consuming depending on configuration as the worker threads for packet processing stay alive along side the main process. this should be more performant (because we're not constantly creating and destroying threads) and will prevent error conditions that can cause an extreme number of threads to spawn; * reduce influx and V.24 thread pool sizes; add calculation of how long between when a packet was Rx to when it began proper processing; * don't use void* for the task routines; * rename ThreadPoolCallback to ThreadPoolTask; add some checking around task validness; correct a valgrind issue with RawFrameQueue() write not deleting the buffer before return; * valgrind cleanups; * gate active TG from CC to VC updates at 5s (prevent API spam); * update package version; * don't attempt to send active TG updates to 0.0.0.0; * make notification of active TGs CC -> VC optional; * correct ThreadPool issue on Win32; split UDP PCM audio processing into its own thread; implement user control of inter-audio frame delay and jitter buffer (if using inter-audio frame delay); * lock queue; * add custom classes for STL containers that support mutex locking for thread safe operation; modify ChannelLookup and AffiliationLookup to use concurrent containers; modify FNE to use concurrent containers for internal lists; * remove mutex used for protecting udp packet deque; * more concurrency solidification; * further concurrency class usage; bump version number to R04H30; * add --boot commandline argument to reboot modem into bootloader without any interactive interface; * cleanup program -h usage display; * incorrect opcode define; * update README.md; * correct incorrect string format for non-useAlternatePortForDiagnostics; * update README.md; * simplify influxdb worker task function; * refactor PL_ACT_PEER_LIST opcode entirely, use zlib and compress list sent and properly block data sent; * don't waste cycles on building the peer list repeatedly, build it once for the cycle; * deduplicate compress/decompress code into a static C++ class; * stylecop file formatting; * add table locking and remove at find; * deduplicate implementation; * cleanup unused label; change FrameQueue's unordered_map to a concurrent one; fix incorrect setting of __lock() for concurrent containers; * add more timestream map locking; * fix incorrect behavior when deriving initial timestamp for a call stream; correct incorrect behavior inserting new stream in to timestamps table for frame queue; fix incorrect behavior deriving timestamp for bridge RTP; * fix issue with naive approach to handling PL_ACT_PEER_LIST data fragementation; * disable accidental debug code; * instead of asserting, throw a log error message and discard network packet; * lock the talkgroup tables when a find is in progress (this will prevent some weird concurrency behaviors because talkgroup rules does not use the concurrent vector); * if filter headers or terminators is enabled, and the target peer is in the exclusion list, do not send headers or terminators; * exclusion check should happen before the rewrite check; * implement dvmpatch, this is a new utility that allows simple TG to TG patching; * ensure FNE downstream peers that report as peer link have implicit always rules applied to them (i.e. they will *always* receive *all* traffic); correct order of operations when deleting a peer entry (delete connection *AFTER* removing from peers table); * document concern over possible null ref concurrency issue; * don't be overly aggressive with FNE process niceness, nice of -10 is more then sufficient;
1 parent c10087e commit af2e7c9

87 files changed

Lines changed: 6310 additions & 1091 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CMakeLists.txt

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# * GPLv2 Open Source. Use is subject to license terms.
55
# * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
66
# *
7-
# * Copyright (C) 2022,2024 Bryan Biedenkapp, N2PLL
7+
# * Copyright (C) 2022,2024,2025 Bryan Biedenkapp, N2PLL
88
# * Copyright (C) 2022 Natalie Moore
99
# *
1010
# */
@@ -267,7 +267,8 @@ install(TARGETS sysview DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
267267
install(TARGETS tged DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
268268
endif (ENABLE_TUI_SUPPORT AND (NOT DISABLE_TUI_APPS))
269269
install(TARGETS dvmbridge DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
270-
install(FILES configs/config.example.yml configs/fne-config.example.yml configs/fne-sysview.example.yml configs/monitor-config.example.yml configs/iden_table.example.dat configs/RSSI.dat configs/rid_acl.example.dat configs/talkgroup_rules.example.yml configs/bridge-config.example.yml DESTINATION ${CMAKE_INSTALL_PREFIX}/etc)
270+
install(TARGETS dvmpatch DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
271+
install(FILES configs/config.example.yml configs/fne-config.example.yml configs/fne-sysview.example.yml configs/monitor-config.example.yml configs/iden_table.example.dat configs/RSSI.dat configs/rid_acl.example.dat configs/talkgroup_rules.example.yml configs/bridge-config.example.yml configs/patch-config.example.yml DESTINATION ${CMAKE_INSTALL_PREFIX}/etc)
271272
install(PROGRAMS tools/start-dvm.sh tools/stop-dvm.sh tools/dvm-watchdog.sh tools/stop-watchdog.sh tools/fne-watchdog.sh tools/start-dvm-fne.sh DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
272273
install(CODE "execute_process(COMMAND bash \"-c\" \"sed -i 's/filePath: ./filePath: \\\\/var\\\\/log\\\\//' /usr/local/etc/config.example.yml\")")
273274
install(CODE "execute_process(COMMAND bash \"-c\" \"sed -i 's/activityFilePath: ./activityFilePath: \\\\/var\\\\/log\\\\//' /usr/local/etc/config.example.yml\")")
@@ -289,13 +290,15 @@ if (NOT TARGET strip)
289290
COMMAND arm-linux-gnueabihf-strip -s sysview
290291
COMMAND arm-linux-gnueabihf-strip -s tged
291292
COMMAND arm-linux-gnueabihf-strip -s peered
292-
COMMAND arm-linux-gnueabihf-strip -s dvmbridge)
293+
COMMAND arm-linux-gnueabihf-strip -s dvmbridge
294+
COMMAND arm-linux-gnueabihf-strip -s dvmpatch)
293295
else()
294296
add_custom_target(strip
295297
COMMAND arm-linux-gnueabihf-strip -s dvmhost
296298
COMMAND arm-linux-gnueabihf-strip -s dvmfne
297299
COMMAND arm-linux-gnueabihf-strip -s dvmcmd
298-
COMMAND arm-linux-gnueabihf-strip -s dvmbridge)
300+
COMMAND arm-linux-gnueabihf-strip -s dvmbridge
301+
COMMAND arm-linux-gnueabihf-strip -s dvmpatch)
299302
endif (ENABLE_TUI_SUPPORT AND (NOT DISABLE_TUI_APPS))
300303
elseif (CROSS_COMPILE_AARCH64)
301304
if (ENABLE_TUI_SUPPORT AND (NOT DISABLE_TUI_APPS))
@@ -307,27 +310,31 @@ if (NOT TARGET strip)
307310
COMMAND aarch64-linux-gnu-strip -s sysview
308311
COMMAND aarch64-linux-gnu-strip -s tged
309312
COMMAND aarch64-linux-gnu-strip -s peered
310-
COMMAND aarch64-linux-gnu-strip -s dvmbridge)
313+
COMMAND aarch64-linux-gnu-strip -s dvmbridge
314+
COMMAND aarch64-linux-gnu-strip -s dvmpatch)
311315
else()
312316
add_custom_target(strip
313317
COMMAND aarch64-linux-gnu-strip -s dvmhost
314318
COMMAND aarch64-linux-gnu-strip -s dvmfne
315319
COMMAND aarch64-linux-gnu-strip -s dvmcmd
316-
COMMAND aarch64-linux-gnu-strip -s dvmbridge)
320+
COMMAND aarch64-linux-gnu-strip -s dvmbridge
321+
COMMAND aarch64-linux-gnu-strip -s dvmpatch)
317322
endif (ENABLE_TUI_SUPPORT AND (NOT DISABLE_TUI_APPS))
318323
elseif (CROSS_COMPILE_RPI_ARM)
319324
if (NOT WITH_RPI_ARM_TOOLS)
320325
add_custom_target(strip
321326
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/_deps/rpitools-src/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmhost
322327
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/_deps/rpitools-src/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmfne
323328
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/_deps/rpitools-src/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmcmd
324-
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/_deps/rpitools-src/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmbridge)
329+
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/_deps/rpitools-src/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmbridge
330+
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/_deps/rpitools-src/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmpatch)
325331
else()
326332
add_custom_target(strip
327333
COMMAND ${RPI_ARM_TOOLS}/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmhost
328334
COMMAND ${RPI_ARM_TOOLS}/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmfne
329335
COMMAND ${RPI_ARM_TOOLS}/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmcmd
330-
COMMAND ${RPI_ARM_TOOLS}/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmbridge)
336+
COMMAND ${RPI_ARM_TOOLS}/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmbridge
337+
COMMAND ${RPI_ARM_TOOLS}/arm-bcm2708/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-strip -s dvmpatch)
331338
endif ()
332339
else()
333340
if (ENABLE_TUI_SUPPORT AND (NOT DISABLE_TUI_APPS))
@@ -339,13 +346,15 @@ if (NOT TARGET strip)
339346
COMMAND strip -s sysview
340347
COMMAND strip -s tged
341348
COMMAND strip -s peered
342-
COMMAND strip -s dvmbridge)
349+
COMMAND strip -s dvmbridge
350+
COMMAND strip -s dvmpatch)
343351
else()
344352
add_custom_target(strip
345353
COMMAND strip -s dvmhost
346354
COMMAND strip -s dvmfne
347355
COMMAND strip -s dvmcmd
348-
COMMAND strip -s dvmbridge)
356+
COMMAND strip -s dvmbridge
357+
COMMAND strip -s dvmpatch)
349358
endif (ENABLE_TUI_SUPPORT AND (NOT DISABLE_TUI_APPS))
350359
endif (CROSS_COMPILE_ARM)
351360
endif (NOT TARGET strip)
@@ -375,6 +384,7 @@ if (NOT TARGET tarball)
375384
COMMAND cp -v peered ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
376385
COMMAND cp -v dvmfne ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
377386
COMMAND cp -v dvmbridge ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
387+
COMMAND cp -v dvmpatch ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
378388
COMMAND cp ${CMAKE_SOURCE_DIR}/tools/*.sh ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm
379389
COMMAND chmod +x ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/*.sh
380390
COMMAND cp -v ${CMAKE_SOURCE_DIR}/configs/*.yml ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm
@@ -408,6 +418,7 @@ if (NOT TARGET tarball)
408418
COMMAND cp -v dvmcmd ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
409419
COMMAND cp -v dvmfne ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
410420
COMMAND cp -v dvmbridge ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
421+
COMMAND cp -v dvmpatch ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
411422
COMMAND cp ${CMAKE_SOURCE_DIR}/tools/*.sh ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm
412423
COMMAND chmod +x ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/*.sh
413424
COMMAND cp -v ${CMAKE_SOURCE_DIR}/configs/*.yml ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm
@@ -454,6 +465,7 @@ if (NOT TARGET tarball_notools)
454465
COMMAND cp -v peered ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
455466
COMMAND cp -v dvmfne ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
456467
COMMAND cp -v dvmbridge ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
468+
COMMAND cp -v dvmpatch ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
457469
COMMAND cp -v ${CMAKE_SOURCE_DIR}/configs/*.yml ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm
458470
COMMAND mkdir -p ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/schema
459471
COMMAND cp -v ${CMAKE_SOURCE_DIR}/configs/schema/*.json ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/schema
@@ -485,6 +497,7 @@ if (NOT TARGET tarball_notools)
485497
COMMAND cp -v dvmcmd ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
486498
COMMAND cp -v dvmfne ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
487499
COMMAND cp -v dvmbridge ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
500+
COMMAND cp -v dvmpatch ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/bin
488501
COMMAND cp -v ${CMAKE_SOURCE_DIR}/configs/*.yml ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm
489502
COMMAND mkdir -p ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/schema
490503
COMMAND cp -v ${CMAKE_SOURCE_DIR}/configs/schema/*.json ${CMAKE_INSTALL_PREFIX_TARBALL}/dvm/schema
@@ -530,6 +543,7 @@ add_custom_target(old_install
530543
COMMAND install -m 755 peered ${CMAKE_LEGACY_INSTALL_PREFIX}/bin
531544
COMMAND install -m 755 dvmfne ${CMAKE_LEGACY_INSTALL_PREFIX}/bin
532545
COMMAND install -m 755 dvmbridge ${CMAKE_LEGACY_INSTALL_PREFIX}/bin
546+
COMMAND install -m 755 dvmpatch ${CMAKE_LEGACY_INSTALL_PREFIX}/bin
533547
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/config.example.yml ${CMAKE_LEGACY_INSTALL_PREFIX}/config.example.yml
534548
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/fne-config.example.yml ${CMAKE_LEGACY_INSTALL_PREFIX}/fne-config.example.yml
535549
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/fne-sysview.example.yml ${CMAKE_LEGACY_INSTALL_PREFIX}/fne-sysview.example.yml
@@ -539,6 +553,7 @@ add_custom_target(old_install
539553
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/rid_acl.example.dat ${CMAKE_LEGACY_INSTALL_PREFIX}/rid_acl.dat
540554
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/talkgroup_rules.example.yml ${CMAKE_LEGACY_INSTALL_PREFIX}/talkgroup_rules.example.yml
541555
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/bridge-config.example.yml ${CMAKE_LEGACY_INSTALL_PREFIX}/bridge-config.example.yml
556+
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/patch-config.example.yml ${CMAKE_LEGACY_INSTALL_PREFIX}/patch-config.example.yml
542557
COMMAND install -m 644 ${CMAKE_SOURCE_DIR}/configs/schema/talkgroup_rules.yaml_schema.json ${CMAKE_LEGACY_INSTALL_PREFIX}/schema/talkgroup_rules.yaml_schema.json
543558
COMMAND install -m 755 ${CMAKE_SOURCE_DIR}/tools/start-dvm.sh ${CMAKE_LEGACY_INSTALL_PREFIX}
544559
COMMAND install -m 755 ${CMAKE_SOURCE_DIR}/tools/stop-dvm.sh ${CMAKE_LEGACY_INSTALL_PREFIX}
@@ -581,6 +596,7 @@ add_custom_target(old_install-service
581596
COMMAND chown dvmhost:dvmhost ${CMAKE_LEGACY_INSTALL_PREFIX}/rid_acl.example.dat
582597
COMMAND chown dvmhost:dvmhost ${CMAKE_LEGACY_INSTALL_PREFIX}/talkgroup_rules.example.yml
583598
COMMAND chown dvmhost:dvmhost ${CMAKE_LEGACY_INSTALL_PREFIX}/bridge-config.example.yml
599+
COMMAND chown dvmhost:dvmhost ${CMAKE_LEGACY_INSTALL_PREFIX}/patch-config.example.yml
584600
COMMAND chown dvmhost:dvmhost ${CMAKE_LEGACY_INSTALL_PREFIX}/log
585601
COMMAND cp ../linux/dvmhost.service /lib/systemd/system/
586602
COMMAND bash \"-c\" \"sed -i 's/\\\\/usr\\\\/local\\\\/bin/\\\\/opt\\\\/dvm\\\\/bin/' /lib/systemd/system/dvmhost.service\"

README.md

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ This project suite generates a few executables:
1515
- `dvmhost` host software that connects to the DVM modems (both air interface for repeater and hotspot or P25 DFSI for commerical P25 hardware) and is the primary data processing application for digital modes. [See configuration](#dvmhost-configuration) to configure and calibrate.
1616
- `dvmfne` a network "core", this provides a central server for `dvmhost` instances to connect to and be networked with, allowing relay of traffic and other data between `dvmhost` instances and other `dvmfne` instances. [See configuration](#dvmfne-configuration) to configure.
1717
- `dvmbridge` a analog/PCM audio bridge, this provides the capability for analog or PCM audio resources to be connected to a `dvmfne` instance, allowing realtime vocoding of traffic. [See configuration](#dvmbridge-configuration) to configure.
18+
- `dvmpatch` a talkgroup patching utility, this provides the capability to manually patch talkgroups of the same digital mode together. [See configuration](#dvmpatch-configuration) to configure.
1819
- `dvmcmd` a simple command-line utility to send remote control commands to a `dvmhost` or `dvmfne` instance with REST API configured.
1920

2021
### Supplementary Support Applications
@@ -215,12 +216,18 @@ using the command line parameter `-wasapi` will force `dvmbridge` to utilize WAS
215216
216217
There is no other real configuration for a `dvmbridge` instance other then setting the appropriate parameters within the configuration files.
217218
219+
## dvmpatch Configuration
220+
221+
This source repository contains configuration example files within the configs folder, please review `patch-config.example.yml` for the `dvmpatch` for details on various configurable options.
222+
223+
There is no other real configuration for a `dvmpatch` instance other then setting the appropriate parameters within the configuration files.
224+
218225
## Command Line Parameters
219226
220227
### dvmhost Command Line Parameters
221228
222229
```
223-
usage: ./dvmhost [-vhdf][--syslog][--setup][-c <configuration file>][--remote [-a <address>] [-p <port>]]
230+
usage: ./dvmhost [-vhdf] [--syslog] [--setup] [--cal][--boot] [-c <configuration file>] [--remote [-a <address>] [-p <port>]]
224231

225232
-v show version information
226233
-h show this screen
@@ -229,13 +236,17 @@ usage: ./dvmhost [-vhdf][--syslog][--setup][-c <configuration file>][--remote [-
229236

230237
--syslog force logging to syslog
231238

232-
--setup setup and calibration mode
239+
--setup TUI setup and calibration mode
240+
241+
--cal simple calibration mode
242+
--boot connects to modem and reboots into bootloader mode
233243

234244
-c <file> specifies the configuration file to use
235245

236246
--remote remote modem mode
237247
-a remote modem command address
238248
-p remote modem command port
249+
-P remote modem command port (local listening port)
239250

240251
-- stop handling options
241252
```
@@ -281,6 +292,20 @@ Audio Output Devices:
281292
... <list of audio output devices> ...
282293
```
283294
295+
### dvmpatch Command Line Parameters
296+
297+
```
298+
usage: ./dvmpatch [-vhf][-c <configuration file>]
299+
300+
-v show version information
301+
-h show this screen
302+
-f foreground mode
303+
304+
-c <file> specifies the configuration file to use
305+
306+
-- stop handling options
307+
```
308+
284309
### dvmcmd Command Line Parameters
285310
286311
```

configs/bridge-config.example.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,17 @@ network:
8080
# Flag indicating UDP audio should follow the USRP format.
8181
udpUsrp: false
8282

83+
# Delay in-between UDP audio frames (in ms).
84+
# (Some applications will send RTP/PCM audio too fast, requiring a delay in-between packets to
85+
# be added for appropriate IMBE audio pacing. For most cases a 20ms delay will properly pace
86+
# audio frames. If set to 0, no frame pacing or jitter buffer will be applied and audio will be
87+
# encoded as fast as it is received.)
88+
udpInterFrameDelay: 0
89+
# Jitter Buffer Length (in ms).
90+
# (This is only applied if utilizing inter frame delay, otherwise packet timing is assumed to be
91+
# properly handled by the source.)
92+
udpJitter: 200
93+
8394
# Flag indicating the UDP audio will be padded with silence during hang time before end of call.
8495
udpHangSilence: true
8596

configs/config.example.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,8 @@ protocols:
216216
interval: 300
217217
# Amount of time to transmit non-dedicated CC broadcasts. (seconds)
218218
duration: 1
219+
# Flag indicating this CC will notify VCs of active TGIDs.
220+
notifyActiveTG: false
219221
# Flag to disable TSDU triple-block transmissions and instead transmit single-block TSDUs.
220222
disableTSDUMBF: false
221223
# Flag to enable optional TIME_DATE_ANNC TSBK during a CC broadcast.

configs/fne-config.example.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ master:
4646
# Flag indicating whether or not verbose debug logging is enabled.
4747
debug: false
4848

49+
# Maximum number of concurrent packet processing workers.
50+
workers: 16
51+
4952
# Maximum permitted connections (hard maximum is 250 peers).
5053
connectionLimit: 100
5154

configs/patch-config.example.yml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
#
2+
# Digital Voice Modem - TG Patch
3+
#
4+
5+
# Flag indicating whether the host will run as a background or foreground task.
6+
daemon: true
7+
8+
#
9+
# Logging Configuration
10+
#
11+
# Logging Levels:
12+
# 1 - Debug
13+
# 2 - Message
14+
# 3 - Informational
15+
# 4 - Warning
16+
# 5 - Error
17+
# 6 - Fatal
18+
#
19+
log:
20+
# Console display logging level (used when in foreground).
21+
displayLevel: 1
22+
# File logging level.
23+
fileLevel: 1
24+
# Flag indicating file logs should be sent to syslog instead of a file.
25+
useSyslog: false
26+
# Full path for the directory to store the log files.
27+
filePath: .
28+
# Full path for the directory to store the activity log files.
29+
activityFilePath: .
30+
# Log filename prefix.
31+
fileRoot: dvmpatch
32+
33+
#
34+
# Network Configuration
35+
#
36+
network:
37+
# Network Peer ID
38+
id: 9000123
39+
# Hostname/IP address of FNE master to connect to.
40+
address: 127.0.0.1
41+
# Port number to connect to.
42+
port: 62031
43+
# FNE access password.
44+
password: RPT1234
45+
46+
# Flag indicating whether or not host endpoint networking is encrypted.
47+
encrypted: false
48+
# AES-256 32-byte Preshared Key
49+
# (This field *must* be 32 hex bytes in length or 64 characters
50+
# 0 - 9, A - F.)
51+
presharedKey: "000102030405060708090A0B0C0D0E0F000102030405060708090A0B0C0D0E0F"
52+
53+
# Flag indicating whether or not the host diagnostic log will be sent to the network.
54+
allowDiagnosticTransfer: true
55+
56+
# Flag indicating whether or not verbose debug logging is enabled.
57+
debug: false
58+
59+
# Source Talkgroup ID for transmitted/received audio frames.
60+
sourceTGID: 1
61+
# Source Slot for received/transmitted audio frames.
62+
sourceSlot: 1
63+
# Destination Talkgroup ID for transmitted/received audio frames.
64+
destinationTGID: 1
65+
# Destination Slot for received/transmitted audio frames.
66+
destinationSlot: 1
67+
68+
# Flag indicating whether or not the patch is two-way.
69+
twoWay: false
70+
71+
system:
72+
# Textual Name
73+
identity: PATCH
74+
75+
# Digital mode (1 - DMR, 2 - P25).
76+
digiMode: 1
77+
78+
# Flag indicating whether or not trace logging is enabled.
79+
trace: false
80+
# Flag indicating whether or not debug logging is enabled.
81+
debug: false

src/CMakeLists.txt

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ set(CPACK_PACKAGE_VENDOR "DVMProject")
6060

6161
set(CPACK_DEBIAN_PACKAGE_DESCRIPTION "The DVM Host software provides the host computer implementation of a mixed-mode DMR, P25 and/or NXDN or dedicated-mode DMR, P25 or NXDN repeater system that talks to the actual modem hardware. The host software; is the portion of a complete Over-The-Air modem implementation that performs the data processing, decision making and FEC correction for a digital repeater.")
6262
set(CPACK_DEBIAN_PACKAGE_MAINTAINER "DVMProject Authors")
63-
set(CPACK_DEBIAN_PACKAGE_VERSION "R04Axx")
63+
set(CPACK_DEBIAN_PACKAGE_VERSION "R04Hxx")
6464
set(CPACK_DEBIAN_PACKAGE_RELEASE "0")
6565
set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "https://github.com/dvmproject")
6666

@@ -142,3 +142,15 @@ else ()
142142
target_link_libraries(dvmbridge PRIVATE common vocoder ${OPENSSL_LIBRARIES} dl asio::asio Threads::Threads)
143143
endif (COMPILE_WIN32)
144144
target_include_directories(dvmbridge PRIVATE ${OPENSSL_INCLUDE_DIR} src src/bridge)
145+
146+
#
147+
## dvmpatch
148+
#
149+
include(src/patch/CMakeLists.txt)
150+
add_executable(dvmpatch ${common_INCLUDE} ${patch_SRC})
151+
if (COMPILE_WIN32)
152+
target_link_libraries(dvmpatch PRIVATE common ${OPENSSL_LIBRARIES} asio::asio Threads::Threads)
153+
else ()
154+
target_link_libraries(dvmpatch PRIVATE common ${OPENSSL_LIBRARIES} dl asio::asio Threads::Threads)
155+
endif (COMPILE_WIN32)
156+
target_include_directories(dvmpatch PRIVATE ${OPENSSL_INCLUDE_DIR} src src/patch)

src/CompilerOptions.cmake

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ option(DEBUG_P25_DFSI "" off)
4646
option(DEBUG_RINGBUFFER "" off)
4747
option(DEBUG_HTTP_PAYLOAD "" off)
4848
option(DEBUG_TRELLIS "" off)
49+
option(DEBUG_COMPRESS "" off)
4950

5051
if (DEBUG_DMR_PDU_DATA)
5152
message(CHECK_START "DMR PDU Data Debug")
@@ -139,6 +140,10 @@ if (DEBUG_TRELLIS)
139140
message(CHECK_START "Trellis Encoding Debug")
140141
add_definitions(-DDEBUG_TRELLIS)
141142
endif (DEBUG_TRELLIS)
143+
if (DEBUG_COMPRESS)
144+
message(CHECK_START "zlib Compression Debug")
145+
add_definitions(-DDEBUG_COMPRESS)
146+
endif (DEBUG_COMPRESS)
142147

143148
set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake")
144149
find_package(Threads REQUIRED)

0 commit comments

Comments
 (0)