User Tools

Site Tools


playground:playground

**This is an old revision of the document!**

PlayGround

Create your docker image

Using docker, we will enable the nodes to use Gnuradio 3.7. The codes used are written in this version (waiting for an updtae). In order to do that, we will create an image containing theGnuradio 3.7 version and the python/C++ files used for the dataset creation.

First you have to get the python codes used. Download the following folder :

https://github.com/Inria-Maracas/gr-txid

Then, let us create a dockerfile in your home, giving the files instructions we want to use :

FROM m1mbert/cxlb-gnuradio-3.7:1.0 

WORKDIR /root

COPY ./docker /root

RUN chmod -R 777 ./gr-txid-master

In this dockerfile, the first line download the 3.7 Gnuradio version. Then it adds the python files used for the dataset and gives the rights to the folder.

We can now build our image and then access to it with an ssh command :

you@yourpc:~$ docker build -t <nameofimage> 
you@yourpc:~$ docker run -d -p 2222:2222 <nameofimage>
you@yourpc:~$ ssh -Xp 2222 root@localhost 

Then let us compile the C++ code. Go inside the first folder having the first Cmake. file and launch the compilation :

you@yourpc:~$ cmake .
you@yourpc:~$ make
you@yourpc:~$ make install

The following line might be necessary in case of unfound error :

you@yourpc:~$ mv /<locationofthisfolder>/examples/src/tmp/home/cxlbuser/tasks/task/* /<locationofthisfolder>/examples/src/
you@yourpc:~$ rm -rf /<locationofthisfolder>/examples/src/tmp

It moves the folders to an other location. To finish the config, execute :

you@yourpc:~$ ldconfig

For you to be sure the config has been done properly, you can launch the emitter or recevier command (used then to create the dataset).

you@yourpc:~$ ./gr_txid/examples/src/emitter.py -T 0 -P 3580 -G 8 -R 0 -f 2

At this point the only message error should be this one : empty devices services. Meaning that there is no USRP available on your laptop. The image is ready to be used, we have noax to push it on Dockerhub. The nodes will have access to it through internet.

you@yourpc:~$ docker ps -a 
you@yourpc:~$ docker commit [CONTAINER ID] [NEW IMAGE NAME] 
you@yourpc:~$ docker tag [NEW IMAGE NAME] [DOCKER USERNAME]/[NEW IMAGE NAME] 
you@yourpc:~$ docker login 
you@yourpc:~$ docker push [DOCKER USERNAME]/[NEW IMAGE NAME] 

You can check your pushed on internet, on dockerhub website.

Create your airlock scenario

We have now to create the scenario read by minus on the airlock. Create a .sh file and a .txt file. The .sh file wille execute the commands submitting thz task with minus. The .txt file is the scenario ypou will modifie to create your experiments.

<code>

playground/playground.1666600504.txt.gz · Last modified: 2022/10/24 10:35 by christiandc

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki