lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

March 2026

  • 1 participants
  • 1933 discussions
[M] Change in osmo-ccid-firmware[master]: ccid: properly emit wait time ext messages
by Hoernchen 10 Mar '26

10 Mar '26
Attention is currently required from: Hoernchen. Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/42306?usp=email to look at the new patch set (#2). The following approvals got outdated and were removed: Verified-1 by Jenkins Builder Change subject: ccid: properly emit wait time ext messages ...................................................................... ccid: properly emit wait time ext messages The CCID message that tells the host that the card asked for a wait time extension was missing. This is a bit weird, because it breaks the 1:1 relationship between messages and responses that usually exists, nor does it consume a bSeq, so we just count and emit WT msgs as appropriate. Closes: OS#6458 Change-Id: Ib69483d453a0e5ebb1bc1885a8f78790a0f10d70 --- M ccid_common/ccid_device.h M ccid_common/ccid_slot_fsm.c M ccid_common/iso7816_fsm.c M ccid_common/iso7816_fsm.h 4 files changed, 99 insertions(+), 82 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware refs/changes/06/42306/2 -- To view, visit https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/42306?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newpatchset Gerrit-Project: osmo-ccid-firmware Gerrit-Branch: master Gerrit-Change-Id: Ib69483d453a0e5ebb1bc1885a8f78790a0f10d70 Gerrit-Change-Number: 42306 Gerrit-PatchSet: 2 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Attention: Hoernchen <ewild(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ccid-firmware[master]: firmware: enable watchdog timer
by Hoernchen 10 Mar '26

10 Mar '26
Hoernchen has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/42307?usp=email ) Change subject: firmware: enable watchdog timer ...................................................................... firmware: enable watchdog timer 2s is plenty, and while not perfect it should at least ensure that hangs that require manual intervention happen rarely if at all. At least from a custimer POV having resets in case something breaks is better than ending up with non working devices that are stuck. Change-Id: I1ef1fc70d33492efe0171a7879c1a23f16957195 --- M sysmoOCTSIM/main.c 1 file changed, 14 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware refs/changes/07/42307/1 diff --git a/sysmoOCTSIM/main.c b/sysmoOCTSIM/main.c index 74de4bf..75fb4ad 100644 --- a/sysmoOCTSIM/main.c +++ b/sysmoOCTSIM/main.c @@ -685,6 +685,17 @@ printf("Chip ID: %s\r\n", sernr_buf); printf("Reset cause: %s\r\n", rstcause_buf); + /* Configure and enable WDT with ~2s timeout (2048 cycles @ 1.024 kHz) */ + while (WDT->SYNCBUSY.reg) + ; + WDT->CONFIG.reg = WDT_CONFIG_PER_CYC2048; + while (WDT->SYNCBUSY.reg) + ; + WDT->CTRLA.reg = WDT_CTRLA_ENABLE; + while (WDT->SYNCBUSY.reg) + ; + printf("Watchdog enabled (2s timeout)\r\n"); + talloc_enable_null_tracking(); g_tall_ctx = talloc_named_const(NULL, 0, "global"); printf("g_tall_ctx=%p\r\n", g_tall_ctx); @@ -737,6 +748,9 @@ } feed_ccid(); osmo_timers_update(); + + /* Pet the watchdog */ + WDT->CLEAR.reg = WDT_CLEAR_CLEAR_KEY; int qs = llist_count_at(&g_ccid_s.free_q); if (qs > NUM_OUT_BUF) for (int i = 0; i < qs - NUM_OUT_BUF; i++) { -- To view, visit https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/42307?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ccid-firmware Gerrit-Branch: master Gerrit-Change-Id: I1ef1fc70d33492efe0171a7879c1a23f16957195 Gerrit-Change-Number: 42307 Gerrit-PatchSet: 1 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ccid-firmware[master]: ccid: properly emit wait time ext messages
by Hoernchen 10 Mar '26

10 Mar '26
Hoernchen has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/42306?usp=email ) Change subject: ccid: properly emit wait time ext messages ...................................................................... ccid: properly emit wait time ext messages The CCID message that tells the host that the card asked for a wait time extension was missing. This is a bit weird, because it breaks the 1:1 relationship between messages and responses that usually exists, nor does it consume a bSeq, so we just count and emit WT msgs as appropriate. Closes: OS#6458 Change-Id: Ib69483d453a0e5ebb1bc1885a8f78790a0f10d70 --- M ccid_common/ccid_device.h M ccid_common/ccid_slot_fsm.c M ccid_common/iso7816_fsm.c M ccid_common/iso7816_fsm.h 4 files changed, 46 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware refs/changes/06/42306/1 diff --git a/ccid_common/ccid_device.h b/ccid_common/ccid_device.h index 97d6212..ee2b5e2 100644 --- a/ccid_common/ccid_device.h +++ b/ccid_common/ccid_device.h @@ -78,6 +78,8 @@ const struct ccid_pars_decoded *default_pars; volatile uint32_t event; volatile void* event_data; + /* count of pending Wait Time Extension notifications to send to host */ + volatile uint32_t wtime_ext; }; /* CCID operations provided by USB transport layer */ diff --git a/ccid_common/ccid_slot_fsm.c b/ccid_common/ccid_slot_fsm.c index c34ad72..307c50f 100644 --- a/ccid_common/ccid_slot_fsm.c +++ b/ccid_common/ccid_slot_fsm.c @@ -102,6 +102,7 @@ card_uart_ctrl(ss->cuart, CUART_CTL_POWER_5V0, false); cs->icc_powered = false; cs->cmd_busy = false; + cs->wtime_ext = 0; } } @@ -175,6 +176,10 @@ case ISO7816_E_HW_ERR_IND: card_uart_ctrl(ss->cuart, CUART_CTL_NO_RXTX, true); break; + case ISO7816_E_WTIME_EXT_IND: + /* card sent NULL byte (0x60); notify host via intermediate TimeExtension response */ + cs->wtime_ext++; + break; case ISO7816_E_ATR_ERR_IND: case ISO7816_E_TPDU_FAILED_IND: case ISO7816_E_PPS_FAILED_IND: @@ -206,6 +211,27 @@ volatile uint32_t event = cs->event; volatile void * volatile data = cs->event_data; + /* send pending Wait Time Extension notifications to host. + * wtime_ext is incremented from ISR context (UART RX -> FSM -> user_cb), + * so we must atomically read-and-clear to avoid losing increments. */ + if (cs->wtime_ext) { + uint32_t wt_pending; +#ifdef OCTSIMFWBUILD + CRITICAL_SECTION_ENTER(); +#endif + wt_pending = cs->wtime_ext; + cs->wtime_ext = 0; +#ifdef OCTSIMFWBUILD + CRITICAL_SECTION_LEAVE(); +#endif + for (uint32_t i = 0; i < wt_pending; i++) { + LOGPCS(cs, LOGL_DEBUG, "Sending Wait Time Extension to host\n"); + resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_TIME_EXT, 1, NULL, 0); + /* this does neither consume the bSeq nor unbusy the slot! */ + ccid_slot_send(cs, resp); + } + } + if (!event) return 0; // if(event && !data) @@ -224,6 +250,7 @@ resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_FAILED, CCID_ERR_ICC_MUTE, 0, 0); ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; case ISO7816_E_ATR_DONE_IND: tpdu = data; @@ -239,6 +266,7 @@ resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_OK, 0, msgb_data(tpdu), msgb_length(tpdu)); ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; case ISO7816_E_ATR_ERR_IND: tpdu = data; @@ -252,6 +280,7 @@ resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_FAILED, CCID_ERR_ICC_MUTE, msgb_data(tpdu), msgb_length(tpdu)); ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; break; case ISO7816_E_TPDU_DONE_IND: @@ -261,6 +290,7 @@ resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_OK, 0, msgb_l4(tpdu), msgb_l4len(tpdu)); ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; case ISO7816_E_TPDU_FAILED_IND: tpdu = data; @@ -275,6 +305,7 @@ resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_FAILED, CCID_ERR_ICC_MUTE, msgb_l2(tpdu), 0); ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; case ISO7816_E_PPS_DONE_IND: tpdu = data; @@ -310,6 +341,7 @@ ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; case ISO7816_E_PPS_UNSUPPORTED_IND: /* unsupported means no response, failed means request/response mismatch @@ -331,6 +363,7 @@ ccid_slot_send_unbusy(cs, resp); cs->event = 0; + cs->wtime_ext = 0; break; case 0: break; diff --git a/ccid_common/iso7816_fsm.c b/ccid_common/iso7816_fsm.c index a035148..c59bc7d 100644 --- a/ccid_common/iso7816_fsm.c +++ b/ccid_common/iso7816_fsm.c @@ -228,6 +228,7 @@ { ISO7816_E_ATR_DONE_IND, "ATR_DONE_IND" }, { ISO7816_E_ATR_ERR_IND, "ATR_ERR_IND" }, { ISO7816_E_TPDU_DONE_IND, "TPDU_DONE_IND" }, + { ISO7816_E_WTIME_EXT_IND, "WTIME_EXT_IND" }, { ISO7816_E_XCEIVE_TPDU_CMD, "XCEIVE_TPDU_CMD" }, /* allstate events */ { ISO7816_E_WTIME_EXP, "WAIT_TIME_EXP" }, @@ -432,6 +433,10 @@ /* hand finished TPDU to user */ ip->user_cb(fi, event, 0, apdu); break; + case ISO7816_E_WTIME_EXT_IND: + /* notify user of wait time extension; TPDU still in progress! */ + ip->user_cb(fi, event, 0, NULL); + break; default: OSMO_ASSERT(0); } @@ -588,7 +593,8 @@ S(ISO7816_E_TX_COMPL) | S(ISO7816_E_RX_ERR_IND) | S(ISO7816_E_TX_ERR_IND) | - S(ISO7816_E_TPDU_DONE_IND), + S(ISO7816_E_TPDU_DONE_IND) | + S(ISO7816_E_WTIME_EXT_IND), .out_state_mask = S(ISO7816_S_RESET) | S(ISO7816_S_WAIT_TPDU) | S(ISO7816_S_IN_TPDU), @@ -1319,6 +1325,7 @@ LOGPFSML(fi, LOGL_DEBUG, "Received 0x%02x from UART\n", byte); if (byte == 0x60) { /* NULL: wait for another procedure byte */ + osmo_fsm_inst_dispatch(fi->proc.parent, ISO7816_E_WTIME_EXT_IND, NULL); card_uart_set_rx_threshold(ip->uart, 1); card_uart_ctrl(ip->uart, CUART_CTL_RX_TIMER_HINT, 1); osmo_fsm_inst_state_chg(fi, TPDU_S_PROCEDURE, 0, 0); @@ -1490,6 +1497,7 @@ LOGPFSML(fi, LOGL_DEBUG, "Received 0x%02x from UART\n", byte); if (byte == 0x60) { /* NULL: wait for actual SW1 */ + osmo_fsm_inst_dispatch(fi->proc.parent, ISO7816_E_WTIME_EXT_IND, NULL); card_uart_set_rx_threshold(ip->uart, 1); card_uart_ctrl(ip->uart, CUART_CTL_RX_TIMER_HINT, 1); osmo_fsm_inst_state_chg(fi, TPDU_S_SW1, 0, 0); diff --git a/ccid_common/iso7816_fsm.h b/ccid_common/iso7816_fsm.h index fb37396..542880a 100644 --- a/ccid_common/iso7816_fsm.h +++ b/ccid_common/iso7816_fsm.h @@ -47,6 +47,8 @@ /* TODO: Rx FIFO overrun */ /* TODO: Rx buffer overrun */ + ISO7816_E_WTIME_EXT_IND, /*!< Wait Time Extension (NULL byte 0x60) from card */ + /* internal events between FSMs in this file */ ISO7816_E_ATR_DONE_IND, /*!< ATR Done indication from ATR child FSM */ ISO7816_E_ATR_ERR_IND, /*!< ATR Error indication from ATR child FSM */ -- To view, visit https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/42306?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ccid-firmware Gerrit-Branch: master Gerrit-Change-Id: Ib69483d453a0e5ebb1bc1885a8f78790a0f10d70 Gerrit-Change-Number: 42306 Gerrit-PatchSet: 1 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de>
1 0
0 0
[M] Change in pysim[master]: pySim/transport: fix GET RESPONSE behaviour
by laforge 10 Mar '26

