Maybe you have a typo from copying the usrp2 code, or didnt fill in the
make function in a cc file. The compiler wont catch something like that
unless you try to call the make function in some example c++ app. See
gr-usrp2/src/usrp2_source_32fc.cc
usrp2_source_32fc_sptr
usrp2_make_source_32fc(const std::string &ifc, const std::string &mac_addr)
throw (std::runtime_error)
{
return gnuradio::get_initial_sptr(new usrp2_source_32fc(ifc, mac_addr));
}
-Josh
On 01/18/2010 10:38 AM, Tom Gross wrote:
I've been trying to create a usrp2 dual source class for a number of
weeks now, and I've come to realize there is something fundamental
about this development environment that I don't understand.
Basically i've been installing gnuradio and grc on a variety of Ubuntu
machines buy building gnuradio-3.2.2 thus:
cd gnuradio-3.2.2
./configure --prefix=/usr
make
sudo make install
I've also been making custom blocks using gr-howto-write-a-block-3.2.2.
Lately I've tried to create usrp2_dsource_16sc and
usrp2_dual_source_32fc (slightly different naming conventions just to
see if it would make a difference) in gnuradio-3.2.2/gr-usrp2/src by
mimicing exactly how it is done for the existing single-channel
classes.
Everything builds, but at run-time I am getting an "ImportError"
symbol undefined for _Z23usrp2_make_dsource_16scRKSsS0_
I did an "nm -a _usrp.so | grep make" in
/usr/lib/python2.6/dist-packages/gnuradio and see this:
0000d1b3 T _Z12make_int_ptrv
0000d238 T _Z13make_long_ptrv
0000d12e T _Z15make_uint16_ptrv
U _Z20usrp2_make_sink_16scRKSsS0_
U _Z20usrp2_make_sink_32fcRKSsS0_
U _Z22usrp2_make_source_16scRKSsS0_
U _Z22usrp2_make_source_32fcRKSsS0_
U _Z23usrp2_make_dsource_16scRKSsS0_
U _Z27usrp2_make_dual_source_32fcRKSsS0_
0000d1d7 t _wrap_make_int_ptr
0000d25c t _wrap_make_long_ptr
0000d152 t _wrap_make_uint16_ptr
What I've noticed now is that even in the original _usrp2.so built
from the unmodified gnuradio-3.2.2 source, which works, the make
methods for sink and source appear to be undefined, according to "nm
-a".
So where are they defined? I'm hoping that if I knew how these
methods are resolved at run-time in the "off-the-shelf" version of the
code, I would see why modified code is not working.
-Tom
_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio