Thursday, December 20, 2018

Horizon UMX Servo Range

tl;dr: For Horizon UMX planes and an OpenTX transmitter, set output channel to 80%.

From RCGroups:

All Horizon Hobby Ultra Micro (UMX) models, from the very first Vapor nearly ten years ago, use linear servos. This includes the Champ.

These servos are not designed to go beyond limits corresponding to 100% in a Spektrum transmitter (1100-1900uS pulse width). If driven much beyond this range, they may suffer mechanical or electrical damage as their travel is physically restricted. Horizon issue strict warnings not to set the transmitter travel beyond 100%.

For the Taranis and other transmitters that use OpenTX or ER9X, 100% corresponds to 988 to 2022 uS. Thus, it’s essential to restrict the travel to about 80% (actually it’s 78%, but the servos have enough leeway that 80% is close enough).

You can do this by setting the weight on channels 1-4 to 80% in Mixers. A better way, however, is to set the output on those channels to +/- 80 on the Outputs page.

If you have more than one UMX model, set up one model this way, then copy it as many times as needed, changing just the name.

The arithmetic is as follows:
Spektrum_Transmitter: 1500 - 1100 = 400uS for full travel.
Taranis: 1500 - 988 = 512uS for full travel.
400 / 512 = 0.78125 I.e., 78.1%.

Sunday, December 16, 2018

Using the FrSky S6R and S8R Stabilizing Receivers

(update) One-page checklist is here. If you've been through the setup before, it's a nice summarized quick reference.

Here's my notes on setting up and using the SxR receivers. This is a Work in Progress.

Key Points:
  • There are quite a few steps, but most of them are pretty simple.
  • Don't skip any steps, especially the one called "Self Test".  It actually sets your plane's leveling and stick controls.
  • These notes use the Lua programs on the receiver, and not the USB link.  They also revolve around setting up "simple" mode.
  • If you have a voltage sensor, disconnect it from the receiver.  It can overwhelm the telemetry channel and interfere with the procedures below.
  • Manual mode:  The SxR doesn't do anything special, it works just like a normal receiver.
  • Stabilized mode: The SxR corrects for wind buffeting, allowing a plane to fly more smoothly in gusty or heavy winds.
  • Level mode:  The SxR will bring the plane to a flat and level flying position.
  • Recovery mode:  In any of the above modes, you flip a switch and the plane recovers to level flight.
  • A flyable model plane.  It's probably good if it's one you've successfully flown before.
  • Ensure your transmitter is running at least OpenTX 2.2.
  • Ensure your receiver has been updated to the latest firmware.  Sadly there's no way of determining the firmware version, so this means you need to update it yourself or trust your vendor has done it for you.
  • We'll assume you know some basics about binding, setting up a model in OpenTX, etc.
Both of these tasks are big enough to have their own blog post.  I'll do that as I go along.

The Big Picture

The step below are a breakdown of this plan:
  • Initial Benchtop SxR configuration
  • Initial OpenTX configuration
  • Model customization, SxR in plane
  • First flights and SxR Tuning
  • Finalizing SxR configuration.
1. Binding and Failsafe.
  • Binding is standard D16-style binding.
  • Be sure that you specify Channels 1-16 are available.
  • Set failsafe as normal.
  • Do other non-flying bindings (landing gear, prop safety, etc) as per your model.

2. Calibration using SxR_Calibrate program.

This is a one-time step that tells the receiver which way is up and down. Run SxR_Calibrate program to do this. Sticking some servies on channels 1-4 isn't required, but will help you see that you're getting thing right.
  • Long-press to get to radio setup menu.
  • Page to get to SD card.
  • Scroll down to SxR folder and click to open.
  • Scroll to SxR_Calibrate.lua
  • Long-press and select "execute".
  • Now you're on a screen with some instructions to follow.

There's six steps in calibrating.
  • The program will tell you something like "lay receiver flat, facing up."
  • Lay the receiver as told and hold it still.
  • The position data is stored in the receiver, and you are told to press enter to confirm.
Repeat this for all six directions the software tells you, and you're finished.  The receiver has determined which was is up and down and stored this configuration information in the receiver's memory.  You won't have to do this again.

3a. Set up initial transmitter bindings.

We'll change these up in a bit when we're ready to fly.  This is for setup.
  • Channels 1-4 are AETR: Aileron, Elevator, Throttle, Rudder.
  • Channel 9 is stabilization gain.  Set it to Input:S1, Scale:50 Offset:50
  • Channel 10 is flight mode: manual, stabilized, level.  Set it to Input: SC, no modifiers.
  • Channel 11 is unused in simple mode.
  • Channel 12 is for self-test mode. Set it to input SD, no modifiers. We will change this binding before we fly.
3b.  Set up audio announcing of the gain value.

Add this line to the Special Functions menu to play CH9 (the gain) every 5 seconds when switch A is down.

  • SA↓  Play Val     CH9     5

4. Initial Setup using SxR program.

  • Long-press to get to radio setup menu.
  • Page to get to SD card.
  • Scroll down to SxR folder and click to open.
  • Scroll to SxR.lua
  • Long-press and select "execute".
  • There are two screens of configuration information.  Use the page button to switch between the pages.
The first screen specifies the airplane type (normal, v-tail, delta a.k.a. wing) and receiver orientation, how it's mounted in the plane.
  • Set the airplane type.
  • Set the receiver orientation.  There's help at the bottom of the screen
