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/.
laforge gerrit-no-reply at lists.osmocom.orglaforge has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/20172 ) Change subject: utils.py: Add helper method to convert a hex string into array of N bytes string elements ...................................................................... utils.py: Add helper method to convert a hex string into array of N bytes string elements Change-Id: I3af080726079729eae92af183de40dfc70c9390e --- M pySim/utils.py 1 file changed, 3 insertions(+), 0 deletions(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified diff --git a/pySim/utils.py b/pySim/utils.py index d0d6cb5..e5434a5 100644 --- a/pySim/utils.py +++ b/pySim/utils.py @@ -128,6 +128,9 @@ def hexstr_to_threebytearr(s): return [s[i:i+6] for i in range(0, len(s), 6) ] +def hexstr_to_Nbytearr(s, nbytes): + return [s[i:i+(nbytes*2)] for i in range(0, len(s), (nbytes*2)) ] + # Accepts hex string representing three bytes def dec_mcc_from_plmn(plmn): ia = h2i(plmn) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/20172 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I3af080726079729eae92af183de40dfc70c9390e Gerrit-Change-Number: 20172 Gerrit-PatchSet: 4 Gerrit-Owner: herlesupreeth <herlesupreeth at gmail.com> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: herlesupreeth <herlesupreeth at gmail.com> Gerrit-Reviewer: laforge <laforge at osmocom.org> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200920/86939fc4/attachment.htm>