Page 1 of 1

LUA scripts not seen by openTx

Posted: Mon Sep 11, 2023 9:23 pm
by Raythegreat
Hi all,

I'm experimenting with LUA scripts and have a few problems/questions.

In my SCRIPTS/TELEMETRY directory I have 3 scripts files: snake.lua, test2.lua and switch_test.lua
The script switch_test.lua is not seen by the openTX Taranis+ system. I have the latest firmware version and lua is enabled.

The snake and test2 scripts work fine when the are chosen in the telemetry display screen, but the switch_test is not in the list of choices so I can never choose it.
I minimized the code (put in comments with -- ) as much as possible to find out why it's not seen but never really found it.

File switch_test.lua is attached. It's almost empty.
switch_test.lua
(548 Bytes) Downloaded 83 times
Can anyone help me understand why some files are seen and others not?

Thanks,
Ray

Re: LUA scripts not seen by openTx

Posted: Mon Sep 11, 2023 11:21 pm
by Raythegreat
OK I found the problem.

The script filename needs to be 6 or less characters. I forgot that detail.

Ray