Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3.5.0 Lua Script Updates #416

Merged
merged 4 commits into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,7 @@ SkyZone
Skystars
Slickshot
SmartPort
SmartAudio
Spektrum
SteadyView
Stefanski
Expand Down
34 changes: 33 additions & 1 deletion docs/quick-start/transmitters/lua-howto.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,14 @@ Available Options:

* Alternate between the two Antennas.

### Link Mode

Introduced in 3.5.0, `Link Mode` changes the main protocol and function of the TX module.

* `Normal` - This is the default configuration. The TX module simply sends the commands from the radio handset, and receive telemetry from the receiver and send it to the handset.

* `MAVLink` - This option enables native MAVLink Telemetry downlink and Radio Control uplink making the TX module and radio handset to be an intermediary between a GCS and a MAVLink-capable craft. See the [MAVLink](../../software/mavlink.md) page for more details.

### Model Match

ExpressLRS supports multiple configuration profiles, and the configuration profile is selected by setting the "Receiver ID" property in the Radio Handset's Model Setup -> Internal/External RF -> Receiver (number).
Expand Down Expand Up @@ -352,9 +360,29 @@ The `Protocol` setting controls the output of the connected receiver. The follow
* `SUMD` - Lets the receiver output Graupner HoTT SUMD signal for use with devices that don't support CRSF protocol, like Stabilizers, Heli Controllers etc.
* `DJI RS2 Pro` - Mainly used for the RS2 Pro Gimbals
* `HoTT Telemetry` - Allows to use Graupner HoTT enabled telemetry sensors (Graupner and 3rd party)
* `MAVLINK` - Introduced on ExpressLRS 3.5.0, it allows the receiver to output native MAVLink into a flight controller. See the [MAVLink](../../software/mavlink.md) page for more details.

For more information, see [Receiver Serial Protocols](../../software/serial-protocols.md)

### Protocol 2

The `Protocol 2` setting is only available for ESP32-based receivers. This include the True Diversity ones like the RP4TD, Super D, Super P and EP Dual. These receivers have a second UART that can be used for the same purpose as the main UART. Note that not all of the ESP32-based receivers have the extra UART pads or pins exposed for easy use.

It has the same options as the setting above with these additional ones:

* `Tramp` - If you want to control a VTX using Tramp protocol directly through the ExpressLRS Lua Script's VTX Admin.
* `SmartAudio` - If you want to control a VTX using SmartAudio protocol directly through the ExpressLRS Lua Script's VTX Admin.
* `Off` - Set when the auxiliary UART is not in use.

This setting is available on ExpressLRS 3.5.0 and onwards. See [PR 2605](https://github.com/ExpressLRS/ExpressLRS/pull/2605) for more details.

### SBUS failsafe

`SBUS Failsafe` is used to set the behavior of a receiver using SBUS protocol for output. The following options are available:

* `No Pulses` - When a failsafe occurs, the receiver will stop sending any messages.
* `Last Pos` - When a failsafe occurs, the receiver will keep sending the last channel positions it received.

### Antenna Mode

The `Antenna Mode` setting is only available for Receivers with Antenna Diversity. These options are available:
Expand Down Expand Up @@ -390,7 +418,7 @@ Team Racing allows selection between multiple connected models, failsafing all u

These commands allow the user to Loan/Return the model. For more information, see the [Loan Model](../../software/loan-model.md) guide.

This is deprecated and removed in ExpressLRS 3.4.0 in favor of the new Binding Procedures. See the [binding](../binding.md) page for details.
This is deprecated and removed in ExpressLRS 3.4.0 in favor of the new Binding Procedures. See the [binding](../binding.md) page for details or the **Bind Storage** section below.

### Output Mapping

Expand All @@ -414,6 +442,8 @@ For more information, see [PWM Receivers](../../hardware/pwm-receivers.md) page.

This option is available on ExpressLRS 3.4.0 and newer. See the details [here](https://github.com/ExpressLRS/ExpressLRS/pull/2542).

* `Returnable` - Introduced in ExpressLRS 3.5.0. It is used to allow models to be safely loaned from a fleet if unbound OTA. A Binding Phrase must be set for this to work properly. see [PR 2744](https://github.com/ExpressLRS/ExpressLRS/pull/2744) for details.

### Enter Bind Mode command

This will put the receiver into Bind Mode. It works even if the receiver is already flashed with a binding phrase or already bound traditionally.
Expand All @@ -432,6 +462,8 @@ This line shows the currently set Model ID for the receiver when Model Matching

* For fixed wings, we recommend using `100Hz Full Res`, together with either `Std` or your choice of Telemetry Ratio. Switch Mode will depend greatly on how many full resolution channels you intend to use.

* For Long Range applications, see the [Long Range Records](../../info/long-range.md) page and try the settings the pilots used to achieve the range. It is not guaranteed you'll achieve the same range as they are due to several factors like RF Noise in your area, your location and position and the antenna orientation on your aircraft and transmitter modules. Observe local laws and regulations.

## Troubleshooting the Lua Script

### <span class="custom-heading" data-id="1">ExpressLRS Lua Script is stuck at `Loading...`</span>
Expand Down