Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@ Doxyfile
.DS_Store
.tarball-version
.version

.*.swp

doc/


CMakeCache.txt
*/CMakeFiles
CMakeFiles
*.cmake
debian/*.debhelper.log
obj-x86_64-linux-gnu
obj-aarch64-linux-gnu

File renamed without changes.
19 changes: 16 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,13 @@ endif()
# Install udev rules
########################################################################
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
set(CMAKE_INSTALL_UDEVRULESDIR "lib/udev/rules.d"
CACHE PATH "udev rules installation directory")

install(
FILES fobos-sdr.rules
DESTINATION "/etc/udev/rules.d"
COMPONENT "udev")
FILES 73-fobos-sdr.rules
DESTINATION "${CMAKE_INSTALL_UDEVRULESDIR}"
COMPONENT udev)
endif()
########################################################################

Expand Down Expand Up @@ -151,6 +154,10 @@ target_include_directories(libfobos PUBLIC

set_target_properties(libfobos PROPERTIES DEFINE_SYMBOL "FOBOS_EXPORTS")
set_target_properties(libfobos PROPERTIES OUTPUT_NAME fobos)
set_target_properties(libfobos PROPERTIES
VERSION 2.4.1
SOVERSION 0
)
########################################################################

########################################################################
Expand Down Expand Up @@ -273,6 +280,12 @@ target_include_directories(fobos_fwloader PRIVATE ${CMAKE_SOURCE_DIR})
target_include_directories(fobos_fwloader PRIVATE ${CMAKE_SOURCE_DIR}/fobos)
########################################################################

# install executables
install(
TARGETS fobos_fwloader fobos_recorder fobos_devinfo
RUNTIME DESTINATION bin
COMPONENT tools
)

########################################################################
# Directories
Expand Down
1 change: 1 addition & 0 deletions debian/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
fobos-udev/
libfobos-dev/
libfobos0/
fobos-tools/
12 changes: 12 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
libfobos (2.4.1-5-trixie1) trixie; urgency=medium

* turn off FOBOS_PRINT_DEBUG apparently turned on upstream

-- Phil Karn <karn@ka9q.net> Wed, 17 Jun 2026 05:26:23 -0700

libfobos (2.4.1-4-trixie1) trixie; urgency=medium

* fixed debian packaging, set SONAME 0

-- Phil Karn <karn@ka9q.net> Wed, 17 Jun 2026 00:37:45 -0700

libfobos (2.4.1-3) trixie; urgency=medium

* clean out deadwood
Expand Down
10 changes: 10 additions & 0 deletions debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,21 @@ Rules-Requires-Root: no
Build-Depends:
debhelper-compat (= 13),
cmake,
libusb-1.0-0-dev
Standards-Version: 4.7.2
Homepage: https://rigexpert.com
Vcs-Git: https://github.com/ka9q/libfobos-debian.git
Vcs-Browser: https://github.com/ka9q/libfobos-debian

Package: fobos-tools
Section: utils
Priority: optional
Architecture: any
Multi-Arch: same
Depends: libfobos0 (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
Description: Command line tools for RigExpert Fobos SDR
Simple test/info tools for the RigExpert Fobos SDR front end

Package: libfobos-dev
Section: libdevel
Architecture: any
Expand Down
2 changes: 2 additions & 0 deletions debian/fobos-tools.install
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
usr/bin/*

2 changes: 0 additions & 2 deletions debian/libfobos-dev-dirs

This file was deleted.

1 change: 0 additions & 1 deletion debian/libfobos0.dirs

This file was deleted.

2 changes: 1 addition & 1 deletion debian/libfobos0.install
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
usr/lib/*/lib*.so.*
usr/lib/udev/rules.d/60-fobos-sdr.rules
usr/lib/udev/rules.d/73-fobos-sdr.rules
3 changes: 3 additions & 0 deletions debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
#export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed


override_dh_auto_install:
dh_auto_install -- DESTDIR=$(CURDIR)/debian/tmp

%:
dh $@

