drowe67 / codec2

Open source speech codec designed for communications quality speech between 700 and 3200 bit/s. The main application is low bandwidth HF/VHF digital radio.
GNU Lesser General Public License v2.1
202 stars 32 forks source link

Using the fsk modem in external projects? fsk_api.c / fsk_api.h needed? #42

Closed xssfox closed 8 months ago

xssfox commented 8 months ago

Hey team,

I've been playing with using the fsk.h and fsk library from libcodec2 for my selcall project. It's been working great as a modem for the project - many thanks for providing it.

I'm aware that this library likely isn't intended to be used in other projects like this. At the moment the usage is quite clunky, getting the user to compile libcodec2 from source and then setting CFLAGS="-I/path/to/codec2/src - this is because kiss_fftr.h isn't included in the installed header files when doing make install

I am wondering about the best way to approach this problem. Some options I see working are:

Thoughts?

tmiw commented 8 months ago

I don't recall if Codec2 made any changes to kiss_fft* but is it possible that including the https://github.com/mborgerding/kissfft project into your own project might work?

drowe67 commented 8 months ago

@xssfox sounds like a cool project. Given it's prototype code using libcodec2 outside of it's intended use cases, your current solution sounds fine. As per the codec 2 README support for one off or experimental projects is best done outside of libcodec2.

xssfox commented 8 months ago

I've ended up adding codec2 as a git submodule and adjusted the build process to static link against it which somewhat solves my problems with distribution in the near term.

I think it might still be worth considering make fsk into something that could be easily included into other projects as it's a useful library to use for fsk modulation and demodulation. It's already in use not only in my project but horusdemodlib and likely others.

drowe67 commented 8 months ago

@xssfox - good to see you have a way fwd.

We're happy to consider you proposal - please free free to submit a feature request form.