Skip to content

Commit b8919ba

Browse files
authored
Merge branch 'dev' into gpiod
2 parents 81d11c5 + 30869c7 commit b8919ba

File tree

147 files changed

+12443
-2756
lines changed

Some content is hidden

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

147 files changed

+12443
-2756
lines changed

CHANGES.md

+33-6
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,36 @@
22
# Revision History #
33

44

5-
## Version 1.6 -- Under Development ##
5+
## Version 1.7 -- Under Development ('dev' branch) ##
66

77

8+
### New Features: ###
9+
10+
- Improved Layer 2 Protocol [(IL2P)](https://en.wikipedia.org/wiki/FX.25_Forward_Error_Correction). Use "-I 1" on command line to enable transmit for first channel. Compatible with Nino TNC for 1200 and 9600 bps.
11+
12+
- Limited support for CM109/CM119 GPIO PTT on Windows.
13+
14+
- Dire Wolf now advertises itself using DNS Service Discovery. This allows suitable APRS / Packet Radio applications to find a network KISS TNC without knowing the IP address or TCP port. Thanks to Hessu for providing this. Currently available only for Linux and Mac OSX. [Read all about it here.](https://github.com/hessu/aprs-specs/blob/master/TCP-KISS-DNS-SD.md)
15+
16+
- The transmit calibration tone (-x) command line option now accepts a radio channel number and/or a single letter mode: a = alternate tones, m = mark tone, s = space tone, p = PTT only no sound.
17+
18+
- The BEACON configuration now recognizes the SOURCE= option. This replaces the AX.25 source address rather than using the MYCALL value for the channel. This is useful for sending more than 5 analog telemetry channels. Use two, or more, source addresses with up to 5 analog channels each.
19+
20+
- For more flexibility, the FX.25 transmit property can now be set individually by channel, rather than having a global setting for all channels. The -X on the command line applies only to channel 0. For other channels you need to add a new line to the configuration file.
21+
22+
> After: "CHANNEL 1" (or other channel)
23+
>
24+
> Add: "FX25TX 1" (or 16 or 32 or 64)
25+
26+
27+
## Version 1.6 -- October 2020 ##
28+
829
### New Build Procedure: ###
930

1031

11-
- Rather than trying to keep a bunch of different platform specific Makefiles in sync, "cmake" is now used for greater portability and easier maintenance.
32+
- Rather than trying to keep a bunch of different platform specific Makefiles in sync, "cmake" is now used for greater portability and easier maintenance. This was contributed by Davide Gerhard.
1233

13-
- README.md has a quick summary of the process. More details in the User Guide.
34+
- README.md has a quick summary of the process. More details in the ***User Guide***.
1435

1536

1637
### New Features: ###
@@ -45,15 +66,21 @@
4566

4667
- ***AX.25 + FEC = FX.25***
4768

69+
- ***AIS Reception***
70+
4871
- ***AX.25 Throughput: Why is 9600 bps Packet Radio only twice as fast as 1200?***
4972

50-
- [***Ham Radio of Things - IoT over Ham Radio***](https://github.com/wb2osz/hrot)
73+
- [***Ham Radio of Things (HRoT) - IoT over Ham Radio***](https://github.com/wb2osz/hrot)
74+
75+
- [***EAS SAME to APRS Message Converter***](https://github.com/wb2osz/eas2aprs)
5176

52-
- Power Point slide show in separate repository. [https://github.com/wb2osz/direwolf-presentation ](https://github.com/wb2osz/direwolf-presentation)
77+
- [***Dire Wolf PowerPoint Slide Show***](https://github.com/wb2osz/direwolf-presentation)
5378

5479
### Notes: ###
5580

56-
Windows binary distribution now uses gcc (MinGW) version 7.4.0.
81+
The Windows binary distribution now uses gcc (MinGW) version 7.4.0.
82+
The Windows version is built for both 32 and 64 bit operating systems.
83+
Use the 64 bit version if possible; it runs considerably faster.
5784

5885

5986

CMakeLists.txt

+66-6
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,13 @@ project(direwolf)
44

55
# configure version
66
set(direwolf_VERSION_MAJOR "1")
7-
set(direwolf_VERSION_MINOR "6")
7+
set(direwolf_VERSION_MINOR "7")
88
set(direwolf_VERSION_PATCH "0")
9-
set(direwolf_VERSION_SUFFIX "")
9+
set(direwolf_VERSION_SUFFIX "Development")
1010

1111
# options
12-
option(FORCE_SSE "Compile with SSE instruction only" OFF)
12+
# See Issue 297.
13+
option(FORCE_SSE "Compile with SSE instruction only" ON)
1314
option(FORCE_SSSE3 "Compile with SSSE3 instruction only" OFF)
1415
option(FORCE_SSE41 "Compile with SSE4.1 instruction only" OFF)
1516
option(OPTIONAL_TEST "Compile optional test (might be broken)" OFF)
@@ -71,6 +72,7 @@ set(CUSTOM_SRC_DIR "${CMAKE_SOURCE_DIR}/src")
7172
set(CUSTOM_EXTERNAL_DIR "${CMAKE_SOURCE_DIR}/external")
7273
set(CUSTOM_MISC_DIR "${CUSTOM_EXTERNAL_DIR}/misc")
7374
set(CUSTOM_REGEX_DIR "${CUSTOM_EXTERNAL_DIR}/regex")
75+
set(CUSTOM_HIDAPI_DIR "${CUSTOM_EXTERNAL_DIR}/hidapi")
7476
set(CUSTOM_GEOTRANZ_DIR "${CUSTOM_EXTERNAL_DIR}/geotranz")
7577
set(CUSTOM_DATA_DIR "${CMAKE_SOURCE_DIR}/data")
7678
set(CUSTOM_SCRIPTS_DIR "${CMAKE_SOURCE_DIR}/scripts")
@@ -86,13 +88,21 @@ set(CUSTOM_SHELL_SHABANG "#!/bin/sh -e")
8688
set(CPACK_GENERATOR "ZIP")
8789
set(CPACK_STRIP_FILES true)
8890
set(CPACK_PACKAGE_NAME "${CMAKE_PROJECT_NAME}")
89-
set(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${direwolf_VERSION}_${CMAKE_SYSTEM_PROCESSOR}")
91+
# This has architecture of the build machine, not the target platform.
92+
# e.g. Comes out as x86_64 when building for i686 target platform.
93+
#set(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${direwolf_VERSION}_${CMAKE_SYSTEM_PROCESSOR}")
94+
# We don't know the target yet so this is set after FindCPUflags.
9095
set(CPACK_PACKAGE_CONTACT "https://github.com/wb2osz/direwolf")
91-
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Dire Wolf is a software soundcard AX.25 packet modem/TNC and APRS encoder/decoder")
96+
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Dire Wolf is an AX.25 soundcard TNC, digipeater, APRS IGate, GPS tracker, and APRStt gateway")
9297
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_SOURCE_DIR}/README.md")
9398
set(CPACK_RESOURCE_FILE_README "${CMAKE_SOURCE_DIR}/README.md")
9499
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE")
95100
set(CPACK_SOURCE_IGNORE_FILES "${PROJECT_BINARY_DIR};/.git/;.gitignore;menu.yml;.travis.yml;.appveyor.yml;default.nix;.envrc;TODOs.org;/.scripts/")
101+
SET(CPACK_PACKAGE_VERSION "${direwolf_VERSION}")
102+
SET(CPACK_PACKAGE_VERSION_MAJOR "${direwolf_VERSION_MAJOR}")
103+
SET(CPACK_PACKAGE_VERSION_MINOR "${direwolf_VERSION_MINOR}")
104+
SET(CPACK_PACKAGE_VERSION_PATCH "${direwolf_VERSION_PATCH}")
105+
SET(CPACK_DEBIAN_PACKAGE_DEPENDS "libasound2,libgps23")
96106

97107
# if we don't set build_type
98108
if(NOT DEFINED CMAKE_BUILD_TYPE OR "${CMAKE_BUILD_TYPE}" STREQUAL "")
@@ -114,10 +124,16 @@ include(FindCompiler)
114124
# find cpu flags (and set compiler)
115125
include(FindCPUflags)
116126

127+
if(${ARCHITECTURE} MATCHES "x86")
128+
set(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${direwolf_VERSION}_i686")
129+
else()
130+
set(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${direwolf_VERSION}_${ARCHITECTURE}")
131+
endif()
132+
117133
# auto include current directory
118134
set(CMAKE_INCLUDE_CURRENT_DIR ON)
119135

120-
# set OS dependant variables
136+
# set OS dependent variables
121137
if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
122138
set(LINUX TRUE)
123139

@@ -129,6 +145,10 @@ elseif(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
129145
configure_file("${CMAKE_SOURCE_DIR}/cmake/cpack/${CMAKE_PROJECT_NAME}.desktop.in"
130146
"${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}.desktop" @ONLY)
131147

148+
elseif(${CMAKE_SYSTEM_NAME} STREQUAL "OpenBSD")
149+
set(OPENBSD TRUE)
150+
set(HAVE_SNDIO TRUE)
151+
132152
elseif(APPLE)
133153
if("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "")
134154
message(STATUS "Build for macOS target: local version")
@@ -142,6 +162,10 @@ elseif(APPLE)
142162
set(CMAKE_MACOSX_RPATH ON)
143163
message(STATUS "RPATH support: ${CMAKE_MACOSX_RPATH}")
144164

165+
# just blindly enable dns-sd
166+
set(USE_MACOS_DNSSD ON)
167+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DUSE_MACOS_DNSSD")
168+
145169
elseif (WIN32)
146170
if(NOT VS2015 AND NOT VS2017 AND NOT VS2019)
147171
message(FATAL_ERROR "You must use Microsoft Visual Studio 2015 | 2017 | 2019 as compiler")
@@ -181,10 +205,16 @@ if (C_CLANG OR C_GCC)
181205
# I also took out -Wextra because it spews out so much noise a serious problem was not noticed.
182206
# It might go back in someday when I have more patience to clean up all the warnings.
183207
#
208+
209+
# TODO:
210+
# Try error checking -fsanitize=bounds-strict -fsanitize=leak
211+
# Requires libubsan and liblsan, respectively.
212+
184213
###set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wvla -ffast-math -ftree-vectorize -D_XOPEN_SOURCE=600 -D_DEFAULT_SOURCE ${EXTRA_FLAGS}")
185214
if(FREEBSD)
186215
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wvla -ffast-math -ftree-vectorize -D_DEFAULT_SOURCE ${EXTRA_FLAGS}")
187216
else()
217+
#set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wvla -ffast-math -ftree-vectorize -D_GNU_SOURCE -fsanitize=bounds-strict ${EXTRA_FLAGS}")
188218
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wvla -ffast-math -ftree-vectorize -D_GNU_SOURCE ${EXTRA_FLAGS}")
189219
endif()
190220
#
@@ -232,6 +262,20 @@ else()
232262
endif(WIN32 OR CYGWIN)
233263

234264
# requirements
265+
266+
include(CheckSymbolExists)
267+
# Some platforms provide their own strlcpy & strlcat. (BSD, MacOSX)
268+
# Others don't so we provide our own. (Most, but not all Linux)
269+
# Define the preprocessor macro so libgps does not supply its own version.
270+
check_symbol_exists(strlcpy string.h HAVE_STRLCPY)
271+
if(HAVE_STRLCPY)
272+
add_compile_options(-DHAVE_STRLCPY)
273+
endif()
274+
check_symbol_exists(strlcat string.h HAVE_STRLCAT)
275+
if(HAVE_STRLCAT)
276+
add_compile_options(-DHAVE_STRLCAT)
277+
endif()
278+
235279
set(THREADS_PREFER_PTHREAD_FLAG ON)
236280
find_package(Threads REQUIRED)
237281

@@ -270,6 +314,17 @@ if(LINUX)
270314
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DUSE_CM108")
271315
endif()
272316

317+
find_package(Avahi)
318+
if(AVAHI_CLIENT_FOUND)
319+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DUSE_AVAHI_CLIENT")
320+
endif()
321+
322+
elseif (HAVE_SNDIO)
323+
find_package(sndio REQUIRED)
324+
if(SNDIO_FOUND)
325+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DUSE_SNDIO")
326+
endif()
327+
273328
elseif (NOT WIN32 AND NOT CYGWIN)
274329
find_package(Portaudio REQUIRED)
275330
if(PORTAUDIO_FOUND)
@@ -281,8 +336,12 @@ else()
281336
set(ALSA_LIBRARIES "")
282337
set(UDEV_INCLUDE_DIRS "")
283338
set(UDEV_LIBRARIES "")
339+
# Version 1.7 supports CM108/CM119 GPIO PTT for Windows.
340+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DUSE_CM108")
284341
set(PORTAUDIO_INCLUDE_DIRS "")
285342
set(PORTAUDIO_LIBRARIES "")
343+
set(SNDIO_INCLUDE_DIRS "")
344+
set(SNDIO_LIBRARIES "")
286345
endif()
287346

288347
# manage and fetch new data
@@ -291,6 +350,7 @@ add_subdirectory(data)
291350
# external libraries
292351
add_subdirectory(${CUSTOM_GEOTRANZ_DIR})
293352
add_subdirectory(${CUSTOM_REGEX_DIR})
353+
add_subdirectory(${CUSTOM_HIDAPI_DIR})
294354
add_subdirectory(${CUSTOM_MISC_DIR})
295355

296356
# direwolf source code and utilities

Makefile

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
2+
all:
3+
@echo "The build procedure has changed in version 1.6."
4+
@echo "In general, it now looks like this:"
5+
@echo " "
6+
@echo "Download the source code:"
7+
@echo " "
8+
@echo " cd ~"
9+
@echo " git clone https://www.github.com/wb2osz/direwolf"
10+
@echo " cd direwolf"
11+
@echo " "
12+
@echo "Optional - Do this to get the latest development version"
13+
@echo "rather than the latest stable release."
14+
@echo " "
15+
@echo " git checkout dev"
16+
@echo " "
17+
@echo "Build it. There are two new steps not used for earlier releases."
18+
@echo " "
19+
@echo " mkdir build && cd build"
20+
@echo " cmake .."
21+
@echo " make -j4"
22+
@echo " "
23+
@echo "Install:"
24+
@echo " "
25+
@echo " sudo make install"
26+
@echo " make install-conf"
27+
@echo " "
28+
@echo "You will probably need to install additional applications and"
29+
@echo "libraries depending on your operating system."
30+
@echo "More details are in the README.md file."
31+
@echo " "
32+
@echo "Questions?"
33+
@echo " "
34+
@echo " - Extensive documentation can be found in the 'doc' directory."
35+
@echo " - Join the discussion forum here: https://groups.io/g/direwolf"
36+
@echo " "

0 commit comments

Comments
 (0)