aboutsummaryrefslogtreecommitdiffstats
path: root/mode-button.rsc
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2024-03-08 17:32:12 +0100
committerGravatar Christian Hesse <mail@eworm.de>2024-03-12 20:37:57 +0100
commitba2df80f073caf6b426def177b217d1b37954d7f (patch)
tree5dadd74e56ded840e62e82127a9315c8769bfd83 /mode-button.rsc
parent19802c0b6977f9467fada4ace3cab017dd98964b (diff)
parent242ecef012f5208b6fa088a1222d0d5477e5b2ed (diff)
Merge branch 'LogPrint' into next
Diffstat (limited to 'mode-button.rsc')
-rw-r--r--mode-button.rsc14
1 files changed, 7 insertions, 7 deletions
diff --git a/mode-button.rsc b/mode-button.rsc
index 07788cb..f453f11 100644
--- a/mode-button.rsc
+++ b/mode-button.rsc
@@ -16,18 +16,18 @@
:global ModeButton;
- :global LogPrintExit2;
+ :global LogPrint;
:set ($ModeButton->"count") ($ModeButton->"count" + 1);
:local Scheduler [ /system/scheduler/find where name="_ModeButtonScheduler" ];
:if ([ :len $Scheduler ] = 0) do={
- $LogPrintExit2 info $ScriptName ("Creating scheduler _ModeButtonScheduler, counting presses...") false;
+ $LogPrint info $ScriptName ("Creating scheduler _ModeButtonScheduler, counting presses...");
:global ModeButtonScheduler do={
:global ModeButton;
- :global LogPrintExit2;
+ :global LogPrint;
:global ModeButtonScheduler;
:global ValidateSyntax;
@@ -52,7 +52,7 @@
:if ([ :len $Code ] > 0) do={
:if ([ $ValidateSyntax $Code ] = true) do={
- $LogPrintExit2 info $ScriptName ("Acting on " . $Count . " mode-button presses: " . $Code) false;
+ $LogPrint info $ScriptName ("Acting on " . $Count . " mode-button presses: " . $Code);
:for I from=1 to=$Count do={
$LEDInvert;
@@ -66,16 +66,16 @@
[ :parse $Code ];
} else={
- $LogPrintExit2 warning $ScriptName ("The code for " . $Count . " mode-button presses failed syntax validation!") false;
+ $LogPrint warning $ScriptName ("The code for " . $Count . " mode-button presses failed syntax validation!");
}
} else={
- $LogPrintExit2 info $ScriptName ("No action defined for " . $Count . " mode-button presses.") false;
+ $LogPrint info $ScriptName ("No action defined for " . $Count . " mode-button presses.");
}
}
/system/scheduler/add name="_ModeButtonScheduler" \
on-event=":global ModeButtonScheduler; \$ModeButtonScheduler;" interval=3s;
} else={
- $LogPrintExit2 debug $ScriptName ("Updating scheduler _ModeButtonScheduler...") false;
+ $LogPrint debug $ScriptName ("Updating scheduler _ModeButtonScheduler...");
/system/scheduler/set $Scheduler start-time=[ /system/clock/get time ];
}
} on-error={ }