Hi all guys,

I am making a file sink block with limited number of elements allowed to be
written in a file. I coded my block in the same way as it was done in
file_sink block found in blocks module. Namely, I derived my block from
file_sink_base and gr_sync_block, and so on, the rest is copied from the
existing block and finally the work function is slightly changed.
Unfortunately I am not able to call methods inherited from file_sink_base
class. I believe it is swig issue but don't know how to make it. The error
that I get when calling close() method inside my test:

1: Test timeout computed to be: 9.99988e+06
1: thread[thread-per-block[1]: <gr_block file_sink_lim_b (2)>]:
gr_block_detail::n_output_items
1: thread[thread-per-block[1]: <gr_block file_sink_lim_b (5)>]:
gr_block_detail::n_output_items
1: E
1: ======================================================================
1: ERROR: test_001_t (__main__.qa_file_sink_lim_b)
1: ----------------------------------------------------------------------
1: Traceback (most recent call last):
1:   File
"/home/savi_ne/work/gnuradio/gr-TPMS/python/qa_file_sink_lim_b.py", line
44, in test_001_t
1:     self.dst.close()
1: AttributeError: 'file_sink_lim_b_sptr' object has no attribute 'close'
1:

I use gnuradio 3.6.5.1 version.

-- 
Nemanja Savić
_______________________________________________
Discuss-gnuradio mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to