Changes between Version 10 and Version 11 of WARPLab/Porting
- Timestamp:
- Feb 5, 2015, 10:11:14 AM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WARPLab/Porting
v10 v11 5 5 WARPLab 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 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. 7 ---- 8 9 '''Choosing a Transmission Length:''' In our previous WARPLab examples, we 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 10 9 11 … … 21 23 22 24 txLength = node_tx.baseband.txIQLen; 25 wl_basebandCmd(node_tx,'tx_length',txLength); 23 26 24 27 }}} … … 45 48 46 49 txLength = min(32768, maximum_buffer_len ); 50 wl_basebandCmd(node_tx,'tx_length',txLength); 47 51 48 52 }}} … … 54 58 In 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 59 60 ---- 61 62 '''Choosing a Reception Length:''' In our previous WARPLab examples, we never bothered to tell the board to capture a certain number of samples. Because the overall buffer size was small, we just let the board capture and fill the entire receive buffer. This is no longer appropriate in WARPLab 7.5 because the maximum receive buffer size can be very large. 63 64 65 66 {{{#!html 67 <table border=1 width=600><tr valign=top><td width=50% align=left> 68 }}} 69 70 {{{ 71 %WARPLab 7.4 72 73 %Trigger of transmission and reception 74 % 75 % eth_trig - UDP broadcast trigger object 76 77 eth_trig.send(); 78 79 %Read samples from the receive buffer 80 % 81 % node_rx - WARPLab node object for the receiver 82 % RF_TX - index of RF interface used for transmission 83 % rxLength - number of samples to read 84 85 rx_IQ = wl_basebandCmd(node_rx,[RF_RX],'read_IQ', 0, rxLength); 86 }}} 87 88 {{{#!html 89 </td><td width=50% align=left> 90 }}} 91 92 {{{ 93 %WARPLab 7.5 94 95 96 %Set the number of samples that should be captured 97 % 98 % node_rx - WARPLab node object for the receiver 99 % rxLength - number of samples to receive 100 101 wl_basebandCmd(node_rx,'rx_length',rxLength); 102 103 %Trigger of transmission and reception 104 % 105 % eth_trig - UDP broadcast trigger object 106 107 eth_trig.send(); 108 109 %Read samples from the receive buffer 110 % 111 % node_rx - WARPLab node object for the receiver 112 % RF_TX - index of RF interface used for transmission 113 % rxLength - number of samples to read 114 115 rx_IQ = wl_basebandCmd(node_rx,[RF_RX],'read_IQ', 0, rxLength); 116 }}} 117 118 {{{#!html 119 </td></tr></table> 120 }}} 121 122 Without the {{{rx_length}}} command, the board will default to capturing 32 kSamp in WARP v3 hardware and 16 kSamp in WARP v2 hardware. Using this command will explicitly tell the board to capture the given number of samples. 56 123 57 124