Changes between Version 9 and Version 10 of WARPLab/Porting


Ignore:
Timestamp:
Feb 5, 2015, 9:44:06 AM (9 years ago)
Author:
chunter
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • WARPLab/Porting

    v9 v10  
    11[[TracNav(WARPLab/TOC)]]
    22
    3 = WARPLab 7: Porting Code from old WARPLab =
     3= New Script Conventions in WARPLab 7.5 and Beyond =
     4
     5WARPLab 7.5 was designed to be fully compatible with unmodified WARPLab 7.4 scripts. No changes are necessary for these older scripts to run. There might, however, be a warning printed to the MATLAB console about deprecated behavior. In this documentation, we describe this deprecated behavior and explain the small changes required to adopt the new conventions.
     6
     7'''Choosing a Transmission Length:''' In our WARPLab examples, we previously adopted the convention of building a transmission waveform whose length was equal to the maximum buffer length the board could support. As of WARPLab 7.5, this number can be [wiki:WARPLab/LargeBuffers extremely large]. We have updated all of our example scripts with the following change.
     8
     9
     10{{{#!html
     11<table border=1 width=600><tr valign=top><td width=50% align=left>
     12}}}
     13
     14{{{
     15%WARPLab 7.4
     16
     17%We will use the transmitter's I/Q buffer length to determine
     18%how long our transmission can be
     19%
     20% node_tx - WARPLab node object for the transmitter
     21
     22txLength = node_tx.baseband.txIQLen;
     23
     24}}}
     25
     26{{{#!html
     27</td><td width=50% align=left>
     28}}}
     29
     30{{{
     31%WARPLab 7.5
     32
     33%We will read the transmitter's maximum I/Q buffer length
     34%and assign that value to a temporary variable.
     35%
     36% node_tx - WARPLab node object for the transmitter
     37% RF_TX - index of RF interface used for transmission
     38
     39maximum_buffer_len = wl_basebandCmd(node_tx,RF_TX,'tx_buff_max_num_samples');
     40
     41%Our transmission length for this example does not need
     42%to fill the entire transmit buffer, so we will use the smaller
     43%of two values: the maximum buffer length the board
     44%can support or an arbitrary value defined by this script
     45
     46txLength = min(32768, maximum_buffer_len );
     47
     48}}}
     49
     50{{{#!html
     51</td></tr></table>
     52}}}
     53
     54In WARPLab 7.5, the {{{txIQLen}}} parameter of a node object still exists and defaults to 32 kSamp for WARP v3 hardware and 16 kSamp for WARP v2 hardware. Attempting to read this parameter will work, but it will print a deprecation warning to the MATLAB console. Instead, users should use the new {{{tx_buff_max_num_samples}}} baseband command to determine the maximum number of samples that the transmit buffers can support.
     55
     56
     57
     58= Porting Code from old WARPLab 6 =
    459The basic flow of an experiment is the same across all versions of WARPLab. However WARPLab 7 has been designed to simplify experiments utilizing multiple nodes, each with multiple RF interfaces. The code samples below illustrate equivalent processes in WARPLab 6 and WARPLab 7, emphasizing the more compact and portable syntax available in the WARPLab 7 framework.
    560
     
    256311</td></tr></table>
    257312}}}
    258