betaflight-tx-lua-scripts icon indicating copy to clipboard operation
betaflight-tx-lua-scripts copied to clipboard

OTX 2.2.0-RC11 / BF 3.1.6 PIDs not shown, just "---"

Open RipperDrone opened this issue 9 years ago • 15 comments

Had an older script BFSetp.lua running on BF 3.1 ok, showed & saved values correctly.

Now updated to BF 3.1.6, latest release of lua scripts, installed BF and TELEMETRY directories under SCRIPTS subdir of my Taranis X9D+. Executed script, mapped it onto screen 2 of telemetry pages.

PID page shows up, but no values, only "---"

I have latest RC11 OTX 2.2 firmware on my Taranis, used to have RC10 on before.

Any thoughts?

RipperDrone avatar Mar 05 '17 16:03 RipperDrone

I have the same Problem. But it is definitely a problem with OTX RC11. When I change back to RC10 it is working.

FPWibi avatar Mar 05 '17 17:03 FPWibi

I see, so we need to wait for another patch or stay with RC10... :-(

RipperDrone avatar Mar 05 '17 17:03 RipperDrone

I don't really know anything about it, but there have been the following changes with the RC11 release with LUA scripts:

LUA : all numbers are now handled as float instead of double as previously (speed and memory footprint improved) LUA : system enhancement have been made to improve stability of scripts

The code of the LUA script maybe has to be changed. I can still change the settings of my IRC Tramp with the same script.

FPWibi avatar Mar 05 '17 17:03 FPWibi

I have tried to find a response on OpenTX github, but they replied that the author of the script should check where the error comes from, because they do not seem to be deeply involved in these specific scripts at OpenTX.

Looks like the BF side might have to analyze it further if we want to get it resolved...

RipperDrone avatar Mar 05 '17 18:03 RipperDrone

If anybody need the RC10 for X7 or X9d+ https://www.dropbox.com/sh/9dc2pu3u0uz66gk/AAClI98k9YrZnlZ88M9x6Ajaa?dl=0

Greez FlowBow

FlowBowFPV avatar Mar 05 '17 21:03 FlowBowFPV

Got these hints from OpenTX GitHub:

From the script it is not evident which dataId is used when sending the MSP frames. Somebody should check in betaflight source. The valid range now is:

#define DIY_STREAM_FIRST_ID 0x5000 #define DIY_STREAM_LAST_ID 0x50ff See https://github.com/opentx/opentx/commit/d594843de29b16eb7ab7cbf039d0307206b54d0c

Check out details here, maybe it helps: https://github.com/opentx/opentx/issues/4560

RipperDrone avatar Mar 05 '17 22:03 RipperDrone

not sure about the details, but I tried to find the snippet where dataID for temeletry push packets is defined in lua script:

... local function mspSendSport(payload) local dataId = 0 dataId = payload[1] + bit32.lshift(payload[2],8) ...

Hope it helps a little - @raphaelcoeffic: Will these values be btw 0x5000 and 0x50ff at all times?

RipperDrone avatar Mar 05 '17 23:03 RipperDrone

I think @lshems makes a good point in opentx/opentx#4560 about integer constants getting messed up by conversion to float. The calculations might have to be rechecked to make sure they are not affected by rounding.

mikeller avatar Mar 05 '17 23:03 mikeller

@RipperDrone look at my comment on the same opentx issue: we do not use the dataID at all ;-) Instead, we use a back door on the packet type, thus letting us use the dataID as part of the payload. I've checked the code and this part has not changed. So I tend to believe the issue is related to the number format that has changed (double -> float), thus messing up the binary compatibility for integrers passed.

raphaelcoeffic avatar Mar 06 '17 08:03 raphaelcoeffic

How can I get RC10 firmware? When I try to download from within Companion RC10, it keeps downloading RC11... I'm using an original (non-plus) version of the Taranis.

barthalamu avatar Mar 10 '17 17:03 barthalamu

same problem, at least found a zip file with the "bin" here: http://blog.seidel-philipp.de/frsky-taranis-q-x7-firmware-flashen-eu-lbtnon-eustock/

teramax avatar Mar 10 '17 19:03 teramax

Guys I had same issue was a model memory issue remove the model and re create it should resolve the issue Mark

Sent from my iPhone

On 10 Mar 2017, at 20:09, teramax [email protected] wrote:

same problem, at least found a zip file with the "bin" here: http://blog.seidel-philipp.de/frsky-taranis-q-x7-firmware-flashen-eu-lbtnon-eustock/

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.

voipmonkey avatar Mar 10 '17 20:03 voipmonkey

RC12 is out guys should fix this issue http://www.open-tx.org/2017/03/13/opentx-2.2.0RC12

Changes since 2.2.0 RC11

X7/X9/X12 : minor change to english “minimum trim” sound #4584 X7/X9/X12 : minor change to german “miliamp per hour” sound #4595 X9/X12 : removed mixermon option (it is now always present) X9E : fix horussticks compilation option #4565 X7 : fix issue for external receiver flashing when multimodule was declared #4478 X7 : fix inconsistency in logical switches #4568 X7 : fix LUA drawline #4567 X7 : fix telemetry ‘bar’ screen #4576 X7 : add pots to preflight check and tune switch settings #4575 ARM : fix slow response when used as joystick #4479 LUA : revert “double” change #4560 SIMU : improve middle mouse button handling #4585 macosx : fix icons missing on Simulator

Luna-Moon21 avatar Mar 13 '17 21:03 Luna-Moon21

OTX 2.2.0-RC12 / Script Syntax Error. Screen shows as below.

Script syntax error attempt to call a nil value

Matthias7Song avatar Mar 15 '17 12:03 Matthias7Song

Hello, I had the same problem with my SPRACINGF3EVO. The old software was beautiful, without problems (3.2.4 Jan 10 2018). When I updated to the latest version of Beta flight, the LUA script worked but did not show the value. After returning to 3.2.4 LUA started working. I compared dump with both software, but I found only 2 differences and I think that they have no effect. Following the logic, just something is changed in the BF software and that was a problem in my case. I hope that my observations will be useful:] greetings

woojak avatar Jan 13 '19 21:01 woojak