commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r10263 - in gnuradio/trunk/grc: data/platforms/python


From: jblum
Subject: [Commit-gnuradio] r10263 - in gnuradio/trunk/grc: data/platforms/python data/platforms/python/blocks src/grc_gnuradio/usrp
Date: Mon, 19 Jan 2009 15:58:17 -0700 (MST)

Author: jblum
Date: 2009-01-19 15:58:08 -0700 (Mon, 19 Jan 2009)
New Revision: 10263

Added:
   gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_sink_xxxx.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_source_xxxx.xml
Modified:
   gnuradio/trunk/grc/data/platforms/python/block_tree.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/Makefile.am
   gnuradio/trunk/grc/data/platforms/python/blocks/blks2_error_rate.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/gr_probe_mpsk_snr_c.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_sink_x.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_source_x.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_sink_x.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_source_x.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/variable_chooser.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/variable_slider.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/variable_text_box.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_client.xml
   gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_server.xml
   gnuradio/trunk/grc/src/grc_gnuradio/usrp/simple_usrp.py
Log:
replaced ", usrp2 blocks, hide for usrp params, mux defaults to 0x0

Modified: gnuradio/trunk/grc/data/platforms/python/block_tree.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/block_tree.xml     2009-01-19 
21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/block_tree.xml     2009-01-19 
22:58:08 UTC (rev 10263)
@@ -249,6 +249,8 @@
                <block>usrp_simple_sink_x</block>
                <block>usrp_dual_source_x</block>
                <block>usrp_dual_sink_x</block>
+               <block>usrp2_source_xxxx</block>
+               <block>usrp2_sink_xxxx</block>
        </cat>
        <cat>
                <name>Variables</name>

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/Makefile.am
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/Makefile.am 2009-01-19 
21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/Makefile.am 2009-01-19 
22:58:08 UTC (rev 10263)
@@ -197,6 +197,8 @@
        usrp_dual_source_x.xml \
        usrp_simple_sink_x.xml \
        usrp_simple_source_x.xml \
+       usrp2_sink_xxxx.xml \
+       usrp2_source_xxxx.xml \
        variable.xml \
        variable_chooser.xml \
        variable_sink.xml \

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/blks2_error_rate.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/blks2_error_rate.xml        
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/blks2_error_rate.xml        
2009-01-19 22:58:08 UTC (rev 10263)
@@ -20,12 +20,12 @@
                <type>enum</type>
                <option>
                        <name>Bit Error Rate</name>
-                       <key>&quot;BER&quot;</key>
+                       <key>'BER'</key>
                        <opt>hide_bps:</opt>
                </option>
                <option>
                        <name>Symbol Error Rate</name>
-                       <key>&quot;SER&quot;</key>
+                       <key>'SER'</key>
                        <opt>hide_bps:all</opt>
                </option>
        </param>

Modified: 
gnuradio/trunk/grc/data/platforms/python/blocks/gr_probe_mpsk_snr_c.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/gr_probe_mpsk_snr_c.xml     
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/gr_probe_mpsk_snr_c.xml     
2009-01-19 22:58:08 UTC (rev 10263)
@@ -9,7 +9,7 @@
        <key>gr_probe_mpsk_snr_c</key>
        <import>from grc_gnuradio import blks2 as grc_blks2</import>
        <make>grc_blks2.probe_mpsk_snr_c(
-       type=&quot;$type&quot;,
+       type='$type',
        alpha=$alpha,
        probe_rate=$probe_rate,
 )</make>

Added: gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_sink_xxxx.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_sink_xxxx.xml         
                (rev 0)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_sink_xxxx.xml 
