TX Size for targetting QPSK example from Transceiver Toolbox in Linux

In the example codes posted under trx_examples/targeting/modem-qpsk/test/linux of the TransceiverToolbox repository in github, I noticed a couple differences between test_dma.c and modemd.c.

1. In modemd.c, in line 220, the TX transfer size for the radio IP is written at the top of the DMA buffer. However, instead of the number of bytes to be transferred, a bit-reversed copy of that uint8 number is written.

2. In test_dma.c, in line 108, the TX transfer size is written directly without any bit reversal.

Why does the difference exist? Also, in modemd.c the number being written is an uint8 which will overflow with larger MTU sizes. How is that dealt with?



Parents Reply Children
  • 0
    •  Analog Employees 
    on Apr 7, 2021 1:14 AM in reply to sunipkm

    We didn't really vary these in our design as it's just an example. TLAST didn't exist in our HDL reference designs so we used fixed packet size to make it work. From what I recall we just made something that got to 1600 bytes, which was the agreed-upon transfer size. I would look at 802.3 to see what they use.

    Usually, MTUs are smaller for wireless comms. For example, I believe Ethernet has jumbo frames but wireless does not. I would look at what 802.11 uses as a baseline. 


  • Thanks, Travis. I am using the HDL reference designs without TLAST as you mentioned, and for a successful transfer I actually have to do a DMA transfer of size payloadLen + 4 (payloadLen is a multiple of 8 bytes) on the receiver even when I am doing a TX transfer of size payloadLen, which I find slightly weird. Do you have any insight as to why is this the case?