The second screen specifies a lot of parameters.  At this time we only care about a couple of them:

  • SxR functions:
  • Quick Mode:
  • CH5, CH6 mode

5a. Bench Self-test (part 1)

Note that "self test" is a bit misleading.  The procedure also sets the level position of your plane and measures the endpoints of your control sticks.
  • Hook up some spare servos to channels 1 (AIL), 2 (ELE), and 4 (RUD). Hook up channels 5 and 6 if they're going to control AIL2 and ELE2.
  • Make sure your trims are centered.
  • Power on the receiver.
  • Flip switch D three times within 3 seconds to activate self  test.
  • You will see the blue Rx LED flash, and the output channels will be exercised.  You should see all three servos move.  This is commonly called the "servo dance."
  • Now move the AIL, ELE, and RUD sticks through their full range of motion.  This is important, it sets the endpoints.  It will also show you something is wrong if the servos don't move.
  • Disconnect and reconnect the power.
5b. Bench Self-test (part 2)

  • Put switch C (channel 10) in the down (manual) position.  This is manual mode, just like a regular receiver.  Move your Tx sticks and observe that the appropriate servos are moving.
  • Put switch C in the middle (stabilize) position and rotate S1 (gain) clockwise to the max position.   Jiggle your Rx, and you will see the servos jiggle and return to neutral.  Rotate S1 counterclockwise to zero gain.  You will see jiggling has less and less effect, until at the zero position there is no effect at all.  Make sure  your sticks move the servos as well.
  • Put switch C in the top (auto level) position and rotate S1 (gain) to max.  Rotate your Rx in several directions.  You will see the servos respond and hold their positions.  Again, rotate S1 to zero gain and you will see less and less effect, and make sure your sticks move the servos.

6. Install into Model
  • Remove or disable props and any other potentially hazardous parts of your model.
  • Attach your servos, etc to the receiver.
  • Using the supplied double-sided sticky foam tape, mount the model along the center line and near the center of gravity.  You can be off a bit with no worries.
  • Make sure the Rx matches the orientation set in step 4.
  • For wings, AIL = left wing, ELE = right wing.

7a. In-model Self-test

(WARNING: self-test will exercise channels 5 and 6 even if they are set to AUX.  If you have landing gear on one of these channels find some way to support your plane.)

This is mostly a repeat of section 5, only attached to the plane.
  • Position your plane as it will be in flat and level flight.  Some models like wings need a couple degrees of up-nose.  Do what's right for your model.
  • Power on the model and triple-flip switch D to start the self test.  You'll see the blue lights flash and the servo dance.
  • Fully exercise the sticks to set the endpoints, and reboot.
At this point, your level-point and stick endpoints have been set, so we need to switch channel 12 to be the momentary H switch.
  • Go to channel 12 on the mix menu and set  the input as momentary stick H.
  • If you leave channel 12 on a 3-position switch, you can accidentally trigger the self test while in the air which will be a disaster.
7b. Initial Model Setup
  • Switch to manual mode and reverse any channels needed in the usual way (e.g. stick input menu).
  • Set the gain high, hold the plane level, and switch to auto level mode.  Rotate your plane around the three axes and test if the control surface motions are in the correct directions.
  • If any of the control surfaces need reversing for auto level, run the SxR program and set the direction to INV on the second screen.  Reversing takes effect immediately.  Test your sticks through their full range of motion while moving the plane around.
  • Switch to stabilize mode and repeat the stick tests.  Jiggle the model and you will see the control surfaces respond to counteract.
  • Flip switch H (recovery) in all modes.  Ensure that when the H switch is held the plane is in auto level mode.
  • Experiment with the gain knob, and see how it goes from no effect to maximum effect as you move the plane around.  You can flip switch A down to hear the gain values announced.
[insert video 6/7 here]

8. Initial Flight

  • Take off in manual mode and adjust your trims, etc, as usual.  Fly to three mistakes high.
  • Now we'll test stabilized and auto level modes. Be ready to switch back to manual mode if things go bad.
  • Turn on gain announce by flipping switch A down.
  • Set the gain to a low value, and switch to stabilize mode.  Gradually increase the gain.  If it's windy, you should feel the plane smooth out as the gain increases.
  • Increase the gain a lot, and you'll see the plane start to jitter in the air as the stabilizer overcorrects.  Back off until the plane feels good in the air, and make a note of the gain value.
  • Now switch to level mode.  If you have an incorrect orientation setting, the plane will flip over and otherwise go crazy.
  • Fly around a bit, letting go of the sticks.  When the sticks are in neutral position, the plane should fly flat and level.  Increase the gain until the plane becomes unstable, and back off the gain.  Note the gain number.
  • Test out recovery mode.  You should be able to go from any position to flat and level flight by pulling the H switch.
At this point, you've finished up most of what you need to do.

[insert video 8 here]

9. Final Adjustment of Gain channel

Now that you've got a good stabilize gain value, you won't want to have to worry about keeping the knob in the exact right position.  Go to the mix menu, and change channel 9 to be
  • src = MAX, scale = X (where X is your stabilized gain)

10. Final Adjustment of Auto Level Gain

If you needed a different gain for auto level, run the SxR.lua program and adjust the AIL stab gain and ELE stab gain.  You will have to experiment to get the exact values dialed in.

11. Set Failsafe to Auto Level Mode (optional)

Finally, if you think it's a good idea, you can configure failsafe to include auto level mode.  Perhaps setting it to power off, slight circle, and auto level?

[insert video 9/10/11 here]