2009-01-19 22:58:08 UTC (rev 10263)
@@ -0,0 +1,127 @@
+<?xml version="1.0"?>
+<!--
+###################################################
+##USRP2 Sink
+###################################################
+ -->
+<block>
+       <name>USRP2 Sink</name>
+       <key>usrp2_sink_xxxx</key>
+       <import>from gnuradio import usrp2</import>
+       <make>usrp2.sink_$(type.fcn)($interface, $mac_addr)
+self.$(id).set_interp_rate($interpolation)
+self.$(id).set_frequency($frequency)
+self.$(id).set_gain($gain)
+#if $auto_tr.eval
+self.$(id).set_auto_tr($auto_tr)
+#end if
+#if $tx_enb.eval
+self.$(id).set_enable($tx_enb)
+#end if
+</make>
+       <callback>set_interp_rate($interpolation)</callback>
+       <callback>set_frequency($frequency)</callback>
+       <callback>set_gain($gain)</callback>
+       <param>
+               <name>Output Type</name>
+               <key>type</key>
+               <type>enum</type>
+               <option>
+                       <name>Complex</name>
+                       <key>complex</key>
+                       <opt>fcn:32fc</opt>
+               </option>
+               <option>
+                       <name>Short</name>
+                       <key>short</key>
+                       <opt>fcn:16sc</opt>
+               </option>
+       </param>
+       <param>
+               <name>Interface</name>
+               <key>interface</key>
+               <value>eth0</value>
+               <type>string</type>
+       </param>
+       <param>
+               <name>MAC Addr</name>
+               <key>mac_addr</key>
+               <value>00:50:C2:85:3x:xx</value>
+               <type>string</type>
+       </param>
+       <param>
+               <name>Frequency</name>
+               <key>frequency</key>
+               <type>real</type>
+       </param>
+       <param>
+               <name>Interpolation</name>
+               <key>interpolation</key>
+               <type>int</type>
+       </param>
+       <param>
+               <name>Gain</name>
+               <key>gain</key>
+               <type>real</type>
+       </param>
+       <param>
+               <name>Auto T/R</name>
+               <key>auto_tr</key>
+               <value></value>
+               <type>enum</type>
+               <hide>$auto_tr.hide</hide>
+               <option>
+                       <name>Ignore</name>
+                       <key></key>
+                       <opt>hide:part</opt>
+               </option>
+               <option>
+                       <name>Enable</name>
+                       <key>True</key>
+                       <opt>hide:none</opt>
+               </option>
+               <option>
+                       <name>Disable</name>
+                       <key>False</key>
+                       <opt>hide:none</opt>
+               </option>
+       </param>
+       <param>
+               <name>TX Enable</name>
+               <key>tx_enb</key>
+               <value></value>
+               <type>enum</type>
+               <hide>$tx_enb.hide</hide>
+               <option>
+                       <name>Ignore</name>
+                       <key></key>
+                       <opt>hide:part</opt>
+               </option>
+               <option>
+                       <name>Enable</name>
+                       <key>True</key>
+                       <opt>hide:none</opt>
+               </option>
+               <option>
+                       <name>Disable</name>
+                       <key>False</key>
+                       <opt>hide:none</opt>
+               </option>
+       </param>
+       <sink>
+               <name>in</name>
+               <type>$type</type>
+       </sink>
+       <doc>
+The USRP2 sink inputs 100 Megasamples per second / interpolation.
+
+--- Flex RF specific ---
+The "Auto TR" and "TX Enable" settings are flex rf specific and should be left 
at "Ignore" unless this is a flex rf board.
+
+If enabled, "Auto Transmit/Receive Switching" handles the preference for 
transmit packets vs receive packets. \
+By default, "Auto TR" is disabled.
+
+The "Transmit Enable" configures the transmitter to be on or off. \
+Do not leave this unconfigured.
+       </doc>
+</block>

Added: gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_source_xxxx.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_source_xxxx.xml       
                        (rev 0)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/usrp2_source_xxxx.xml       
