我有一个一般的工作函数,我将使用GNU Radio的历史记录功能。在块的构造函数中,我打电话set_history(m)
。我投的输入缓冲区以标准方式:GNU Radio历史记录
const float *in = (const float *) input_items[0];
我的问题是wheere in[0]
是指在缓冲区中。对我来说,noutput_items
是新的项要消耗的块的数量,ninput_items[0]
是指缓冲区中的数据总数。因此,in[noutput_items-1]
是数组的最后一个元素,in[0]
是新项的开始,而in[-m]
是指历史块的开始。因此,ninput_items[0]
大于或等于m + noutput_items
。
我不知道这个假设是否属实,如果有人知道这是如何工作,会很高兴。 GNU Radio API在这方面有些模糊。提前致谢!