Dear Niels, Thank you so much for the detailed reply, I think I understand it well now. As you mentioned I am expecting 16 x sc16 items to process at once in my block and I configured the CHDR_W to 128 bits. In the example from the link you shared I see that the spp param is passed as a string key, value pair. After going through the code I can see that there is an input field '*args*' for TX streamer in GNU Radio and I think that is where I have to enter the parameter and I think in my case it should be "spp=16".
>From your explanation and code I assume that 1 sample will be of size 32bits if the output-type/otw_format is sc16? (because of the conversion I see in the connect_channel() in https://github.com/EttusResearch/uhd/blob/master/host/lib/rfnoc/rfnoc_tx_streamer.cpp . Sorry, it was a typo in the processing chain from the last message. -J On Thu, 21 Aug 2025 at 14:32, niels.steffen.garibaldi--- via USRP-users < [email protected]> wrote: > Hi Jons, > > TL;DR: If you configure the packet size of your (TX) streamer by > specifying the SPP parameter of your stream_args, inside of your RFNoC > block you can assume that every time tlast is asserted, have received a > full packet consisting of 32 samples. > > > Technically you can make your packets whatever size you like, especially > if you are not interfacing with any other data processing RFNoC blocks. > > Some blocks have special requirements on the packet size, for example the > fft block. This block takes the full packet and then processes it as a > whole, similar to how it seems your custom block is operating. If you are > doing using an FFT size of 1024, the fft block expects every packet to > consist of exactly 1024 (sc16) samples. > > In RFNoC, you can specify the size of the TX or RX streamer packet sample > payload by specifying the SPP(Samples Per Packet) parameter in the > stream_args. > See https://uhd.readthedocs.io/en/latest/page_stream.html#stream_intro > example code on a basic way to do that. > > When it comes to the FPGA side and tlast, it gets slightly more > complicated: > > RFNoC blocks communicate with each other using CHDR packets, that are > transmitted over the CHDR data bus connections between them. > > The width of this bus is determined by the `CHDR_W` parameter of the bit > file variant you are using your block in. A packet is split into data words > of width `CHDR_W` and then forwarded one word per clock cycle of the data > clock `chdr_clk`. > > This means that if you are using a `CHDR_W` of 64 as used in the 200MHz BW > variant bitfile, the “SPP=32” packet you have sent from the host will be > resized, and tlast will be asserted after 1 CHDR header word + 16 payload > Data words each containing two samples (equivalent to “NIPC=2” with your > sample width of sc16 being “ITEM_W=32”). > > I’m not as familiar with gnuradio but i am assuming that if you are > setting the spp for your streamer your block should be fine. > > The size of the return packet is you depends on what the output of your > custom RFNoC block is, and whenever you assert tlast inside of your block. > > By the way, I am assuming there is a typo in your processing chain: > > GNU Radio block A --> TX streamer --> custom RFNoC block --> *RX* > streamer > --> GNU Radio block B > > Regards, > Niels > _______________________________________________ > USRP-users mailing list -- [email protected] > To unsubscribe send an email to [email protected] >
_______________________________________________ USRP-users mailing list -- [email protected] To unsubscribe send an email to [email protected]
