Skip to content

EdgeTX/OpenTX Battery and Telemetry Monitoring LUA Widget

License

Notifications You must be signed in to change notification settings

derelict/TxBatTele

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub release (latest by date) GitHub Downloads (all assets, all releases) GitHub repo size GitHub language count GitHub top language GitHub last commit Hits Discord GitHub stars GitHub forks GitHub watchers

TxBatTele 🔋

EdgeTX/OpenTX Battery and Telemetry Monitoring LUA Widget which tries to rely as less as possible on radio settings (Everything is defined in the Script). So no need for "manual" Logical Switches or Custom Functions.

It's supposed to be "A jack of all trades" kind of thing (at least for most "standard" needs) but with a main focus on Battery Monitoring.

You can also reach out to me on the EdgeTX LUA Discord Channel (see above)

Key Features of TxBatTele ⭐

  • Receiver and/or Main Battery Monitoring: Monitor your Main and/or Receiver Battery. Support for different Battery Types (lipo and buffer currently, can be extended for additional battery types easily)
  • Current Sensor: Monitor Current Consumption if a Sensor is available
  • Other Sensors: Monitor and show other Sensors and change their color based on >, < and = condition
  • Switch State Announcements: Voice Announcements for any Switch Position (like Armed, Disarmed, Flightmode, and so on)
  • Status Pages: Show pre, post and in flight Statuspage (widget)
  • Pre-Flight Checks: Check for missing/inconsistent Cells, Battery not full conditions before flight
  • Model Statistics: Show Total Flight Count, Total Flight Time and previous/last Flight Time
  • Voice Announcements: Get periodic or on changes Voice Announcements for any Condition (highly customizable)
  • Haptic Feedback: Get Haptic Feedback on Alerts (on critical and warning Events)
  • Logging: Take a Screenshot of the Statuspage after flight or turn on logging if/as needed based on Conditions (like Battery at 30%) ( not yet possible ... but maybe >= EdgeTX 2.11 ... see pending Feature Request: EdgeTX/edgetx#5191 and pending pull request: EdgeTX/edgetx#5181 ) for a Workaround see below

Video 📺

Note

  • This is currently in alpha/"works for me" state ... use/try at your own Risk
  • Based on mahRe2. So full Credits to them!
  • This is my first attempt in LUA Scripting. So please be gentle ;-)
  • If you need/want custom voice announcements (for instance modelname) submit a feature request or patch the CSV .. i will try to generate new voices as soon as i have time to. Same applies for new Languages and/or voices (although that would require more work on my side and may take a little longer to implement ;-) )
  • Important: We are dealing (actually relying on) with Voltages and "real" discharge Curves. So make sure your Sensors are reporting the correct Values (Check with a Voltagemeter) and adjust the Sensor Offset accordingly until it reports the real measured Value !

How to contribute

  • Design the LCD Widget for various sizes ( i'm not very good at designing / see Screenshots ;-) )

How To's

NO MAH Sensor

If you don't have a native mah Sensor but you do have a Current Sensor, you can add a custom Sensor like so:

image

and use it here:

image

How to make automatic screenshots working

There is a pending Pull request open, to directly implement this in LUA. But for the time being you'll have to make some small Radio Settings in order to use this Feature:

Create a Logical Switch like so:

image

and then a Special Function for the actual screenshot taking:

image

Make sure to reference the correct logical switch. Then in the LUA Model Definition:

image

and again ... make sure to reference the correct logical switch by its index number. 0=L01, 1=L02 and so on.

How to make automatic logging working

There is a pending Feature request open, to directly implement this in LUA. But for the time being you'll have to make some small Radio Settings in order to use this Feature:

Create a Logical Switch like so:

image

and then a Special Function for the actual logging:

image

Make sure to reference the correct logical switch. Then in the LUA Model Definition:

image

and again ... make sure to reference the correct logical switch by its index number. 0=L01, 1=L02 and so on.

How to make telemetry reset working

If you like to reset all the Sensors after flight/changing the Battery, you'll have to make some small radio setttings in order to make this work:

Create a Logical Switch like so:

image

and then a Special Function for the reset Telemetry:

image

Make sure to reference the correct logical switch. Then in the LUA Model Definition:

image

and again ... make sure to reference the correct logical switch by its index number. 0=L01, 1=L02 and so on.