functions get_gain_range and get_freq_range should return an array
Opened this issue · 8 comments
This two functions return a float. Expected an array of 2 values.
@kirat68
no, they return an array of two values.
Take a look at their signatures in the include file rsp.h
(please notice the [2]
toward the end of each line):
https://github.com/fventuri/gr-sdrplay3/blob/master/include/sdrplay3/rsp.h#L69
virtual const double (&get_freq_range() const)[2] = 0;
https://github.com/fventuri/gr-sdrplay3/blob/master/include/sdrplay3/rsp.h#L122
virtual const double (&get_gain_range(const std::string& name) const)[2] = 0;
Franco
Please ignore the warn. Just added in the code to make sure that this function was called.
@kirat68 - Tarik, muito obrigado for mentioning Python!
From your initial comment I assumed it was C++ that you were referring too, but now I understand the problem is somewhere in the Python bindings with pybind11.
I'll take a look,
Franco
@kirat68 - thanks for your patience!
The issue with the Python bindings for range functions returning a pair of values should now be resolved in the master
branch.
Please give it a try and let me know if it works there too.
Franco
Obrigado !!!
Ok could check it.
FYI the returned value is not an array but a tuple but still OK for me.