Changes between Version 13 and Version 14 of Tutorials/Wireless/Measurement Tool


Ignore:
Timestamp:
Sep 24, 2020, 11:15:34 PM (4 years ago)
Author:
nilanjan
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Tutorials/Wireless/Measurement Tool

    v13 v14  
    1414 2. [UserGuide/CreateRes Create a resource reservation on sandbox 1]
    1515 3. [UserGuide/RemoteAccess/Console Login to your reserved domain.]
    16  4. Load merif.ndz on your resource. [UserGuide/OmfQuickStart  - this is done via OMF commands.]
     16 4. Load baseline-mobi.ndz on your resource. [UserGuide/OmfQuickStart  - this is done via OMF commands.]
    1717
    1818  * After loading the image, if utilizing a network based SDR radio (ie. ethernet with IP address) then follow the instructions [https://wiki.cosmos-lab.org/wiki/tutorials/n310_usage here to configure the network interface and detect the radio.]
     
    5656To use ''rx_multi_receive'' standalone on an experiment server we can using the following options
    5757{{{#!shell-session
    58 root@node:~/RX_MULTI_RECEIVE# ./rx_multi_receive --args="type=x300" --nsamps 1024000 --freq 2440e6 --rate 100e6 --gain 15 --dilv
     58root@node:~/RX_MULTI_RECEIVE# ./rx_multi_receive --args="resource=rio0,type=x300" --nsamps 1024000 --freq 2440e6 --rate 100e6 --gain 15 --dilv
    5959}}}
    6060
    6161 || --args="addr0=10.10.23.5" || specifies the SDR's IP address. ||
    62  || --args="type=x300"        || if using Krypton radio. ||
     62 || --args="resource=rio0,type=x300"        || if using Krypton radio. ||
    6363 || --freq 2440e6             || sets the center freq ||
    6464 || --rate 20e6               || sets sampling rate ||
     
    124124num_buff_ptrs = 1000
    125125mdbp_idx = 1000
    126 Writing FFT blocks into rx_multi_samples.sq3 @ 10.113.0.10:3003
     126
    127127Done!
    128128
     
    132132 || --oml-id `hostname`     || this identifies the source of the data being store ||
    133133 || --oml-domain rx_samples || file name for the OML database ||
    134  || --oml-collect 10.113.0.10:3003  || network storage located on the console ||
    135 
    136 Rerun the application with these and we'll see a few additional lines of output at the end indicating a connection to the OML database server.
    137 
    138 {{{#!shell-session
    139 
    140 Writing FFT blocks into rx_multi_samples.sq3 @ 10.113.0.10:3003
     134 || --oml-collect oml:3003  || network storage located on the console ||
     135
     136The full command to execute would be
     137{{{#!shell-session
     138root@node:~/RX_MULTI_RECEIVE# ./rx_multi_receive --args="resource=rio0,type=x300" --nsamps 1024000 --freq 2440e6 --rate 20e6 --gain 3 --dilv --oml-id `hostname` --oml-collect "oml:3003" --oml-domain rx_samples
     139}}}
     140
     141Rerun the application with these options and we'll see a few additional lines of output at the end indicating a connection to the OML database server.
     142
     143{{{#!shell-session
     144
     145Writing FFT blocks into rx_samples.sq3 @ oml:3003
    141146May 20 23:12:24 INFO    OML Client 2.11.1rc-dirty [OMSPv5] Copyright 2007-2014, NICTA
    142147INFO    tcp:10.113.0.10:3003: Connected
     
    146151
    147152=== ''rx_multi_receive'' break down ===
    148 The source file for this application is in ~/RX_MULTI_RECEIVE/main.cpp. Without going into the details off c++ and the enitire contents of the source file, we'll make note of the following blocks of code:
     153The source file for this application is in ~/RX_MULTI_RECEIVE/main.cpp. Without going into the details off c++ and the entire contents of the source file, we'll make note of the following blocks of code:
    149154
    150155 1. A handle to the radio is constructed and is used thoughout the source to make reference to the radio.
     
    217222
    218223=== Instrumenting ''rx_multi_receive'' application with OML ===
    219  4. Once the read buffer is completely populated, create and fft object to convert the time samples into frequency bins. FFT is take for every 1024 time samples and saved into another buffer.
     224 4. Once the read buffer is completely populated, create the fft object to convert the time samples into frequency bins. FFT is take for every 1024 time samples and saved into another buffer.
    220225
    221226 Inside this block, we create an object that performs 1024pt FFTs.
     
    325330Display all the tables in the database.
    326331{{{
    327 console> ./db_parse --file /var/lib/oml2/rx_multi_samples.sq3 --showtables
     332console> ./db_parse --file /var/lib/oml2/rx_samples.sq3 --showtables
    328333
    329334name = _senders
     
    331336name = _experiment_metadata
    332337
    333 name = _mp__rx_multi_samples
     338name = _mp__rx_samples
    334339
    335340Use following command to retrieve contents of table.
    336 ./db_parse --file /var/lib/oml2/rx_multi_samples.sq3 --exec "SELECT * FROM <table>"
     341./db_parse --file /var/lib/oml2/rx_samples.sq3 --exec "SELECT * FROM <table>"
    337342
    338343To retrieve contents of the blob:
    339 ./db_parse --file /var/lib/oml2/rx_multi_samples.sq3 --blob2bin ch0_data.bin --ch 0 --table  _mp__rx_multi_samples --key Bins
     344./db_parse --file /var/lib/oml2/rx_samples.sq3 --blob2bin ch0_data.bin --ch 0 --table  _mp__rx_samples --key Bins
    340345
    341346}}}
     
    344349We can recover the contents of the FFT data for each channel and save them into a binary file for viewing in octave.
    345350{{{#!shell-session
    346 console:~$ ./db_parse --file /var/lib/oml2/rx_multi_samples.sq3 --blob2bin ch0_data.bin --ch 0 --table  _mp__rx_multi_samples --key
     351console:~$ ./db_parse --file /var/lib/oml2/rx_samples.sq3 --blob2bin ch0_data.bin --ch 0 --table  _mp__rx_samples --key
    347352Bins
    348353
    349354Executing query statement
    350 select LENGTH(Bins),Bins from _mp__rx_multi_samples where channel=0
     355select LENGTH(Bins),Bins from _mp__rx_samples where channel=0
    351356}}}
    352357
     
    354359{{{#!octave
    355360octave> mag0 = fReadBinaryFile('ch0_data.bin','single');
    356 octave> mag0 = reshape(mag0, 1024, length(mag0)/1024);
    357 octave> image(mag0*1000)
     361        mag0 = reshape(mag0, 1024, length(mag0)/1024);
     362        image(mag0*1000)
    358363}}}
    359364