Retrieve data from USRP N210 device

前端 未结 2 1254
你的背包
你的背包 2021-01-17 08:15

The N210 is connected to the RF frontend, which gets configured using the GNU Radio Companion.

I can see the signal with the FFT plot; I need the received signal (us

2条回答
  •  天涯浪人
    2021-01-17 08:27

    I suggest that you write a python application and stream raw UDP bytes from the USRP block. Simply add a UDP Sink block and connect it to the output of the UDH: USRP Source block. Select an appropriate port and stream to 127.0.0.1 (localhost)

    Now in your python application open a listening UDP socket on the same port and receive the data. Each sample from the UDH: USRP Source is a complex pair of single prevision floats. This means 8 bytes per sample. The I float is first, followed by the Q float.

    Note that the you need to pay special attention to the Payload Size field in the UDP Sink. Since you are streaming localhost, you can use a very large value here. I suggest you use something like 1024*8 here. This means that each packet will contain 1024 IQ Pairs.

    I suggest you first connect a Signal Source and just pipe a sin() wave over the UDP socket into your Python or C application. This will allow you to verify that you are getting the float bytes correct. Make sure to check for glitches due to overflowing buffers. (this will be your biggest problem).

    Please comment or update your post if you have further questions.

提交回复
热议问题