Lua Scripts - rotorflight/rotorflight Wiki

Introduction

You can adjust a variety of settings using only your transmitter with the Rotorflight Lua scripts. They allow you to change things like PIDs, rates, filters, failsafe and governed headspeed on the field. Prerequisites:

Examples:

If you're not using F.Port, start up the Rotorflight Configurator, go to the Configuration tab and enable the TELEMETRY feature. F.Port telemetry does work without enabling this feature.

If telemetry is working properly on your system, the Lua scripts should work as well.

Installation

Download the latest release and copy the contents of the SCRIPTS folder to your transmitter. See also the readme.

Usage

On your transmitter, go to the Tools menu of your transmitter and select Rotorflight conf.

Tools

The first time you do this all scripts will be compiled and the Tools menu will be displayed again. Select Rotorflight conf again. Now the script will wait for a connection with the receiver.

connection

Power up the receiver. The script will retrieve the API version used by Rotorflight and the device ID of the flight controller. After this you will see the main menu.

main menu

Here you can select what you want to change. For example, select PIDs.

pids

Now you can change the values of your PIDs. If you want to save your changes, long press Enter. The Page menu should now pop up. Select Save page to send your changes to the flight controller. Or press Exit to exit the Page menu.

page menu

There's quite a lot of settings you can adjust on the field. Here's an overview of all the pages:

pages

Feel free to have a look at any page. As long as you don't select Save page, nothing will be changed.