Skip to content

Commit

Permalink
blocks/sources/soapysdr: add api and abi version reporting to debug dump
Browse files Browse the repository at this point in the history
  • Loading branch information
vsergeev committed Feb 27, 2020
1 parent 6c8f986 commit 17b6dff
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions radio/blocks/sources/soapysdr.lua
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,10 @@ if not package.loaded['radio.blocks.sinks.soapysdr'] then

enum { SOAPY_SDR_TX = 0, SOAPY_SDR_RX = 1 };

/* Version */
const char *SoapySDR_getLibVersion(void);
const char *SoapySDR_getAPIVersion(void);
const char *SoapySDR_getABIVersion(void);

/* Error strings */
const char *SoapySDR_errToStr(const int errorCode);
Expand Down Expand Up @@ -341,6 +344,8 @@ function SoapySDRSource:initialize_soapysdr()
if debug.enabled then
-- Look up library version
debug.printf("[SoapySDRSource] SoapySDR library version: %s\n", ffi.string(libsoapysdr.SoapySDR_getLibVersion()))
debug.printf("[SoapySDRSource] SoapySDR API version: %s\n", ffi.string(libsoapysdr.SoapySDR_getAPIVersion()))
debug.printf("[SoapySDRSource] SoapySDR ABI version: %s\n", ffi.string(libsoapysdr.SoapySDR_getABIVersion()))
end

-- Make device
Expand Down

0 comments on commit 17b6dff

Please sign in to comment.