Changes between Version 13 and Version 14 of WARPLab/Porting
- Timestamp:
- Feb 5, 2015, 10:26:39 AM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WARPLab/Porting
v13 v14 15 15 16 16 {{{ 17 % WARPLab 7.418 19 % We will use the transmitter's I/Q buffer length to determine20 % how long our transmission can be17 % WARPLab 7.4 18 19 % We will use the transmitter's I/Q buffer length to determine 20 % how long our transmission can be 21 21 % 22 22 % node_tx - WARPLab node object for the transmitter 23 23 24 24 txLength = node_tx.baseband.txIQLen; 25 wl_basebandCmd(node_tx, 'tx_length',txLength);26 27 }}} 28 29 {{{#!html 30 </td><td width=50% align=left> 31 }}} 32 33 {{{ 34 % WARPLab 7.535 36 % We will read the transmitter's maximum I/Q buffer length37 % and assign that value to a temporary variable.25 wl_basebandCmd(node_tx, 'tx_length', txLength); 26 27 }}} 28 29 {{{#!html 30 </td><td width=50% align=left> 31 }}} 32 33 {{{ 34 % WARPLab 7.5 35 36 % We will read the transmitter's maximum I/Q buffer length 37 % and assign that value to a temporary variable. 38 38 % 39 39 % node_tx - WARPLab node object for the transmitter 40 40 % RF_TX - index of RF interface used for transmission 41 41 42 maximum_buffer_len = wl_basebandCmd(node_tx, RF_TX,'tx_buff_max_num_samples');43 44 % Our transmission length for this example does not need45 % to fill the entire transmit buffer, so we will use the smaller46 % of two values: the maximum buffer length the board47 % can support or an arbitrary value defined by this script42 maximum_buffer_len = wl_basebandCmd(node_tx, RF_TX, 'tx_buff_max_num_samples'); 43 44 % Our transmission length for this example does not need 45 % to fill the entire transmit buffer, so we will use the smaller 46 % of two values: the maximum buffer length the board 47 % can support or an arbitrary value defined by this script 48 48 49 49 txLength = min(32768, maximum_buffer_len); 50 wl_basebandCmd(node_tx, 'tx_length',txLength);50 wl_basebandCmd(node_tx, 'tx_length', txLength); 51 51 52 52 }}} … … 69 69 70 70 {{{ 71 % WARPLab 7.472 73 % Trigger of transmission and reception71 % WARPLab 7.4 72 73 % Trigger of transmission and reception 74 74 % 75 75 % eth_trig - UDP broadcast trigger object … … 77 77 eth_trig.send(); 78 78 79 % Read samples from the receive buffer79 % Read samples from the receive buffer 80 80 % 81 81 % node_rx - WARPLab node object for the receiver … … 83 83 % rxLength - number of samples to read 84 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.594 95 96 % Set the number of samples that should be captured85 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 97 % 98 98 % node_rx - WARPLab node object for the receiver 99 99 % rxLength - number of samples to receive 100 100 101 wl_basebandCmd(node_rx, 'rx_length',rxLength);102 103 % Trigger of transmission and reception101 wl_basebandCmd(node_rx, 'rx_length', rxLength); 102 103 % Trigger of transmission and reception 104 104 % 105 105 % eth_trig - UDP broadcast trigger object … … 107 107 eth_trig.send(); 108 108 109 % Read samples from the receive buffer109 % Read samples from the receive buffer 110 110 % 111 111 % node_rx - WARPLab node object for the receiver … … 113 113 % rxLength - number of samples to read 114 114 115 rx_IQ = wl_basebandCmd(node_rx, [RF_RX],'read_IQ', 0, rxLength);115 rx_IQ = wl_basebandCmd(node_rx, [RF_RX], 'read_IQ', 0, rxLength); 116 116 }}} 117 117