FS-i6s, Jumper T16, FRsky X-lite

bracesport

Legendary member
@PsyBorg - my programming has evolved over the last year more than my flying! But regardless of that, it will all pay a dividend down the track - my current DLG setup is borrowed from a friend and works well, but damned if I can figure out how most of it works - my plan is to unbundle it and make a simplified version as he is probably using more of its functionality that I need! hehe, yes, I would like to get the hall effect gimbals one day (my rig is an earlier version)!
 

bracesport

Legendary member
I made a start on deconstructing the DLG OTX that my mate uses for his competition gliders - the attached images are the main components, the mixing and global variables pages - as you can see it is immediately daunting!

This is a 4ch setup and is wholly based on modes - in the global variables there are six modes - normal/thermal/speed, two launch modes, and a calibration mode - these modes (flight modes) all feed into channels one thru four in the mixing desk driving the ship. Channels six through seventeen are controls and trims that also feed into the main four channels - they often can be grouped together to simplify things so you don't have to key in the info twice. To rebuild this structure in my own way I needed to first understand the functionality - for me, it was a case of using it on my DLG to feel it in action and then dumb it down to suit my skills!

Launch Mode
There are two stages to the launch - first is the rotate and release, followed by a fast climb, and finishing by pushing over at the top.
Flying modes
There are three flying modes - normal is essentially a no camber mode that flat and true, thermal is a float mode with maximum wing camber for good lift, and speed is getting from A to B quickly with some wing reflex to reduce lift and speed things up - in all three modes we have what is called 'snap' flaps which just means when the elevator is used the ailerons will respond with the opposite movement to increase the pitch change - this really helps to make tight turns in a thermal - I should also note that these guys use in-flight adjusters to change the flight characteristics on demand (now you can see why there is so much programming)!
Brakes
The DLGs have full-span ailerons that are used as flaps for braking and will be typically driven by the throttle stick - in all these modes with ailerons and flaps (flaperons) there is elevator compensation in the mixing to keep things on the level (so to speak).
Calibration
Finally, there is a calibration mode which essentially disables all inputs and mixes to allow you to calibrate and synchronise aileron travel etc - the calibration mode is usually accessed by some logical switches or a combination of switches and/or actions.

Ok, so now what!

For my level of flying, I can soft launch in the thermal mode (bypassing the launch modes) - so it is important to get the three flying modes built - the basic difference between thermal and speed is the camber/reflex - camber for lift, reflex for speed - in this case, the thermal mode has the camber adjustable on the left slider (LS) which from zero to full camber - the other two modes have their camber hardcoded, zero for normal and 6 deg up for speed.

To add the launch modes there is some trickery in the programming that is triggered by a two-stage momentary switch - in simple terms, the spin (launch 1) is a cambered mode and the fast climb (launch 2) is a reflex mode triggered by the momentary switch - at the top of the fast climb you push over and the elevator movement triggers a release from the fast climb (launch 2) reverting to any one of the selected three flying modes.

That's all there is to it (except for the in-flight adjusters)!

Lets see what we can do!


Screen Shot 2020-09-09 at 4.24.16 PM.png


Screen Shot 2020-09-09 at 4.40.48 PM.png
 

bracesport

Legendary member
I have essentially rebuilt the main functions with a few tweaks to suit my own thinking.

firstly I have added a screengrab of the inputs I have set up - the inputs are always about 'rates and expo' and also have the stick weights applied for ailerons and elevator - I chose to use global variables for the expo driven by SC which gives me 40/20/0 for expo - I could have also used global variables to drive stick weights, but am running low on them so I hard coded the rates.

For the mixing, you can see I have fewer lines of code at the moment - I group channels 12/14/16 into one channel 18 and then use channel 18 as one input in the aileron mixing to simplify things - channel 10 is an in-flight adjuster for aileron differential - there is no differential available in landing/lauch1/launc2 modes - channel 12 also has a second line that drives the camber in thermal mode from the left slider.

At the bottom of each main mix is the calibration mode which replaces all the lines above for pure stick calibration - the second to top line MAX weight (0%) is used to set the neutral point (centre) of the flaps after calibration - given the flaperons have gross asymmetric movement this number will not end up being zero.

I have added a flight mode called landing for the flaperons which was easier to implement than the complex programming to achieve this in the original OTX file - so far it has very similar functionality to the original file - I will add some more in-flight adjusters for tuning the reflex in speed mode, but other than that it is close to finished.

