Good day! Today I'm going to show you how I put Betaflight Lua scripts on my
Jumper T16 in just 3 simple steps! Lua scripts are just mini computer
programs written in the Lua programming language which is supported by the OpenTX
system firmware. There are many Lua scripts available to
do lots of things, however the Betaflight Lua script I'm installing and executing
today allows me to change video transmitter, GPS, and PID tuning values
without the quad connected to a computer and without using my goggles! Sound
interesting? Then give it a thumbs up below and subscribe to your TMac FPV
channel - your home for your "Journey to Better" FPV fun, flights, and
racing stuff! Alright, the first thing we're gonna do is go to this URL and download
our Betaflight Lua script. As you can see, in Betaflight Lua scripts 1.4.0
they added support for the Jumper T16 which is dated October 12th.
System requirements is that you run OpenTX 2.3.2 or newer and also they've added
support for Betaflight 4.1. The latest release of the Lua scripts however is 1.4.1
So, we're going to download that to a folder which I've
already established. So, we download the zip file - downloading over here, and I'm
going to put that downloaded zip file in the folder that I've already made under
Betaflight Lua scripts. Paste. From there I'm gonna extract it. It
creates this obj folder. Within this obj folder you have three different
folders: bf, scripts, and sounds. These are the ones we're gonna want to copy and
paste on our sdcard. We'll come back to that in a minute. Alright now what we're
gonna do is power on the T16 in bootloader mode by pushing T1 and T4
together and pressing the power button. Then we're gonna plug in our USB
cable. USB is now connected. Now what I've done with the USB connected is, I've
opened up two windows. This window on the left is my computer folder for Lua
scripts, under obj folder. These are the three
files that we want to copy and move over to our SD card. On the right is the
window for our SD card of our jumper T16. So all we want to do at this point is
take these three files, copy them and paste them over here.
Now it's going to say that I've got files with the same name and that's just
because I've done this before. So I'm gonna go ahead and say replace the files
just for demonstration purposes. Now all of these folders with the various files
in them have gone to the appropriate locations on our SD card. Now for our
Bonus Section! If you'd like your VTX page (which is currently page 8) to show
up as page 1 when you execute your Betaflight Lua script, then you need to get a
Lua script editor. In my case, I just downloaded this Lua edit free IDE
debugger editor for Lua and it shows up as Lua Edit. Just download and install a
Lua editor which will save your file as a .Lua file. Then before you transfer
over your Betaflight Lua script files from your computer to your SD card, you
want to edit one specific file. The file that you'll want to edit is under your
obj folder, scripts, bf, and UI.Lua. Now I cannot take credit for this
idea. I got this idea from Mr. Joshua Bardwell (or Josh Bardwell or JB) so thank
you very much Mr. Josh Bardwell. This is the file you want to edit. So you open
this up, right click, open with Lua edit 2012. It opens up the UI.Lua file.
This line right here local current page=1 you want to change that to
the page number of your VTX page or whatever page you want to jump to. If you
want to jump to your GPS page the first GPS page is page 9. I want to jump to my
VTX page as the first page which is page 8. So I'm going to change this to 8.
Then you want to file - save UI.LUA. Then you can close, exit out. Now when
I reopen this to confirm my save took place, I see that it's now
changed to 8 which is what I want. From there, you just take these three
folders like you did before, copy and paste them to your SD card and then
execute the program from there and your VTX page will show up as page 1! Now
that they're on the SD card, we can unhook the USB cable from the
transmitter and exit out. Okay, now that we've got the Betaflight Lua script on
our SD card inside our jumper T16 transmitter, to get to it and execute it
we press the SYS button (SYS) to get into the radio setup menu.
Radio setup. Press the page key once and now you see that we've got this bf file
folder here. Make sure that that's highlighted. Click the scroll wheel once
and within that folder you see we've got bf.Lua and bf.LuaC files.
To execute the Betaflight Lua script which we've uploaded to our SD card, with
your quadcopter powered on and, if you're inside, the props off - just make sure to
highlight the bf.Lua file and click on it. Then highlight execute and
execute. There you see that we've got the options to change our PID values and
to navigate within the Betaflight Lua script you can use the page key just as
you normally would. Press it once to page forward once, and press and hold it to
page back. Your various options within the Lua script are to change your
PIDs - you see page one of two and two of two. You can change your rates, advanced
PID features, filters, motor stuff, video transmitter (which is one of the main
uses for the Betaflight Lua script). Also, GPS Rescue. Now a good example of this is
if you happen to have GPS Rescue set up on your quadcopter and
you've got a telemetry receiver - obviously if you're using the Betaflight
Lua script that you've got a telemetry receiver - then you can actually
put the number of satellites as one of your telemetry values on your
transmitter screen in one of the widgets. For instance, if minimum satellites
is set to 8 and you get to a fly spot where you're only picking up maybe 5 - 7
satellites and you see that on your widget, then right away you can just
use your transmitter to go into the Betaflight Lua script at the GPS rescue page
and change your minimum number of satellites. To change these various
options you just click on it with a scroll wheel like you normally would and
use it to change your options. So that's how you make changes to it. Now, once
you've made changes, to save your changes (the changes are only applied for the one
particular page that you're on) . . . to get the options for saving your changes, you
need to click and hold the scroll button down and then you've got this menu that
pops up that says save page, reload, or reboot. Now obviously if you've made
changes and you want to save them then you click on save page. If you've made a
mistake and you want to go back to the default values (or the values that you
had in here prior to making changes) then you hit reload. I'm gonna go ahead and
click save page so that you see how this is done. Now it's saved. To get out of
here, you press and hold the return key and it
goes back to your SD card. Then you just navigate as normal. So what I'm
going to do now is I'm going to go ahead and demonstrate how you can change the
values of your VTX with this Betaflight Lua script. Now to do this little
real-time demonstration of the Betaflight Lua script, what I've got set up
here is my Eachine ROTG01 Pro receiver hooked up to my Android phone. This
receiver together with the app on the phone forms an FPV display. What you're
seeing is the view from my FPV camera on my
workbench. This is a handy little device for your workbench or for spectators
while you're doing some actual flights. If you're interested in this product,
I've got links to it down in the video description below. We're gonna execute
our Betaflight Lua script by pressing down and holding this SYS button. Getting
into radio setup, going to our SD card menu, bf folder, press enter, press ENTER
and press enter. This brings up the first page. I know the VTX settings are on (or
towards the end) of the menu pages so I'm gonna press and hold the page key. That
gets me to GPS Rescue. Press and hold, press and hold. That takes me to the
VTX page. It's currently on F2 at a power of 200mW. Let's go ahead and change this to
F4. There I made the change - but our FPV display didn't change at all! why is that?
Well, simply because we didn't save the page yet. Remember, for each page you need
to save it. Press and hold the enter key, save page and this should go out - and it
did. So it worked! Now on this little device here, the way to get the frequency
back on your FPV display is just press and hold this button and it'll scan it
and it'll find the peak frequency - right here. Then, once it's done scanning,
it'll go to that. Now as we're waiting you can go ahead and make the same
changes using the Betaflight Lua script to your band, or your power as well.
Now we're locked in at F4. That's how you use Betaflight Lua script to make
changes to your VTX or any other options that you have available to you.
So that's how you can download, install and execute the Betaflight Lua script
with your Jumper T16 transmitter. Another one of the fun features brought to you
through OpenTX, Betaflight and the Multi-protocol Module developers who you
can support through links in the video description below. If you found this video
useful, make sure to share it with your friends. Thanks for your time
and your support of your TMac FPV channel. I'll see you next video.
Clear skies friend!