Change in simtrace2[master]: sniffer: set LED pattern

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/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Wed Jul 11 20:25:04 UTC 2018


Harald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/9924 )

Change subject: sniffer: set LED pattern
......................................................................

sniffer: set LED pattern

The red and green LEDs are now used as follows:
- red on = power (firmware is running)
- red blink = error detected (e.g. during ISO-7816 parsing)
- green on = running (sniffer mode is running)
- green blink = activity (e.g. USB message sent)

Change-Id: Ib1b6ff87fb92d6ed3ecae4bc89386206aaab508e
---
M firmware/apps/trace/main.c
M firmware/libcommon/source/sniffer.c
2 files changed, 8 insertions(+), 3 deletions(-)

Approvals:
  Jenkins Builder: Verified
  Harald Welte: Looks good to me, approved



diff --git a/firmware/apps/trace/main.c b/firmware/apps/trace/main.c
index 6b6d70b..f7eb15d 100644
--- a/firmware/apps/trace/main.c
+++ b/firmware/apps/trace/main.c
@@ -142,10 +142,15 @@
 	enum confNum last_simtrace_config = simtrace_config;
 	unsigned int i = 0;
 
-	/* Configure LED output (red = on, green = activity */
+	/* Configure LED output
+	 * red on = power
+	 * red blink = error
+	 * green on = running
+	 * green blink = activity
+	 */
 	led_init();
 	led_blink(LED_RED, BLINK_ALWAYS_ON);
-	led_blink(LED_GREEN, BLINK_ALWAYS_OFF);
+	led_blink(LED_GREEN, BLINK_ALWAYS_ON);
 
 	/* Enable watchdog for 2000 ms, with no window */
 	WDT_Enable(WDT, WDT_MR_WDRSTEN | WDT_MR_WDDBGHLT | WDT_MR_WDIDLEHLT |
diff --git a/firmware/libcommon/source/sniffer.c b/firmware/libcommon/source/sniffer.c
index 8262bec..9202d8e 100644
--- a/firmware/libcommon/source/sniffer.c
+++ b/firmware/libcommon/source/sniffer.c
@@ -302,7 +302,7 @@
 	}
 
 	/* Show activity on LED */
-	led_blink(LED_GREEN, BLINK_2O_F);
+	led_blink(LED_GREEN, BLINK_2F_O);
 
 	/* Print message */
 	switch (type) {

-- 
To view, visit https://gerrit.osmocom.org/9924
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: simtrace2
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib1b6ff87fb92d6ed3ecae4bc89386206aaab508e
Gerrit-Change-Number: 9924
Gerrit-PatchSet: 6
Gerrit-Owner: Kévin Redon <kredon at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20180711/39b18fdb/attachment.htm>


More information about the gerrit-log mailing list