2009-01-19 22:58:08 UTC (rev 10263)
@@ -0,0 +1,127 @@
+<?xml version="1.0"?>
+<!--
+###################################################
+##USRP2 Source
+###################################################
+ -->
+<block>
+       <name>USRP2 Source</name>
+       <key>usrp2_source_xxxx</key>
+       <import>from gnuradio import usrp2</import>
+       <make>usrp2.source_$(type.fcn)($interface, $mac_addr)
+self.$(id).set_decim_rate($decimation)
+self.$(id).set_frequency($frequency)
+self.$(id).set_gain($gain)
+#if $auto_tr.eval
+self.$(id).set_auto_tr($auto_tr)
+#end if
+#if $rx_ant.eval
+self.$(id).select_rx_antenna($rx_ant)
+#end if
+</make>
+       <callback>set_decim_rate($decimation)</callback>
+       <callback>set_frequency($frequency)</callback>
+       <callback>set_gain($gain)</callback>
+       <param>
+               <name>Output Type</name>
+               <key>type</key>
+               <type>enum</type>
+               <option>
+                       <name>Complex</name>
+                       <key>complex</key>
+                       <opt>fcn:32fc</opt>
+               </option>
+               <option>
+                       <name>Short</name>
+                       <key>short</key>
+                       <opt>fcn:16sc</opt>
+               </option>
+       </param>
+       <param>
+               <name>Interface</name>
+               <key>interface</key>
+               <value>eth0</value>
+               <type>string</type>
+       </param>
+       <param>
+               <name>MAC Addr</name>
+               <key>mac_addr</key>
+               <value>00:50:C2:85:3x:xx</value>
+               <type>string</type>
+       </param>
+       <param>
+               <name>Frequency</name>
+               <key>frequency</key>
+               <type>real</type>
+       </param>
+       <param>
+               <name>Decimation</name>
+               <key>decimation</key>
+               <type>int</type>
+       </param>
+       <param>
+               <name>Gain</name>
+               <key>gain</key>
+               <type>real</type>
+       </param>
+       <param>
+               <name>Auto T/R</name>
+               <key>auto_tr</key>
+               <value></value>
+               <type>enum</type>
+               <hide>$auto_tr.hide</hide>
+               <option>
+                       <name>Ignore</name>
+                       <key></key>
+                       <opt>hide:part</opt>
+               </option>
+               <option>
+                       <name>Enable</name>
+                       <key>True</key>
+                       <opt>hide:none</opt>
+               </option>
+               <option>
+                       <name>Disable</name>
+                       <key>False</key>
+                       <opt>hide:none</opt>
+               </option>
+       </param>
+       <param>
+               <name>RX Antenna</name>
+               <key>rx_ant</key>
+               <value></value>
+               <type>enum</type>
+               <hide>$rx_ant.hide</hide>
+               <option>
+                       <name>Ignore</name>
+                       <key></key>
+                       <opt>hide:part</opt>
+               </option>
+               <option>
+                       <name>TX/RX</name>
+                       <key>'TX/RX'</key>
+                       <opt>hide:none</opt>
+               </option>
+               <option>
+                       <name>RX2</name>
+                       <key>'RX2'</key>
+                       <opt>hide:none</opt>
+               </option>
+       </param>
+       <source>
+               <name>out</name>
+               <type>$type</type>
+       </source>
+       <doc>
+The USRP2 source outputs 100 Megasamples per second / decimation.
+
+--- Flex RF specific ---
+The "Auto TR" and "RX Antenna" settings are flex rf specific and should be 
left at "Ignore" unless this is a flex rf board.
+
+If enabled, "Auto Transmit/Receive Switching" handles the preference for 
transmit packets vs receive packets. \
+By default, "Auto TR" is disabled.
+
+The "Receive Antenna Setting" selects one of the SMA connectors as the data 
source. \
+By default, 'TX/RX' is selected.
+       </doc>
+</block>

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_sink_x.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_sink_x.xml        
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_sink_x.xml        
2009-01-19 22:58:08 UTC (rev 10263)
@@ -74,25 +74,30 @@
        <param>
                <name>Mux</name>
                <key>mux</key>
-               <value>0xba98</value>
+               <value>0x0</value>
                <type>hex</type>
+               <hide>part</hide>
        </param>
        <param>
                <name>Auto T/R</name>
                <key>auto_tr</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$auto_tr.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <param>
@@ -100,17 +105,21 @@
                <key>tx_enb_a</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$tx_enb_a.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <param>
@@ -118,17 +127,21 @@
                <key>tx_enb_b</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$tx_enb_b.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <sink>

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_source_x.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_source_x.xml      
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/usrp_dual_source_x.xml      
2009-01-19 22:58:08 UTC (rev 10263)
@@ -74,25 +74,30 @@
        <param>
                <name>Mux</name>
                <key>mux</key>
-               <value>0x3210</value>
+               <value>0x0</value>
                <type>hex</type>
+               <hide>part</hide>
        </param>
        <param>
                <name>Auto T/R</name>
                <key>auto_tr</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$auto_tr.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <param>
@@ -100,17 +105,21 @@
                <key>rx_ant_a</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$rx_ant_a.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>TX/RX</name>
-                       <key>&quot;TX/RX&quot;</key>
+                       <key>'TX/RX'</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>RX2</name>
-                       <key>&quot;RX2&quot;</key>
+                       <key>'RX2'</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <param>
@@ -118,17 +127,21 @@
                <key>rx_ant_b</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$rx_ant_b.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>TX/RX</name>
-                       <key>&quot;TX/RX&quot;</key>
+                       <key>'TX/RX'</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>RX2</name>
-                       <key>&quot;RX2&quot;</key>
+                       <key>'RX2'</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <source>

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_sink_x.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_sink_x.xml      
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_sink_x.xml      
2009-01-19 22:58:08 UTC (rev 10263)
@@ -14,11 +14,7 @@
        frequency=$frequency,
        interpolation=$interpolation,
        gain=$gain,
