I wrote a block to read Matlab files, similar to the Wav file importer,
and finally got around to getting all compile errors solved. I receive
up to 50 350 MB Matlab data files per day, and would prefer to have the
format natively readable in gnuradio, so I wrote the code myself.
Only on trying to run the grc, I get the following error:
mat_size_of_type is an extern definition of an (int) array with the
sample sizes possible in Matlab data files. It is defined in
gri_matfile.h / .cc
I’m suspecting that I have to declare some dependency somewhere else,
but can’t seem to find out where. Or, maybe it’s not possible to use
lookup tables? I’m somewhat confused that this problem only surfaces
at run-time.
lookup tables? I’m somewhat confused that this problem only surfaces
at run-time.
John
Most likely, you’ll have to declare this as a typedef inside the Swig
interface (.i) file (SWIG and C++ and search
for typedef). Generally, this is pretty painless.
This sounds like the library implementing mat_size_of_type is not
getting dynamically linked in at build time, or the system cannot find
it at runtime.
This sounds like the library implementing mat_size_of_type is not
getting dynamically linked in at build time, or the system cannot find
it at runtime.
Scratch that, just reread your post. Is your gri_matfile.cc getting
added to the swig library?
On Mon, 20 Feb 2012 07:52:33 -0800
Johnathan C. [email protected] wrote:
Scratch that, just reread your post. Is your gri_matfile.cc getting
added to the swig library?
I suspect so, but I’m not sure how to test it (is there a way to check?)
Anyway, I changed the code a little. After checking quite a few of the
the other blocks, I noticed that the gri_xxx file was never included in
the gr_xxx, which I suspect to be on purpose.
I added a method to enquire the size and that part seems so be
compiling correctly.
I now have another problem:
After successful compilation, on running, I find that xxx/top_block.py
contains the following:
which, of course, generates a syntax error. As commented before, I
copied the code from the wavfile_source code, and ‘repeat’ is still
defined in the .cc, .h files.
What generates this error?
John
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.