To enter calibration mode you need to hold the ail/ele stick in the top right corner and pull the SH momentary switch - to exit the calibration mode you just pull the SH momentary switch again - this is all done with logical switching and special functions.

So far so good!

Screen Shot 2020-09-09 at 5.31.34 PM.png


Screen Shot 2020-09-09 at 4.25.03 PM.png


Screen Shot 2020-09-09 at 4.41.06 PM.png
 

bracesport

Legendary member
This is more a record for me as I dabble with OTX, a month down the track it is too easy to forget stuff?

My slope ships and my DLG are quite similar in makeup mostly full span ailerons and an elevator - Pete my DLG mate does not use rates, and Jono my Slope mate does use rates - so I thought what if I could use logical switches to arm the sloper with rates and disarm the launch modes, and then visa versa for the DLG!?

We shall see! :)
 

bracesport

Legendary member
I find the OTX stuff interesting and have made some progress on this next bit of programming - the essence of what I want to achieve is two modes, either slope or DLG and when one is active the features not required are deactivated.

I have built a fully-functional version of this where at startup the model is in 'DLG' mode and with some predetermined stick positions and the flick of the momentary switch it will convert to SLOPE mode adding aileron rates and disabling the launch modes - I even built some custom voice calls for 'DLG MODE' and 'SLOPE SOARING MODE' - quite cool.

The first breakthrough is how I add or remove the aileron rates - we always put the rates in the inputs page and you can see I have 100/75/50 for hi/med/low rates - each is triggered now by a logical switch rather than a physical switch (previously SA for elevator and SD for ailerons) - the bottom line called 'catch' is normally there in case there is a switch failure and therefore the bottom line will be the default - In this case, I am using the 'catch' as the default when the rates are turned off.

To activate or deactivate the rates switches I use an 'AND' function which means that a physical switch is active only if the attached logical switch is active - for example if SA(up) and L30 are 'true' SA(up) is 'ON' - to control the logical switch L30 we use four lines of logical switch code which adds up to mean if I hold the Aileron and Elevator stick at -100 and -100 respectively and pull down the momentary switch 'SH', the logical switch L30 becomes true until the momentary switch SH is pulled again.

The next bit I will explain (in another post) is how I disable the launch modes when the rates are active.

You may well be thinking why to bother with this - why not just make a separate DLG and SLOPE programme - well, of course, there is no good reason other than 'because we can' - however, In the back of my mind I am thinking about a generic model that can be tailored to a given set of functions with some under the hood commands (for example when I use my sloper at the park and want to engage a prop).

Screen Shot 2020-09-14 at 9.24.42 AM.png


Screen Shot 2020-09-14 at 9.34.52 AM.png
 

Wildthing

Legendary member
I find the OTX stuff interesting and have made some progress on this next bit of programming - the essence of what I want to achieve is two modes, either slope or DLG and when one is active the features not required are deactivated.

I have built a fully-functional version of this where at startup the model is in 'DLG' mode and with some predetermined stick positions and the flick of the momentary switch it will convert to SLOPE mode adding aileron rates and disabling the launch modes - I even built some custom voice calls for 'DLG MODE' and 'SLOPE SOARING MODE' - quite cool.

The first breakthrough is how I add or remove the aileron rates - we always put the rates in the inputs page and you can see I have 100/75/50 for hi/med/low rates - each is triggered now by a logical switch rather than a physical switch (previously SA for elevator and SD for ailerons) - the bottom line called 'catch' is normally there in case there is a switch failure and therefore the bottom line will be the default - In this case, I am using the 'catch' as the default when the rates are turned off.

To activate or deactivate the rates switches I use an 'AND' function which means that a physical switch is active only if the attached logical switch is active - for example if SA(up) and L30 are 'true' SA(up) is 'ON' - to control the logical switch L30 we use four lines of logical switch code which adds up to mean if I hold the Aileron and Elevator stick at -100 and -100 respectively and pull down the momentary switch 'SH', the logical switch L30 becomes true until the momentary switch SH is pulled again.

The next bit I will explain (in another post) is how I disable the launch modes when the rates are active.

You may well be thinking why to bother with this - why not just make a separate DLG and SLOPE programme - well, of course, there is no good reason other than 'because we can' - however, In the back of my mind I am thinking about a generic model that can be tailored to a given set of functions with some under the hood commands (for example when I use my sloper at the park and want to engage a prop).