10 Mar '26
Attention is currently required from: dexter. laforge has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/42301?usp=email ) Change subject: pySim/transport: fix GET RESPONSE behaviour ...................................................................... Patch Set 4: Code-Review+1 (1 comment) Patchset: PS4: it would be good to introduce some testing of this new fixed handling e.g.by checking the number of remaining PIN attempts which was failing in the OS#6970. Said test could be introduced together with this patch so we can immediately see it now works? -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42301?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I26f0566af0cdd61dcc97f5f502479dc76adc37cc Gerrit-Change-Number: 42301 Gerrit-PatchSet: 4 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Mar 2026 12:26:21 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes
1 0
0 0
[M] Change in pysim[master]: pySim/transport: fix GET RESPONSE behaviour
by laforge 10 Mar '26

10 Mar '26
Attention is currently required from: dexter. laforge has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/42301?usp=email ) Change subject: pySim/transport: fix GET RESPONSE behaviour ...................................................................... Patch Set 4: (1 comment) Patchset: PS4: I would argue actual bugfixes have higher priority and should hence be at the start of a patch series, and not at the end where they're blocked by more cosmetic changes in front of them -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42301?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I26f0566af0cdd61dcc97f5f502479dc76adc37cc Gerrit-Change-Number: 42301 Gerrit-PatchSet: 4 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Mar 2026 12:24:05 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No
1 0
0 0
[S] Change in pysim[master]: pySim-prog/pySim-read: add pySimLogger and verbose cmdline argument
by laforge 10 Mar '26

