yaapu / HorusMappingWidget

Offline GPS Mapping Widget for Horus and T16 radios
GNU General Public License v3.0
91 stars 26 forks source link

Maps config tool fields not visible in EdgeTX 2.6 #42

Closed ulfhedlund closed 1 year ago

ulfhedlund commented 2 years ago

I had the mapping widget working in ETX 2.5 but have run into some problems with the configuration tool in ETX 2.6 RC2. All field info/headers are non-readable/completely black in the config menu. The only thing I can see is the active field value, which is shown in white text on black background. Environment: ETX 2.6.0 RC2, TX16S radio.

yaapu commented 2 years ago

another EdgeTX lua "feature" :-)

ulfhedlund commented 2 years ago

It seems to also effect the map widget itself and your other excellent FrSky Telemetry Script and Widget, unfortunately.

yaapu commented 2 years ago

can you provide a screen shot, I tested under the simulator and works

ulfhedlund commented 2 years ago

Absolutely, I'll provide them to you this weekend.

ulfhedlund commented 2 years ago

tests.zip Here are some screenshots from my TX16S, running ETX 2.6 RC3, the FrSky Telemetry Script 1.9.5 and the Horus Mapping widget v1.2.2 (I believe). It seems all the telemetry/text fields along the edge of the widgets are black on black or something like that. Please let me know if you need more or other info. Thanks!

yaapu commented 2 years ago

ok, check my wiki, you need version 1.9.6 of the Telemetry Widget and version 1.3 of the mapping widget for EdgeTX support, use the dev branch for version 1.9.6

ulfhedlund commented 2 years ago

Thank you! Everything now works as expected on the radio, both the Telemetry Widget, Mapping Widget and config scripts. However the mapping widget throws an error in the model simulator in Companion. "ERROR in create(): /SCRIPTS/YAAPU/mapsconfig.luac: incompatible precompiled chunk".

An observation: the background colors of the telemetry values in the widgets are different for those on the side (blue in my case) and those at the bottom (black in my case). It is cosmetics only so no big deal, and perhaps it is intentional.

I have attached a few screenshots from companion and radio, showing this. tests.zip

Ziege-One commented 2 years ago

I have the same problem. the issue is that the mapsconfig.lua will be not compiled at start up. I have added a compiled in Main.lua

` local function init()

-- load configuration at boot and only refresh if GV(8,8) = 1 assert(loadScript(basePath.."mapsconfig.lua","c")) --new collectgarbage() --new collectgarbage() --new loadConfig() utils.initColors() -- zoom initialize`

yaapu commented 2 years ago

that should not be required, simply remove the .luac file and the lua will be compiled on the fly

Ziege-One commented 2 years ago

I have edgeTX 2.6 it will not compile. A feature for edgeTX ? 😁

yaapu commented 2 years ago

did you delete the mapsconfig.luac file?

Ziege-One commented 2 years ago

yes then restart with the original Main.lua mapsconfig.luac not compiled screenshot_tx16s_22-02-02_22-47-02 .

yaapu commented 2 years ago

ok now I see what you mean, you can also manually launch mapsconfig.lua from SYS->[browse the sd], it will compile it once and for all

Ziege-One commented 2 years ago

Yes that works 👍

yaapu commented 2 years ago

but it's an ugly workaround, the "feature" is that luac compiled for OpenTX 2.3 does not run on edgetx

Ziege-One commented 2 years ago

Another Question, I have made a Fullscreen Map option. Should I make a Pull requests, or should I stay a separate project?

screenshot_tx16s_22-02-02_21-22-58

yaapu commented 2 years ago

mhmm that won't work on opentx, it would be killed for cpu limit, probably on edgetx too, you're really close to max cpu

yaapu commented 2 years ago

the proper way would be to add a second layout, user selectable from the config menu and in that layout go full screen, so users would be free to choose and if the radio kills the script would not be my fault :-)

Ziege-One commented 2 years ago

Where can I see the CPU limit? I will test it

yaapu commented 2 years ago

you can't :-) the radio will kill the script without notice, I do simulated multi hours mission to detect such cases

yaapu commented 2 years ago

you can try to decreae the number of trailing dots if it gets killed, they are quite cpu heavy

julianschweizer commented 2 years ago

ok now I see what you mean, you can also manually launch mapsconfig.lua from SYS->[browse the sd], it will compile it once and for all

Doesnt work here on latest EdgeTX and TX16S

Ziege-One commented 2 years ago

ok now I see what you mean, you can also manually launch mapsconfig.lua from SYS->[browse the sd], it will compile it once and for all

Doesnt work here on latest EdgeTX and TX16Sj

Hello Julian, do not install the last releases, you have to use the source code here https://github.com/yaapu/HorusMappingWidget/archive/refs/heads/master.zip. Before install, delete all older yaapu files. After install go to SYS->[browse the sd], and delete mapsconfig.luac and then open mapsconfig.lua, now you must see the config menu. Close it and restart the TX16S now it will work