View attachment 178982

View attachment 178983
Oh my lord, that brain of yours just doesn't quit does it? :ROFLMAO::ROFLMAO:
 

bracesport

Legendary member
@Wildthing - I know, I have a problem!

here is a quick video from the simulator - starts in DLG mode (no aileron rates), moves to Slope Soarer (aileron rates no launch mode), then back to DLG.

There are some more functions in there for adjustable camber control, expo, and differential - basically they can be dialed in or out to your liking, but that’s for another post I guess! :)


 
Last edited:

bracesport

Legendary member
I just tested the program on the Tx, works like a charm - when you startup it always defaults to DLG as the SLOPE mode is something you trigger - I think I will try and make it a-sexual so you chose one mode or the other after start up, or better, once a mode is set it stays there! :)
 

bracesport

Legendary member
Building on my last comments, I changed the default model mode (when the radio powers up) to incorporate the common functions I use in all my gliders - normal/thermal/speed modes, trim adjustments for camber/expo/differential, and flaps - it also has snap flaps on/off, and trainer mode on/off.

Then using the logical switches I can turn on either SLOPE or DLG modes - to exit the modes I have a delay on the momentary switch of 5 seconds to prevent accidental deactivation.

Default model mode

adding SLOPE or DLG modes
 

bracesport

Legendary member
The next step was a general de-bugging of the setup, and I found my flaps were working as ailerons, not 'flaps', so I needed to fix that - otherwise everything seems to work quite well!

Some input from my mate Pete, (apart from why bother), was that differential is quite related to speed, so maybe that needs to be integrated rather than on a dial - also, with the expo, once you have a good setting, it is a shame to not have it remembered next time you load the model (again on a dial the setting will be lost).

So, some more tinkering is required!

One thing I like with the default mode, for example, is that with no 'launch modes' engaged you can launch the DLG in the thermal mode with a bit of camber for practice without the complexity of the two-stage launch.

One other thing - I also have a servo calibration mode, which when triggered allows us to balance the ailerons in the outputs page - in the mix line shown below, the bottom line for the left aileron is the calibration mode - you may see that the line is not added, rather, it is 'replacing' all the lines above (when active) - this means that all the mixes and trims are not computed in the calibration mode (instead it is the raw stick values).

I have used the same 'replace' trick in the second line - what that does is when in 'landing' mode, the ailerons are using heaps of differential to boost the upward moving aileron to provide more steering.


Screen Shot 2020-09-16 at 9.01.31 AM.png
 
Last edited:

bracesport

Legendary member
without going into too much detail - I made some changes, mostly in the mixing to make all the trims have a memory by using the trim switches rather than the dials and sliders - Camber and Reflex are tweaked by Tr5 and Tr6, and Elevator to Flap percentage under braking is tweaked by TrT (throttle trim tab).

I have also added differential to the global variables (flight modes) which essentially is speed-related - more dif at slower speeds (landing mode for example) - the dif for landing is at 70% which really boosts the upward aileron for more authority when going slow - the opposite is for Speed mode which dif reduced to a minimum.

Screen Shot 2020-09-17 at 12.25.30 PM.png
 

Wildthing

Legendary member
Well looks like it is time to put in the upgraded ribbons. I was just setting up the servos for the Extra and out of the blue "flaps down" was deployed.
 

bracesport

Legendary member
I did a test this morning with the new OTX file running in my Sloper with the crow brakes, and everything seems to be working well including the settings for centres and trims carried over from the original OTX file - the trainer mode is also working, but remember to use (+=) for the setup in OTX, not the :)=) as I did which gave me some kind of crazy offset between the Trainer stick positions and the Master - I am using 6P2 for trainer 'ON' and 6P1 for trainer 'OFF' which limits the number of switch positions to remember!

This is the most complex of my ships running 5 servos, but it was an easy addition to my master file structure adding channels 5+6 for flaps - given there are flaps the flaps mode needed the ailerons to now move up when the flaps go down for crow, but that was about it)! Regardless of the complexity, the file structure is very neat!

Some other small changes for Channels 10/12/14 - now they all use trim switches for in-flight adjustment with the values being stored in the model memory (better than a dial or slider).

I do have expo on the S1 dial which is always live.

Screen Shot 2020-09-25 at 5.06.06 PM.png