Thread Tools
This thread is privately moderated by on4mj, who may elect to delete unwanted replies.
Dec 05, 2014, 04:39 PM
Thread OP

F3K training script for the Taranis, Q and Horus

My F3K training script for the Taranis (regular, plus, Q) and the Horus, providing timing for all the F3K tasks excepting poker, plus a couple training goodies, is now available on RCsettings.

If you have bug reports, improvement suggestions, etc... post them in the comments here, I'll see what I can do.


This F3K Training application for the Taranis is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

In short (follow the link above if you want the details), this means that :
  • You may copy, distribute, use my work and make derivatives provided you give me the credit for the original work.
  • You may distribute derivative works only under an identical license.
  • You may copy, distribute, use my work and make derivatives only for non-commercial purposes.


Updates in 3.02
  • Added AULD.
  • Fixed a regression introduced in 3.00 where a false launch could be detected when running the same task more than once.

Update in 3.01
  • Horus fix: widget browsing was breaking an installed F3K training.

Updates in 3.00

The script set has been refactored to separate the views from the engine. The firmware abstraction layer has been expanded.
The result is a much more "cross-plateform friendly" application.
The Horus port was originally contributed by xStatiCa. Thanks Adam
  • Runs on the Horus and the Q.
  • OpenTX 2.2 support for the Taranis.
  • A few sound files were updated.

Updates in 2.05
  • Changed the QT practice to count down from 30s.
  • Solved some OpenTX 2.0 vs. 2.1 incompatibilities.

Updates in 2.04
  • Added a "Free Flight" non-task, which provides a normal usage of the timers.
  • Added the total flight time to the QT practice.

Updates in 2.03
  • Added variations with a 7 minutes work time in task A & B (at the bottom of the menu).
  • OpenTX 2.1.x compatibility (not tested on the transmitter)


There's a new sound file 'taskb7.wav'.
If you're upgrading from a previous 2.0x release of the script, you can keep your current custom.lua file.
If you're using OpenTX 2.1 (which I do not recommend yet), read the documentation for the installation instructions.

Updates in 2.02
  • Added a quick turnaround practice "task".

Updates in 2.01
  • Fixed a regression introduced in 2.00 which caused the script to crash in several tasks when the plane was still flying at the end of the working time

Special thanks to Cory Shantz for reporting the bug and doing the QA after that.

Quick Fix 7 May 2015

I released 2.00 with the wrong documentation. That's fixed.
Sorry about that.

Updates in 2.00
  • Major refactoring: split the original script in several dynamically loaded files to get rid of all those memory problems
  • Added Task M
  • Correction of a false launch detection problem when the previous task was "Done !"


There's a new sound file 'taskm.wav' (with a different voice, unfortunately) for the Big Ladder announcement.