Expand Down
28 changes: 14 additions & 14 deletions fobos/fobos.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
// / __ / / / / _ \ / ___/ \ \/ / / __ \ / __ \ / ___\ / _/
// / /\ \ / / / /_/ / / /___ / / / /_/ / / ___/ / / / /_
// /_ / \_\ /_/ \__ / /______/ /_/\_\ / ____/ \____/ /_/ \___/
// /______/ /_/
// /______/ /_/
// Fobos SDR API library
// 2024.03.21
// 2024.04.08
Expand All @@ -30,7 +30,7 @@
#ifdef _WIN32
#include <conio.h>
#include <Windows.h>
#pragma comment(lib, "libusb-1.0.lib")
#pragma comment(lib, "libusb-1.0.lib")
#define printf_internal _cprintf
#else
#include <unistd.h>
Expand All @@ -39,7 +39,7 @@
#define printf_internal printf
#endif // !printf_internal
//==============================================================================
#define FOBOS_PRINT_DEBUG
//#define FOBOS_PRINT_DEBUG
//==============================================================================
#define LIB_VERSION "2.4.1"
#define DRV_VERSION "libusb"
Expand Down Expand Up @@ -176,7 +176,7 @@ int fobos_rx_get_api_info(char * lib_version, char * drv_version)
{
if (lib_version)
{
strcpy(lib_version, LIB_VERSION" "__DATE__" "__TIME__);
strcpy(lib_version, LIB_VERSION);
}
if (drv_version)
{
Expand Down Expand Up @@ -208,7 +208,7 @@ int fobos_rx_get_device_count(void)
libusb_get_device_descriptor(list[i], &dd);
#ifdef FOBOS_PRINT_DEBUG
printf_internal("%04x:%04x\n", dd.idVendor, dd.idProduct);
#endif // FOBOS_PRINT_DEBUG
#endif // FOBOS_PRINT_DEBUG
if ((dd.idVendor == FOBOS_VENDOR_ID) &&
(dd.idProduct == FOBOS_PRODUCT_ID) &&
(dd.bcdDevice == FOBOS_DEV_ID))
Expand Down Expand Up @@ -607,7 +607,7 @@ int fobos_rffc507x_set_lo_frequency_hz(struct fobos_dev_t * dev, uint64_t lo_fre
fobos_rffc507x_commit(dev, 0);
#ifdef FOBOS_PRINT_DEBUG
double ff = (double)freq_hz;
printf_internal("rffc507x lo_freq_mhz = %lld %f\n", lo_freq_hz, ff);
printf_internal("rffc507x lo_freq_mhz = %llu %f\n", (unsigned long long)lo_freq_hz, ff);
#endif // FOBOS_PRINT_DEBUG
return 0;
}
Expand Down Expand Up @@ -1008,7 +1008,7 @@ int fobos_rx_get_board_info(struct fobos_dev_t * dev, char * hw_revision, char *
#define FOBOS_INJECT_LOW 1
#define FOBOS_INJECT_HIGH 2
//==============================================================================
typedef struct
typedef struct
{
uint32_t idx;
uint32_t freq_mhz_min;
Expand Down Expand Up @@ -1153,7 +1153,7 @@ int fobos_rx_set_frequency(struct fobos_dev_t * dev, double value, double * actu
int result = fobos_check(dev);
#ifdef FOBOS_PRINT_DEBUG
printf_internal("%s(%f);\n", __FUNCTION__, value);
#endif // FOBOS_PRINT_DEBUG
#endif // FOBOS_PRINT_DEBUG
if (result != FOBOS_ERR_OK)
{
return result;
Expand Down Expand Up @@ -1502,7 +1502,7 @@ int fobos_rx_set_bandwidth(struct fobos_dev_t * dev, double value, double * actu
if (dev->rx_bw_idx != idx)
{
dev->rx_bw_idx = idx;
fobos_max2830_write_reg(dev, 8, (uint16_t)(idx | 0x3020));
fobos_max2830_write_reg(dev, 8, (uint16_t)(idx | 0x3020));
}
if (dev->rx_bw_adj != adj)
{
Expand Down Expand Up @@ -1548,7 +1548,7 @@ int fobos_rx_get_samplerates(struct fobos_dev_t * dev, double * values, unsigned
//==============================================================================
const uint32_t fobos_p1s[] =
{
10,
10,
16, 20, 25, 32, 40, 50, 64, 80, 100
};
//==============================================================================
Expand Down Expand Up @@ -2160,10 +2160,10 @@ int fobos_rx_read_sync(struct fobos_dev_t * dev, float * buf, uint32_t * actual_
}
result = libusb_bulk_transfer(
dev->libusb_devh,
LIBUSB_BULK_IN_ENDPOINT,
dev->rx_sync_buf,
dev->transfer_buf_size,
&actual,
LIBUSB_BULK_IN_ENDPOINT,
dev->rx_sync_buf,
dev->transfer_buf_size,
&actual,
LIBUSB_BULK_TIMEOUT);
if (result == FOBOS_ERR_OK)
{
Expand Down
Loading