-
Notifications
You must be signed in to change notification settings - Fork 0
/
SoapyHifiBerry.cpp
38 lines (30 loc) · 1.2 KB
/
SoapyHifiBerry.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#include <SoapySDR/Device.hpp>
#include <SoapySDR/Registry.hpp>
#include "SoapyHifiBerry.h"
/***********************************************************************
* Find available devices
**********************************************************************/
SoapySDR::KwargsList findMyHifiBerry(const SoapySDR::Kwargs &args)
{
SoapySDR::Kwargs options;
static std::vector<SoapySDR::Kwargs> results;
options["driver"] = "hifiberry";
options["label"] = "SoapyHifiberrys";
options["product"] = "SoapyHifiberry";
options["manufacturer"] = "PA0PHH";
options["label"] = "Hifiberry";
options["tuner"] = "si5351";
results.push_back(options);
return results;
}
/***********************************************************************
* Make device instance
**********************************************************************/
SoapySDR::Device *makeMyHifiBerry(const SoapySDR::Kwargs &args)
{
return new SoapyHifiBerry(args);
}
/***********************************************************************
* Registration
**********************************************************************/
static SoapySDR::Registry registerHifiberry("hifiberry", &findMyHifiBerry, &makeMyHifiBerry, SOAPY_SDR_ABI_VERSION);