-#if $mux.eval == hex(0)
-       mux=None,
-#else
        mux=$mux,
-#end if
        auto_tr=$auto_tr,
        tx_enb=$tx_enb,
 )</make>
@@ -84,23 +80,28 @@
                <key>mux</key>
                <value>0x0</value>
                <type>hex</type>
+               <hide>part</hide>
        </param>
        <param>
                <name>Auto T/R</name>
                <key>auto_tr</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$auto_tr.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <param>
@@ -108,17 +109,21 @@
                <key>tx_enb</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$tx_enb.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <sink>

Modified: 
gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_source_x.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_source_x.xml    
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/usrp_simple_source_x.xml    
2009-01-19 22:58:08 UTC (rev 10263)
@@ -14,11 +14,7 @@
        frequency=$frequency,
        decimation=$decimation,
        gain=$gain,
-#if $mux.eval == hex(0)
-       mux=None,
-#else
        mux=$mux,
-#end if
        auto_tr=$auto_tr,
        rx_ant=$rx_ant,
 )</make>
@@ -92,23 +88,28 @@
                <key>mux</key>
                <value>0x0</value>
                <type>hex</type>
+               <hide>part</hide>
        </param>
        <param>
                <name>Auto T/R</name>
                <key>auto_tr</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$auto_tr.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>Enable</name>
                        <key>True</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>Disable</name>
                        <key>False</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <param>
@@ -116,17 +117,21 @@
                <key>rx_ant</key>
                <value>None</value>
                <type>enum</type>
+               <hide>$rx_ant.hide</hide>
                <option>
                        <name>Ignore</name>
                        <key>None</key>
+                       <opt>hide:part</opt>
                </option>
                <option>
                        <name>TX/RX</name>
-                       <key>&quot;TX/RX&quot;</key>
+                       <key>'TX/RX'</key>
+                       <opt>hide:none</opt>
                </option>
                <option>
                        <name>RX2</name>
-                       <key>&quot;RX2&quot;</key>
+                       <key>'RX2'</key>
+                       <opt>hide:none</opt>
                </option>
        </param>
        <source>

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/variable_chooser.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/variable_chooser.xml        
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/variable_chooser.xml        
2009-01-19 22:58:08 UTC (rev 10263)
@@ -14,7 +14,7 @@
                #if $label.eval
        label=$label,
                #else
-       label=&quot;$id&quot;,
+       label='$id',
                #end if
        index=$value_index,
        choices=$choices,

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/variable_slider.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/variable_slider.xml 
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/variable_slider.xml 
2009-01-19 22:58:08 UTC (rev 10263)
@@ -14,7 +14,7 @@
                #if $label.eval
        label=$label,
                #else
-       label=&quot;$id&quot;,
+       label='$id',
                #end if
        value=$id,
        min=$min,

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/variable_text_box.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/variable_text_box.xml       
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/variable_text_box.xml       
2009-01-19 22:58:08 UTC (rev 10263)
@@ -14,7 +14,7 @@
                #if $label.eval
        label=$label,
                #else
-       label=&quot;$id&quot;,
+       label='$id',
                #end if
        value=$id,
 )

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_client.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_client.xml   
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_client.xml   
2009-01-19 22:58:08 UTC (rev 10263)
@@ -8,7 +8,7 @@
        <name>XMLRPC Client</name>
        <key>xmlrpc_client</key>
        <import>import xmlrpclib</import>
