User Tools

Site Tools


tuto_fpga_pico

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
tuto_fpga_pico [2016/05/18 10:55] – [What's next] lbesemetuto_fpga_pico [2016/12/14 18:44] – [Edit the .grc file] onicolas
Line 1: Line 1:
-# Using a custom bitstream with a PicoSDR (WORK IN PROGRESS)+# Using a custom bitstream with a PicoSDR
  
-This tutorial shows how to use a custom bitstream when you are making experiments with PicoSDR. For this we will be using a Nutaq exemple about OFDM transmission.+This tutorial shows how to use a custom bitstream when you are making experiments with PicoSDR. For this we will be using a Nutaq example about OFDM transmission.
  
- This exemple provides a bitstream and a GNURadio Companion (GRC) file interacting with the bitstream. All the OFDM work is done within the FPGA. Basically you send raw data to the PicoSDR, the FPGA make the OFDM modulation, TX antenna of card 2 make the emission and RX antenna of card 2 receive the signal, FPGA make the OFDM demodulation, and data is sent back to the computer. As you can see all the work is done with only 1 PicoSDR but using the antennas, so this really for demonstration purpose only. (Pro tip : when modulation and demodulation is made by the same FPGA you don't have to care of the synchronisation because you share the same clock)+This example provides a bitstream and a GNU Radio Companion (GRC) file interacting with the bitstream. All the OFDM work is done within the FPGA. Basically you send raw data to the PicoSDR, the FPGA makes the OFDM modulation, TX antenna of card 2 makes the emission and RX antenna of card 2 receives the signal, the FPGA makes the OFDM demodulation, and data is sent back to the computer. As you can see all the work is done with only 1 PicoSDR but using the antennas, so this is really for demonstration purpose only. (Pro tip : when modulation and demodulation are made by the same FPGA you don't have to take care of the synchronization because both share the same clock).
- +
-The GRC file can be found at ''/Path/to/toolchain/opt/Nutaq/ADP6/ADP\_MicroTCA/sdk/gnuradio/gr-nutaq/examples/ofdm.grc'' and the bitstream at ''/Path/to/toolchain/opt/Nutaq/ADP6/ADP\_MicroTCA/sdk/fpga/bin/OFDM_6_6_0_sx315.bit''. Copy both to a new folder named ''fpga-pico''.+
  
 +The GRC file can be found at ''/Path/to/toolchain/opt/Nutaq/ADP6/ADP\_MicroTCA/sdk/gnuradio/gr-nutaq/examples/ofdm.grc'' and the bitstream at ''/Path/to/toolchain/opt/Nutaq/ADP6/ADP\_MicroTCA/sdk/fpga/bin/OFDM\_6\_6\_0\_sx315.bit''. Copy both to a new folder named ''fpga-pico''. For example, on ''airlock'', the toolchain is located in ''/cortexlab/toolchains/current''.
  
 ## Edit the .grc file ## Edit the .grc file
  
-Let's take a look at ''ofdm.grc''. First, what it is intended to do : We send a video file to RTDEX Sink, and form RTDEX Source we get the constellation points of the OFDM demodulation and the video file is sent to an UDP Sink (in order to open it with VLC for example). We have also a lot of parameters blocks we don't care about in this tutorials (all the custom register blocks are specific to the bitstream).+Let's take a look at ''ofdm.grc'': On ''airlock'', run ''$ gnuradio-companion <path-to-ofdm.grc>''. 
 + 
 +First, what it is intended to do: we send a video file to RTDEX Sink, and from RTDEX Source we get the constellation points of the OFDM demodulation and the video file is sent to UDP Sink (in order to open it with VLC for example). We have also a lot of parameter blocks we don't care about in this tutorials (all the custom register blocks are specific to the bitstream).
  
  
-This example can be used straight away when you are working on your setup, but not in CortXlab because of the video file over UDP thing. Instead of this, we are going to do something a lot easier, which is sending a constant integer to the PicoSDR, and see if we get it back.+This example can be used straight away when you are working on your setup, but not in CorteXlab because of the video file over UDP thing. Instead of this, we are going to do something a lot easier, which is sending a constant integer to the PicoSDR, and see if we get it back.
  
  
Line 19: Line 20:
  
  
-Let's back to the idea of sending a constant number to the PicoSDR and see if we get it back. First thing to do is to add a ''Constant Source'' block (with Int as Output Type, and whatever-you-want as the constant), and connect it to ''RTDEX Sink''. Now, how can we check that we receive the right number ? We could send it to a file and then check the file, but this ain't funny. Instead of this, we're gonna use a super cool new type of block added to GNURadio lately (As I am writing this tutorial). I'm talking about ''Python Block''. With this block, you can create a custom block, with its associated python code easily, without going through an OOT module. +Let's back to the idea of sending a constant number to the PicoSDR and see if we get it back. First thing to do is to add a ''Constant Source'' block (with Int as Output Type, and whatever-you-want as the constant) (block can be found in category ''Waveform Generator''), and connect it to ''RTDEX Sink''. Now, how can we check that we receive the right number ? We could send it to a file and then check the file, but this ain't funny. Instead of this, we're gonna use a super cool new type of block added to GNURadio lately (As I am writing this tutorial). I'm talking about ''Python Block''. With this block, you can create a custom block, with its associated python code easily, without going through an OOT module. 
  
-Add a Python Block, open it, and click on 'Open in Editor'. You can now edit the python code behind the block, and as soon as you save it, changes are repercuted to the block in GRC. You can either write your own code comparing two inputs or use mine :+Add a Python Block (from category ''Misc''), open it, and click on 'Open in Editor'. You can now edit the python code behind the block, and as soon as you save it, changes are repercuted to the block in GRC. You can either write your own code comparing two inputs or use mine :
 <code> <code>
 """ """
tuto_fpga_pico.txt · Last modified: 2017/11/15 16:22 by onicolas

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki