This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Piotr Krysik gerrit-no-reply at lists.osmocom.orgPiotr Krysik has submitted this change and it was merged. ( https://gerrit.osmocom.org/12576 ) Change subject: trx/radio_if.py: use existing 'dict_toggle_sign' block ...................................................................... trx/radio_if.py: use existing 'dict_toggle_sign' block Change-Id: Ifa616644a858f493b9f8706663f9e7fed717f3d0 --- M python/trx/radio_if.py 1 file changed, 1 insertion(+), 19 deletions(-) Approvals: Harald Welte: Looks good to me, but someone else must approve Piotr Krysik: Looks good to me, approved; Verified diff --git a/python/trx/radio_if.py b/python/trx/radio_if.py index 85970a9..49e6788 100644 --- a/python/trx/radio_if.py +++ b/python/trx/radio_if.py @@ -38,25 +38,7 @@ from gnuradio import filter from gnuradio.filter import firdes - -# HACK: should be implemented in C++! -class dict_toggle_sign(gr.basic_block): - def __init__(self): # only default arguments here - gr.basic_block.__init__(self, - name='Change sign of elts in dict', - in_sig=[], - out_sig=[] - ) - self.message_port_register_in(pmt.intern("dict_in")) - self.message_port_register_out(pmt.intern("dict_out")) - self.set_msg_handler(pmt.intern("dict_in"), self.change_sign) - - def change_sign(self, msg): - if pmt.is_dict(msg): - d = pmt.to_python(msg) - for key, value in d.items(): - d[key] *= -1 - self.message_port_pub(pmt.intern("dict_out"), pmt.to_pmt(d)) +from dict_toggle_sign import dict_toggle_sign class radio_if(gr.top_block): # PHY specific variables -- To view, visit https://gerrit.osmocom.org/12576 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: gr-gsm Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: Ifa616644a858f493b9f8706663f9e7fed717f3d0 Gerrit-Change-Number: 12576 Gerrit-PatchSet: 1 Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com> Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Piotr Krysik <ptrkrysik at gmail.com> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190205/208a1a43/attachment.htm>