10 Mar '26
Attention is currently required from: dexter. laforge has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/42305?usp=email ) Change subject: pySim-prog/pySim-read: add pySimLogger and verbose cmdline argument ...................................................................... Patch Set 1: (1 comment) File pySim-read.py: https://gerrit.osmocom.org/c/pysim/+/42305/comment/701fab1c_99ad18f2?usp=em… : PS1, Line 84: # Setup logger : PySimLogger.setup(print, {logging.WARN: "\033[33m"}) : if (opts.verbose): : PySimLogger.set_verbose(True) : PySimLogger.set_level(logging.DEBUG) : else: : PySimLogger.set_verbose(False) : PySimLogger.set_level(logging.INFO) it looks like this should go in some generic helper function that we call from all the programs, simply passing a "verbose:bool = False" argument into the function? -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42305?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: Ia2fa535fd9ce4ffa301c3f5d6f98c1f7a4716c74 Gerrit-Change-Number: 42305 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Mar 2026 12:23:22 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No
1 0
0 0
[XS] Change in pysim[master]: contrib/csv-to_pgsl: explicitly set log level to INFO in non verbose ...
by laforge 10 Mar '26

10 Mar '26
Attention is currently required from: dexter. laforge has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/42304?usp=email ) Change subject: contrib/csv-to_pgsl: explicitly set log level to INFO in non verbose mode ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42304?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I4b8ef1e203186878910c9614a1d900d5759236a8 Gerrit-Change-Number: 42304 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Mar 2026 12:22:04 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[M] Change in osmo-trx[master]: build: install common/GSM/transceiver libraries for emscripten and ad...
by Timur Davydov 10 Mar '26

