Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Python (http://www.velocityreviews.com/forums/f43-python.html)
-   -   Re: AttributeError: 'gr_hier_block2_sptr' object has no attribute'set_callback' (http://www.velocityreviews.com/forums/t957619-re-attributeerror-gr_hier_block2_sptr-object-has-no-attributeset_callback.html)

Dave Angel 02-14-2013 09:39 PM

Re: AttributeError: 'gr_hier_block2_sptr' object has no attribute'set_callback'
 
On 02/14/2013 04:16 PM, md123@nycap.rr.com wrote:
>
> I am using ubuntu 12.10 and python version 2.7.3. i run the following command in terminal:
>
> <snip>


>
> def connect(self, *points):
> """
> Connect two or more block endpoints. An endpoint is either a (block,
> port)
> tuple or a block instance. In the latter case, the port number is
> assumed
> to be zero.
>
> To connect the hierarchical block external inputs or outputs to internal
> block
> inputs or outputs, use 'self' in the connect call.
>
> If multiple arguments are provided, connect will attempt to wire them in
> series,
> interpreting the endpoints as inputs or outputs as appropriate.
> """
>
> if len (points) < 1:
> raise ValueError, ("connect requires at least one endpoint; %d
> provided." % (len (points),))
> else:
> if len(points) == 1:
> self._hb.primitive_connect(points[0].to_basic_block())
> else:
> for i in range (1, len (points)):
> self._connect(points[i-1], points[i])
>
> def _connect(self, src, dst):
> (src_block, src_port) = self._coerce_endpoint(src)
> (dst_block, dst_port) = self._coerce_endpoint(dst)
> self._hb.primitive_connect(src_block.to_basic_bloc k(), src_port,
> dst_block.to_basic_block(), dst_port)


For those of us using text-based email, the program in this message is
totally unreadable. This is a text mailing-list, so please put your
email program in text mode, or you'll lose much of your audience.

Why are you showing us the source to a file from gnuradio library
module, instead of your own code?



--
DaveA


All times are GMT. The time now is 09:51 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.