Restructure: Move sample rate conversion from common code to 'libsamplerate'

pull/1/head
Andreas Eversberg 5 years ago
parent 669705c6ed
commit 1b183864bb
  1. 1
      .gitignore
  2. 1
      configure.ac
  3. 2
      src/Makefile.am
  4. 1
      src/amps/Makefile.am
  5. 1
      src/anetz/Makefile.am
  6. 1
      src/bnetz/Makefile.am
  7. 1
      src/cnetz/Makefile.am
  8. 1
      src/common/Makefile.am
  9. 2
      src/common/emphasis.h
  10. 2
      src/common/mncc_console.c
  11. 2
      src/common/sender.h
  12. 1
      src/jtacs/Makefile.am
  13. 6
      src/libsamplerate/Makefile.am
  14. 2
      src/libsamplerate/samplerate.c
  15. 0
      src/libsamplerate/samplerate.h
  16. 1
      src/nmt/Makefile.am
  17. 1
      src/r2000/Makefile.am
  18. 1
      src/tacs/Makefile.am
  19. 4
      src/test/Makefile.am

1
.gitignore vendored

@ -20,6 +20,7 @@ compile
.libs
.dirstamp
m4
src/libsamplerate/libsamplerate.a
src/libfilter/libfilter.a
src/common/libcommon.a
src/common/libmobile.a

@ -75,6 +75,7 @@ AS_IF([test "x$with_soapy" == "xyes"],[AC_MSG_NOTICE( Compiling with SoapySDR su
AS_IF([test "x$somethingmagick" == "xyes"],[AC_MSG_NOTICE( Compiling with ImageMagick )],[AC_MSG_NOTICE( ImageMagick not supported )])
AC_OUTPUT(
src/libsamplerate/Makefile
src/libfilter/Makefile
src/common/Makefile
src/anetz/Makefile

@ -1,3 +1,3 @@
AUTOMAKE_OPTIONS = foreign
SUBDIRS = libfilter common anetz bnetz cnetz nmt amps tacs jtacs r2000 tv test
SUBDIRS = libsamplerate libfilter common anetz bnetz cnetz nmt amps tacs jtacs r2000 tv test

@ -28,6 +28,7 @@ amps_LDADD = \
libamps.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -14,6 +14,7 @@ anetz_LDADD = \
$(top_builddir)/src/common/libgermanton.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -16,6 +16,7 @@ bnetz_LDADD = \
$(top_builddir)/src/common/libgermanton.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -20,6 +20,7 @@ cnetz_LDADD = \
$(top_builddir)/src/common/libgermanton.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -11,7 +11,6 @@ libcommon_a_SOURCES = \
goertzel.c \
jitter.c \
dtmf.c \
samplerate.c \
emphasis.c \
compandor.c \
fft.c \

@ -1,3 +1,5 @@
#include "../libfilter/iir_filter.h"
typedef struct emphasis {
struct {
iir_filter_t lp;

@ -25,7 +25,7 @@
#include <errno.h>
#include <sys/time.h>
#include "sample.h"
#include "samplerate.h"
#include "../libsamplerate/samplerate.h"
#include "jitter.h"
#include "debug.h"
#include "testton.h"

@ -3,7 +3,7 @@
#include "sdr.h"
#endif
#include "wave.h"
#include "samplerate.h"
#include "../libsamplerate/samplerate.h"
#include "jitter.h"
#include "emphasis.h"
#include "display.h"

@ -14,6 +14,7 @@ jtacs_LDADD = \
../amps/libamps.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -0,0 +1,6 @@
AM_CPPFLAGS = -Wall -Wextra -g $(all_includes)
noinst_LIBRARIES = libsamplerate.a
libsamplerate_a_SOURCES = \
samplerate.c

@ -22,7 +22,7 @@
#include <errno.h>
#include <string.h>
#include <stdlib.h>
#include "sample.h"
#include "../common/sample.h"
#include "samplerate.h"
int init_samplerate(samplerate_t *state, double low_samplerate, double high_samplerate, double filter_cutoff)

@ -24,6 +24,7 @@ nmt_LDADD = \
libdmssms.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -14,6 +14,7 @@ radiocom2000_LDADD = \
$(COMMON_LA) \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -15,6 +15,7 @@ tacs_LDADD = \
../amps/libamps.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

@ -15,6 +15,7 @@ test_filter_LDADD = \
$(COMMON_LA) \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
@ -38,6 +39,7 @@ test_emphasis_LDADD = \
$(COMMON_LA) \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
@ -51,6 +53,7 @@ test_dms_LDADD = \
$(top_builddir)/src/nmt/libdmssms.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
@ -64,6 +67,7 @@ test_sms_LDADD = \
$(top_builddir)/src/nmt/libdmssms.a \
$(top_builddir)/src/common/libmobile.a \
$(top_builddir)/src/common/libcommon.a \
$(top_builddir)/src/libsamplerate/libsamplerate.a \
$(top_builddir)/src/libfilter/libfilter.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \

Loading…
Cancel
Save