Yes, sure. Thank you. Now it is working. Regards,
----------------- Azza Ben Mosbah On Thu, Mar 6, 2014 at 12:45 PM, Ben Reynwar <[email protected]> wrote: > Try changing: > "digital.constellation_qpsk.base()" > to: > "digital.constellation_qpsk().base()" > > Note the brackets after the constellation_qpsk constructor. > > On Thu, Mar 6, 2014 at 9:05 AM, Azza Ben Mosbah > <[email protected]> wrote: > > Thank you. > > Actually, I am doing it in the GRC interface. > > > > When I use the .base(), it returns the following error: > > > > Param - Constellation Object(constellation): > > Value "digital.constellation_qpsk.base()" cannot be evaluated: > > 'function' object has no attribute 'base' > > > > I don't know what is the matter. But, maybe, there is some issues with my > > GRC version (GNU Radio Companion 3.6.2). > > > > > > Regards, > > > > ----------------- > > Azza Ben Mosbah > > > > > > > > On Thu, Mar 6, 2014 at 10:54 AM, Tom Rondeau <[email protected]> wrote: > >> > >> On Wed, Mar 5, 2014 at 8:59 AM, Azza Ben Mosbah > >> <[email protected]> wrote: > >> > Tom, > >> > > >> > > >> > Thank you for the help. But, even that didn't work. > >> > > >> > I tried a different approach. I configured the "Constellation Object" > >> > block > >> > with the symbol map and the constellation points. Then, I called it in > >> > the > >> > argument of the "Constellation Decoder" block. And it worked. > >> > > >> > I am still wondering what is the right way to define a > >> > 'digital_constellation_sptr' type in the "Constellation Decoder" > >> > argument > >> > without passing by the "Constellation Object" block. > >> > > >> > > >> > Regards, > >> > Azza > >> > >> Yes, that Constellation Object in GRC returns the .base() > >> automatically for you so that you can pass it to the Constellation > >> Decode/Receiver blocks easily. > >> > >> You really should be able to use the .base() method of those > >> constellation blocks this way. Are you in GRC doing this or doing your > >> own Python? There could be some issues with GRC properly interpreting > >> your casting using base() (which is likely related to why the > >> Constellation Objects just return the.base() method for you). > >> > >> Tom > >> > >> > >> > >> > On Tue, Mar 4, 2014 at 5:16 PM, Tom Rondeau <[email protected]> wrote: > >> >> > >> >> On Tue, Mar 4, 2014 at 4:17 PM, Azza Ben Mosbah > >> >> <[email protected]> wrote: > >> >> > Hi All, > >> >> > > >> >> > I am manipulating GNU Radio Companion. > >> >> > While using the "Constellation Decoder" block, I have put > >> >> > digital.constellation_qpsk as a "Constellation Object" argument. > But, > >> >> > I > >> >> > have > >> >> > found an error when I have executed the flow graph: > >> >> > > >> >> > Traceback (most recent call last): > >> >> > File "/users/anb10/metrics/error_rate.py", line 342, in <module> > >> >> > tb = error_rate() > >> >> > File "/users/anb10/metrics/error_rate.py", line 225, in __init__ > >> >> > self.digital_constellation_decoder_cb_0 = > >> >> > digital.constellation_decoder_cb(digital.constellation_qpsk) > >> >> > File > >> >> > > >> >> > > "/usr/lib64/python2.6/site-packages/gnuradio/digital/digital_swig.py", > >> >> > line > >> >> > 3096, in constellation_decoder_cb > >> >> > return _digital_swig.constellation_decoder_cb(*args, **kwargs) > >> >> > TypeError: in method 'constellation_decoder_cb', argument 1 of type > >> >> > 'digital_constellation_sptr' > >> >> > > >> >> > I don't know what went wrong. I have even tried > >> >> > digital.psk.psk_constellation(m=4,mod_code='gray'), > >> >> > digital.constellation_8psk and > >> >> > digital.psk.psk_constellation(m=8,mod_code='gray') as a > >> >> > "Constellation > >> >> > Object" argument. > >> >> > > >> >> > So, what is the proper way to define the argument (Constellation > >> >> > Object) > >> >> > in > >> >> > the "Constellation Decoder" block? > >> >> > > >> >> > I hope you can give me some ideas. Any help is appreciated. Thank > >> >> > you. > >> >> > > >> >> > Regards, > >> >> > Azza > >> >> > >> >> Azza, > >> >> > >> >> Check out the documentation page: > >> >> > >> >> > >> >> > http://gnuradio.org/doc/doxygen/classgr_1_1digital_1_1constellation__decoder__cb.html > >> >> > >> >> It's not entirely clear (unless you know to look for it). You want to > >> >> pass the constellation object using the base() parameter to get to > the > >> >> parent class. Basically, you'd call it: > >> >> > >> >> digital.constellation_decoder_cb(digital.constellation_qpsk.base()) > >> >> > >> >> Tom > >> > > >> > > > > > > > > > _______________________________________________ > > Discuss-gnuradio mailing list > > [email protected] > > https://lists.gnu.org/mailman/listinfo/discuss-gnuradio > > >
_______________________________________________ Discuss-gnuradio mailing list [email protected] https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
