From b26ea69676c09f5366a9e2f33b11ae5a7521ffe5 Mon Sep 17 00:00:00 2001
From: jcorgan <jcorgan@221aa14e-8319-0410-a670-987f0aec2ac5>
Date: Sat, 28 Apr 2007 02:20:28 +0000
Subject: Merged -r 5137:5174 from developer branch jcorgan/hb.  Trunk passes
 distcheck. Converts gr.hier_block2 API to not use 'define_component'
 methodology anymore.

git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@5177 221aa14e-8319-0410-a670-987f0aec2ac5
---
 gnuradio-examples/python/hier/digital/transmit_path.py | 18 ++++--------------
 1 file changed, 4 insertions(+), 14 deletions(-)

(limited to 'gnuradio-examples/python/hier/digital/transmit_path.py')

diff --git a/gnuradio-examples/python/hier/digital/transmit_path.py b/gnuradio-examples/python/hier/digital/transmit_path.py
index c517210aef..4ed477ea15 100644
--- a/gnuradio-examples/python/hier/digital/transmit_path.py
+++ b/gnuradio-examples/python/hier/digital/transmit_path.py
@@ -1,5 +1,5 @@
 #
-# Copyright 2005,2006 Free Software Foundation, Inc.
+# Copyright 2005,2006,2007 Free Software Foundation, Inc.
 # 
 # This file is part of GNU Radio
 # 
@@ -33,16 +33,13 @@ from pick_bitrate import pick_tx_bitrate
 #                              transmit path
 # /////////////////////////////////////////////////////////////////////////////
 
-class transmit_path(gr.hier_block2): 
+class transmit_path(gr.top_block): 
     def __init__(self, modulator_class, options):
         '''
         See below for what options should hold
         '''
         
-        gr.hier_block2.__init__(self, "transmit_path",
-                                gr.io_signature(0,0,0), # Input signature
-                                gr.io_signature(0,0,0)) # Output signature
-
+        gr.top_block.__init__(self, "transmit_path")
         options = copy.copy(options)    # make a copy so we can destructively modify
 
         self._verbose            = options.verbose
@@ -99,14 +96,7 @@ class transmit_path(gr.hier_block2):
         if self._verbose:
             self._print_verbage()
 
-        # Define the components
-        self.define_component("packet_transmitter", self.packet_transmitter)
-        self.define_component("amp", self.amp)
-        self.define_component("usrp", self.u)
-
-        # Connect components in the flowgraph; set amp component to the output of this block
-        self.connect("packet_transmitter", 0, "amp", 0)
-        self.connect("amp", 0, "usrp", 0)
+        self.connect(self.packet_transmitter, self.amp, self.u)
 
     def _setup_usrp_sink(self):
         """
-- 
cgit v1.2.3