-       <make>xmlrpclib.Server(&quot;http://$(addr.eval):$(port)&quot;)</make>
+       <make>xmlrpclib.Server('http://$(addr.eval):$(port)')</make>
        <callback>$(callback.eval)($variable)</callback>
        <param>
                <name>Address</name>

Modified: gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_server.xml
===================================================================
--- gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_server.xml   
2009-01-19 21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/data/platforms/python/blocks/xmlrpc_server.xml   
2009-01-19 22:58:08 UTC (rev 10263)
@@ -33,7 +33,7 @@
 Example client in python:
 
 import xmlrpclib
-s = xmlrpclib.Server(&quot;http://localhost:8080&quot;)
+s = xmlrpclib.Server('http://localhost:8080')
 s.set_freq(5000)
        </doc>
 </block>

Modified: gnuradio/trunk/grc/src/grc_gnuradio/usrp/simple_usrp.py
===================================================================
--- gnuradio/trunk/grc/src/grc_gnuradio/usrp/simple_usrp.py     2009-01-19 
21:51:07 UTC (rev 10262)
+++ gnuradio/trunk/grc/src/grc_gnuradio/usrp/simple_usrp.py     2009-01-19 
22:58:08 UTC (rev 10263)
@@ -146,7 +146,7 @@
 class _simple_source(gr.hier_block2, _simple_usrp):
        """A single usrp source of IO type short or complex."""
 
-       def __init__(self, number, subdev_spec, frequency, decimation, gain, 
mux=None, auto_tr=None, rx_ant=None):
+       def __init__(self, number, subdev_spec, frequency, decimation, gain, 
mux=0x0, auto_tr=None, rx_ant=None):
                """
                USRP simple source contructor.
                @param number the unit number
@@ -168,7 +168,7 @@
                u = self.constructor[0](number, nchan=1)
                if subdev_spec is None: subdev_spec = usrp.pick_rx_subdevice(u)
                u.set_decim_rate(decimation)
-               if mux is None: mux = usrp.determine_rx_mux_value(u, 
subdev_spec)
+               if not mux: mux = usrp.determine_rx_mux_value(u, subdev_spec)
                u.set_mux(mux)
                subdev = _setup_rx_subdev(u, subdev_spec, 0, gain, frequency, 
auto_tr, rx_ant)
                _simple_usrp.__init__(self, u, subdev, 0)
@@ -186,7 +186,7 @@
 class _simple_sink(gr.hier_block2, _simple_usrp):
        """A single usrp sink of IO type short or complex."""
 
-       def __init__(self, number, subdev_spec, frequency, interpolation, gain, 
mux=None, auto_tr=None, tx_enb=None):
+       def __init__(self, number, subdev_spec, frequency, interpolation, gain, 
mux=0x0, auto_tr=None, tx_enb=None):
                """
                USRP simple sink contructor.
                @param number the unit number
@@ -208,7 +208,7 @@
                u = self.constructor[0](number, nchan=1)
                if subdev_spec is None: subdev_spec = usrp.pick_tx_subdevice(u)
                u.set_interp_rate(interpolation)
-               if mux is None: mux = usrp.determine_tx_mux_value(u, 
subdev_spec)
+               if not mux: mux = usrp.determine_tx_mux_value(u, subdev_spec)
                u.set_mux(mux)
                subdev = _setup_tx_subdev(u, subdev_spec, gain, frequency, 
auto_tr, tx_enb)
                _simple_usrp.__init__(self, u, subdev, subdev.which())
@@ -299,7 +299,7 @@
 class _dual_source(gr.hier_block2, _dual_usrp):
        """A dual usrp source of IO type short or complex."""
 
-       def __init__(self, number, frequency_a, frequency_b, decimation, 
gain_a, gain_b, mux=0x3210, auto_tr=None, rx_ant_a=None, rx_ant_b=None):
+       def __init__(self, number, frequency_a, frequency_b, decimation, 
gain_a, gain_b, mux=0x0, auto_tr=None, rx_ant_a=None, rx_ant_b=None):
                """
                USRP dual source contructor.
                @param number the unit number
@@ -322,6 +322,7 @@
                #create usrp object
                u = self.constructor[0](number, nchan=2)
                u.set_decim_rate(decimation)
+               if not mux: mux = 0x3210
                u.set_mux(mux)
                subdev_a = _setup_rx_subdev(u, (0, 0), 0, gain_a, frequency_a, 
auto_tr, rx_ant_a)
                subdev_b = _setup_rx_subdev(u, (1, 0), 1, gain_b, frequency_b, 
auto_tr, rx_ant_b)
@@ -342,7 +343,7 @@
 class _dual_sink(gr.hier_block2, _dual_usrp):
        """A dual usrp sink of IO type short or complex."""
 
-       def __init__(self, number, frequency_a, frequency_b, interpolation, 
gain_a, gain_b, mux=0xba98, auto_tr=None, tx_enb_a=None, tx_enb_b=None):
+       def __init__(self, number, frequency_a, frequency_b, interpolation, 
gain_a, gain_b, mux=0x0, auto_tr=None, tx_enb_a=None, tx_enb_b=None):
                """
                USRP dual sink contructor.
                @param number the unit number
@@ -363,6 +364,7 @@
                #create usrp object
                u = self.constructor[0](number, nchan=2)
                u.set_interp_rate(interpolation)
+               if not mux: mux = 0xba98
                u.set_mux(mux)
                subdev_a = _setup_tx_subdev(u, (0, 0), gain_a, frequency_a, 
auto_tr, tx_enb_a)
                subdev_b = _setup_tx_subdev(u, (1, 0), gain_b, frequency_b, 
auto_tr, tx_enb_b)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]