10 Mar '26
Attention is currently required from: Hoernchen, fixeria, laforge, osmith, pespin. Timur Davydov has posted comments on this change by Timur Davydov. ( https://gerrit.osmocom.org/c/osmo-trx/+/42243?usp=email ) Change subject: build: install common/GSM/transceiver libraries for emscripten and add pkg-config files ...................................................................... Patch Set 4: (1 comment) File configure.ac: https://gerrit.osmocom.org/c/osmo-trx/+/42243/comment/63a71d84_2e62190b?usp… : PS3, Line 307: PKG_CHECK_MODULES(FFTWF, fftw3f) > How is for instance […] It isn't — and it doesn't need to be. `Channelizer`/`Synthesis` are compiled into object files inside the static library `libtransceiver_common.a`, but no code in the Emscripten binary actually references them. They are only ever instantiated by `RadioInterfaceMulti` (in `radioInterfaceMulti.cpp`), which is not part of the Emscripten link target. With static libraries, the linker only pulls in object files that resolve symbols actually referenced by the binary. Since nothing calls `Channelizer`/`Synthesis`, their objects are never pulled from the archive, and the unresolved `cxvec_fft()` symbol is never encountered. It simply stays unused inside the .a file. Btw, I'm currently reworking this commit. My plan is to introduce a separate `web` target in `devices` that will produce a static library `osmo-trx-web.a` containing everything needed to build `osmo-bts` with Emscripten. It will only be built when the `--with-web` configure flag is enabled. -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/42243?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: I2495c5b5c79f2fe74bef83902058e1d2207c1f3c Gerrit-Change-Number: 42243 Gerrit-PatchSet: 4 Gerrit-Owner: Timur Davydov <dtv.comp(a)gmail.com> Gerrit-Reviewer: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-CC: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Attention: Hoernchen <ewild(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Mar 2026 12:02:14 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: pespin <pespin(a)sysmocom.de> Comment-In-Reply-To: Timur Davydov <dtv.comp(a)gmail.com>
1 0
0 0
[XS] Change in pysim[master]: contrib/csv-to_pgsl: explicitly set log level to INFO in non verbose ...
by dexter 10 Mar '26

10 Mar '26
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/42304?usp=email ) Change subject: contrib/csv-to_pgsl: explicitly set log level to INFO in non verbose mode ...................................................................... contrib/csv-to_pgsl: explicitly set log level to INFO in non verbose mode The current log level for PySimLogger currently is DEBUG. (The default for verbose is False). Since those defaults may change over time, we should conciously set what we want in verbose and non verbose mode, like we already do in pySim-shell. Change-Id: I4b8ef1e203186878910c9614a1d900d5759236a8 --- M contrib/csv-to-pgsql.py 1 file changed, 3 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/04/42304/1 diff --git a/contrib/csv-to-pgsql.py b/contrib/csv-to-pgsql.py index 416d870..c3c480f 100755 --- a/contrib/csv-to-pgsql.py +++ b/contrib/csv-to-pgsql.py @@ -289,6 +289,9 @@ if (opts.verbose): PySimLogger.set_verbose(True) PySimLogger.set_level(logging.DEBUG) + else + PySimLogger.set_verbose(False) + PySimLogger.set_level(logging.INFO) # Open CSV file cr = open_csv(opts) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42304?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I4b8ef1e203186878910c9614a1d900d5759236a8 Gerrit-Change-Number: 42304 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
1 0
0 0
[S] Change in pysim[master]: pySim-prog/pySim-read: add pySimLogger and verbose cmdline argument
by dexter 10 Mar '26

