Closed mhantsch closed 11 months ago
Indeed! Thanks for report!
I just experienced this as well moving from firmware 10.1.0 to 10.3.0. My custom startup macro stopped working. I'm guessing that in my case it's because +
. -
, *
, & /
are now mathematical operators, but i guess there's more to it. Glad to see a fix in the pipeline for the next firmware release!
setLedTxt 150
setLedTxt 150 !!-
setLedTxt 150 !--
setLedTxt 150 ---
setLedTxt 150 --
setLedTxt 150 -
setLedTxt 150 /
setLedTxt 150 |
setLedTxt 150 \
setLedTxt 150 -
setLedTxt 150 O
setLedTxt 150 O-
setLedTxt 150 O/
setLedTxt 150 O|
setLedTxt 150 O\
setLedTxt 150 O-
setLedTxt 150 O/
setLedTxt 150 OM
setLedTxt 150 OM-
setLedTxt 150 OM/
setLedTxt 150 OM|
setLedTxt 150 OM\
setLedTxt 150 OM-
setLedTxt 150 OM/
setLedTxt 1000 OMG
I'm guessing that in my case it's because
+
.-
,*
, &/
are now mathematical operators, but i guess there's more to it.
Yes, there are two unrelated things at play here:
You will need to put the string in quotes. Either double-quotes ("
) or single-quotes ('
) will work. Double-quotes will give you string interpolation, but with your strings it won't make a difference whether you use single or double.
A bug in 10.3.0 makes any setLedTxt
command produce an ERR
.
Personally, I have reverted to firmware 10.2.0 for now until the bug is fixed. The new Agent at least shows me error and warning messages directly in Agent, and 10.2.0 already contains a lot of useful improvements.
Btw, it seems we all like to play with the segment display 😄
I have a lot of macros similar to this:
setLedTxt 800 "[-]"
setLedTxt 200 "[\]"
setLedTxt 200 "[|]"
setLedTxt 200 "[/]"
setLedTxt 200 "[-]"
setLedTxt 200 "[\]"
setLedTxt 200 "[|]"
setLedTxt 200 "[/]"
setLedTxt 200 "[-]"
setLedTxt 200 "[*]"
setLedTxt 200 "|_|"
Reopening then, as this still seems to be a bug.
I believe all is fixed on master, just not released. Could you maybe release a patch firmware?
On master, I get:
Error at $onInit 1/1/14: Text argument expected.
> 1 | setLedTxt 150
> | ^
Error at $onInit 1/4/18: Could not parse
> 4 | setLedTxt 150 ---
> | ^
Error at $onInit 1/4/1: Unexpected variable type: 3
> 4 | setLedTxt 150 ---
Error at $onInit 1/5/17: Could not parse
> 5 | setLedTxt 150 --
> | ^
Error at $onInit 1/5/1: Unexpected variable type: 3
> 5 | setLedTxt 150 --
Error at $onInit 1/6/16: Could not parse
> 6 | setLedTxt 150 -
> | ^
Error at $onInit 1/6/1: Unexpected variable type: 3
> 6 | setLedTxt 150 -
Error at $onInit 1/11/16: Could not parse
> 11 | setLedTxt 150 -
> | ^
Error at $onInit 1/11/1: Unexpected variable type: 3
> 11 | setLedTxt 150 -
Yes, because this is an incomplete numeric expression. Neither a string, nor a number.
I agree that the error could be improved, but that's pretty much it...
Just released the new 10.3.1 firmware version. setLedTxt
works well with quoted arguments, indeed.
These animations are quite amusing; I think I'll feature them in a future blog post.
@mondalaci Thank yo so much! I'll test when i get home on saturday. Also, the source of my macro script is this repo where i originally found it and modified it to "OMG", haha https://github.com/hxv/uhk-macros/blob/master/lcd.md
Agent 3.1.0 Firmware 10.3.0
Seems like the setLedTxt command is now broken (since fw 10.3.0). Neither single nor double quotes allow me to set the text.