Documentation update - 5 Feb 2015
  • Changed the alternative detection functions to the working version (see around msg #86 in this thread)

Updates in 1.02
  • 2.0.15 compatibility : reduced the memory footprint (the short window option had to go, sorry about that)
  • When running the "last" tasks several times in a row, the "improve margin" message could stay on screen at the beginning of the subsequent tasks
  • When running "ladder" several times in a row, the flight timer was not reset
  • In last 2&3, you won't be congratulated for maxing a single flight anymore; only for maxing the task
  • Added congratulations to 3oo6
  • Corrected the initial display of 1234
  • Reduced the usage of setTimer(), which seems to write in the eeprom !! (so, probably improved the life expectancy of the TX)
  • Reduced the default temporary switch holding time again (to 0.6s this time).
It finally seems to work with my settings in 2.0.15. If you have any trouble, let me know (most often, this would happen when ending a task and returning to the menu). I would still advise to keep 2.0.13 unless you have really good reasons to upgrade (like the LCD freezing when it's too cold (sic!)).

The launch/land detection has changed a little (removed the wrapper function), so, if you've written yours, take care with that.

Updates in 1.01
  • There's now a preparation time of 16s before the start of the work time ; the launch can be anticipated as long as the switch release occurs after the work time has started
  • Reduced the default temporary switch hold time to 0.9s
  • The short window time was not initialized with a default value
  • Better support of custom launch detection functions


There's a new sound file 'badflight.wav' (used to signal a launch during the preparation time).

Last edited by on4mj; Oct 23, 2017 at 08:13 AM.
Sign up now
to remove ads between posts
Dec 05, 2014, 05:55 PM
nigelsheffield's Avatar
This is going on my Taranis first thing tomorrow, weather is rubbish though for real testing but I will do some couch test runs lol!
Will definitely make my flying more fun!
Thanks mike.
Dec 06, 2014, 01:56 PM
nigelsheffield's Avatar
HI mike tested it on couch as promised lol.
Perhaps you can clear up some of my confusion with tasks in general.
The ladder task only counts the actual task time and not any extra time, ie 33 seconds will only score 30 seconds, so only the task target is flown for best chance of getting through the tasks, if 2 competitors both get to 105 seconds then they are separated by total flight time, no need to add this to the script though as we can just add it up if needed.
where as the 1234 basically the best 4 flights count with 4 mins being max for one flight and then 3 min max for another etc,
sorry to be so vague but I am trying to understand what the strategy of a competitor might be to get max score.
I have never been to a competition so struggling to get how the whole thing works.
Feel free to delete this if you like as its just none sense as far as your script goes lol..
Dec 06, 2014, 04:31 PM
Thread OP
Does this help ?

Here's my own view about them (but a better pilot than me should step in to describe his/her strategy, because I'm really not good enough to give competent advice in the matter) :

In ladder, the idea is to fly just a little over the target time to validate the current step. There's really no strategy involved. It's duration with land on target (you ).

When the flights become long enough, you can patrol to get an idea where to go the next time. There's a little margin of time to take a look around you and see what the others are doing.

In 1234, for the flight duration, you aim probably more towards a little under the target time, to minimize the loss due to the re-throw (as 1+2+3+4=10, you can't do the theoritical max).

There, the strategy depends on the weather, I guess. For example if you follow a thermal coming to you, it can be a good idea to shorten your flight and rethrow directly in it before it's too far. So you can make a second long(er) flight and be able to come back. Well that's theory anyway But it depends on the amount of wind, of course.
Dec 06, 2014, 05:32 PM
nigelsheffield's Avatar
Thanks mike.
That clears it up for me.
I think I read a few different versions of the scoring for the different tasks, I guess it varies from country to country a bit.
OK now I need some decent weather to go fly with it.
Dec 06, 2014, 05:38 PM
I don't want to "Switch Now"
pmackenzie's Avatar
Finally a very good reason to upgrade to 2.0
Dec 06, 2014, 05:54 PM
nigelsheffield's Avatar
Yep good script, so the reason to go to 2.1 is gonna be SD card access of some sort so scores can be saved for later!
Dec 07, 2014, 06:16 PM
Registered User
I have a little problem with the script Michael.
I am using your DLG epee.
Everytime I use springloaded switch SF (it enables the launch preset, and flaps up,etc, you know), the active task says Finished.
Dec 08, 2014, 03:09 AM
Thread OP
Have you disabled the timer control from the Special functions ?
I can't remember exactly from the top of my head, but my initial setup restarted the timer on switch F, to get the flight duration. This is not compatible with the script. You should look for that and untick the "ON" box on the right (if using Companion).
Dec 08, 2014, 10:04 AM
Registered User
Thnx Mike,
That was the Golden Tip.
Dec 15, 2014, 10:34 PM
Do it AGAIN! This time BETTER!
ThermalThief's Avatar
Thanks for this post Mike!

I like the idea however I too have issues with the SF momentary as I have a launch sequence linked to that which runs for about 4 seconds after activation.
I have another momentary that I could install in the SH switch location and then a slight alter of the script.

Dec 16, 2014, 01:29 AM
Do it AGAIN! This time BETTER!
ThermalThief's Avatar
I played with this more tonight and think reducing the time on the SF Launch setting will work better although flight times will be slightly overstated.
This will sound be a fun and valuable practice tool.
Thanks again Mike for all the work you put into this!
Dec 16, 2014, 03:40 AM
Thread OP
Originally Posted by ThermalThief
I like the idea however I too have issues with the SF momentary as I have a launch sequence linked to that which runs for about 4 seconds after activation.
I have another momentary that I could install in the SH switch location and then a slight alter of the script.
It's difficult to know exactly what your issue is without knowing the details, but maybe you have a logical switch in your programming which is suitable as the input instead of the real switch ?

And thanks for your comments
Dec 16, 2014, 10:23 AM
Do it AGAIN! This time BETTER!
ThermalThief's Avatar
I was having some problem getting a reliable land - launch transition. The time would stop (land) but not restart (launch) sometimes. I think it is likely due to my logical switch that looks at the SF and remains on for 4 seconds when activated.

I tried using a new logical switch in the LUA but got a error when loading the script. I'm not familiar enough with the script writing and thought L## must not work.

As I have it now it requires 1 hold of the SF switch for .2 and I get a land - launch transition but my flight time now includes much of the turn around. As a training tool I can work with that.
Dec 16, 2014, 11:00 AM
Thread OP
Or you were too fast for the 1.2s delay, perhaps ? (it works for me, but my launching skills won't break any records soon ).

I've given it a little thought since my first answer, and I don't see how the LS could affect the reading of the temporary switch (it's the physical input which is monitored).

But as long as you can easily make the difference between a simple landing and a turn-around, I guess it's ok as you did it (it would be way too short for me, though !).

Regarding the accuracy, well, it's not expected to be rigorously exact with such a launch/land detection. But as you say, it's good enough for training

Anyway, have fun

Quick Reply
Thread Tools