10 Mar '26
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/42305?usp=email ) Change subject: pySim-prog/pySim-read: add pySimLogger and verbose cmdline argument ...................................................................... pySim-prog/pySim-read: add pySimLogger and verbose cmdline argument pySim-prog and pySim-read do not integrate the pySimLogger yet. As we may add more debug output that should not be visible on normal use, we should ensure that the pySimLogger is correctly set up. Change-Id: Ia2fa535fd9ce4ffa301c3f5d6f98c1f7a4716c74 --- M pySim-prog.py M pySim-read.py 2 files changed, 31 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/05/42305/1 diff --git a/pySim-prog.py b/pySim-prog.py index 760a650..4467ec7 100755 --- a/pySim-prog.py +++ b/pySim-prog.py @@ -44,6 +44,11 @@ from pySim.card_handler import * from pySim.utils import * +from pathlib import Path +import logging +from pySim.log import PySimLogger + +log = PySimLogger.get(Path(__file__).stem) def parse_options(): @@ -185,6 +190,7 @@ default=False, action="store_true") parser.add_argument("--card_handler", dest="card_handler_config", metavar="FILE", help="Use automatic card handling machine") + parser.add_argument("--verbose", help="Enable verbose logging", action='store_true', default=False) options = parser.parse_args() @@ -770,6 +776,15 @@ # Parse options opts = parse_options() + # Setup logger + PySimLogger.setup(print, {logging.WARN: "\033[33m"}) + if (opts.verbose): + PySimLogger.set_verbose(True) + PySimLogger.set_level(logging.DEBUG) + else: + PySimLogger.set_verbose(False) + PySimLogger.set_level(logging.INFO) + # Init card reader driver sl = init_reader(opts) diff --git a/pySim-read.py b/pySim-read.py index 481e9da..da3652d 100755 --- a/pySim-read.py +++ b/pySim-read.py @@ -46,11 +46,17 @@ from pySim.legacy.utils import format_xplmn_w_act, dec_st, dec_msisdn from pySim.ts_51_011 import EF_SMSP +from pathlib import Path +import logging +from pySim.log import PySimLogger + +log = PySimLogger.get(Path(__file__).stem) + option_parser = argparse.ArgumentParser(description='Legacy tool for reading some parts of a SIM card', formatter_class=argparse.ArgumentDefaultsHelpFormatter) +option_parser.add_argument("--verbose", help="Enable verbose logging", action='store_true', default=False) argparse_add_reader_args(option_parser) - def select_app(adf: str, card: SimCard): """Select application by its AID""" sw = 0 @@ -75,6 +81,15 @@ # Parse options opts = option_parser.parse_args() + # Setup logger + PySimLogger.setup(print, {logging.WARN: "\033[33m"}) + if (opts.verbose): + PySimLogger.set_verbose(True) + PySimLogger.set_level(logging.DEBUG) + else: + PySimLogger.set_verbose(False) + PySimLogger.set_level(logging.INFO) + # Init card reader driver sl = init_reader(opts) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42305?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: Ia2fa535fd9ce4ffa301c3f5d6f98c1f7a4716c74 Gerrit-Change-Number: 42305 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 151
  • 152
  • 153
  • 154
  • 155
  • 156
  • 157
  • ...
  • 194
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.