edgetx icon indicating copy to clipboard operation
edgetx copied to clipboard

Trainer with SBUS over AUX1 not working since 2.11.0

Open soumas opened this issue 1 year ago • 23 comments

Is there an existing issue for this problem?

  • [x] I have searched the existing issues

What part of EdgeTX is the focus of this bug?

Transmitter firmware

Current Behavior

I'm using SBUS signal (generated by a Graupner Hott GR-12 receiver) at AUX1 as trainer "Master/Serial" on my TX16S. After upgrading to the latest Version 2.11.1 I noticed, that my trainer setup no longer works.

Going back version by version (bare firmware and sd card content) I found out, that the latest working version is 2.10.6 with which everything works as usual. A lot has changed in recent versions, but I haven't been able to find any breaking changes that might be related to this.

Did I miss something, or could it be a bug?

Expected Behavior

In "Systemsettings --> Trainer" the values should change when the sticks on the student transmitter are moved.

Steps To Reproduce

  1. Clean Installation of EdgeTX 2.11.X on TX16S
  2. Systemsettings --> Hardware --> AUX1 = SBUS Input and power on
  3. Modelsettings --> Trainer --> Mode = Master/Serial
  4. Connect any SBUS generator to AUX1 (power and signal, inverted) --> TX16S does not recognize any student transmitter at all --> Same works fine with Version 2.10.6 and lower

Version

2.11.1

Transmitter

RadioMaster TX16S / TX16SMK2

Operating System (OS)

Linux

OS Version

No response

Anything else?

No response

soumas avatar Jun 22 '25 15:06 soumas

When I upgraded I noticed that under model setup, the trainer Ch. Range changed from 1-4 to 1-0 which disabled the trainer output. Selecting 1-4 fixed my issue, it might be worth checking that.

pagrey avatar Jun 22 '25 17:06 pagrey

@pagrey Thank you for the tip. You mean "Model Setup -> Trainer"? Unfortunately, that doesn't solve my problem. I can only change the channel range there if I select the "Slave/Jack" trainer mode. My transmitter, however, is supposed to operate as "Master/Serial."

soumas avatar Jun 22 '25 19:06 soumas

That makes sense, my situation was the slave not generating a signal and you said you have a valid sbus signal input.

pagrey avatar Jun 22 '25 20:06 pagrey

Just tested it here, working fine, I get trainer input in trainer screen using an ER6 inverted SBUS output connected to AUX1

3djc avatar Jun 26 '25 10:06 3djc

Okay, thanks! Good to know, but even stranger. Since my setup works with older EdgeTX versions, I think it must be a software issue. The only thing I can think of is that my SBUS signal isn't exactly at 3.3 volts, and earlier firmwares were more tolerant in this regard. I'll look into that.

Any other helpful ideas/inputs on how I could analyze the problem?

Thanks, Thomas

soumas avatar Jun 26 '25 11:06 soumas

If you paste your model and radio data I can test with those, but most of it is simply hardware driven

3djc avatar Jun 26 '25 11:06 3djc

I wonder if and how a GR12 ever worked on AUX1. AFAIK Graupner receivers outputs true (idle low) SBUS. AUX1 requires inverted (idle high) SBUS. @3djc demonstrated this with an ELRS RM ER6 receiver set to inverted SBUS on AUX1.

Graupner receivers work fine in the JR Bay because there true SBUS is accepted while inverted SBUS will not work.

mha1 avatar Jul 01 '25 08:07 mha1

Indeed ONLY inverted SBUS will work on AUX1, but I (likely wrongly) assumed that this is what the GR12 was giving, since he says it worked in 2.10.

3djc avatar Jul 01 '25 08:07 3djc

Indeed ONLY inverted SBUS will work on AUX1, but I (likely wrongly) assumed that this is what the GR12 was giving, since he says it worked in 2.10.

Some time ago I set up a buddy system for one of my club mates. TX16s with a GR12 in the module bay (GND, VCC, SBUS to SPort pin). And I'm sure Graupner receivers don't have an option to invert SBUS. You can just select SBUS as one of the serial options.

mha1 avatar Jul 01 '25 09:07 mha1

Thank you for your feedback!

If you paste your model and radio data I can test with those, but most of it is simply hardware driven

Thanks for the offer. But I'm using a fresh installation for testing... just firmware flash and standard SD card content. So I would rule out a configuration problem with the model.

I wonder if and how a GR12 ever worked on AUX1. AFAIK Graupner receivers outputs true (idle low) SBUS. AUX1 requires inverted (idle high) SBUS. @3djc demonstrated this with an ELRS RM ER6 receiver set to inverted SBUS on AUX1.

I'm inverting the SBUS signal between the GR-12 output and the AUX input. I built the inverter myself according to the circuit diagram: https://intofpv.com/t-creating-an-sbus-inverter - I can't rule out the possibility that the inverter isn't working properly. But as I said, it's worked so far.

Graupner receivers work fine in the JR Bay because there true SBUS is accepted while inverted SBUS will not work.

I wasn't aware of that. That would probably be a much better option. I'll try the JR Bay and report back here.

soumas avatar Jul 01 '25 09:07 soumas

Only a scope will tell if your inverter works properly.

Here's a great, very clean, and removable option to put have an SBUS capable receiver in the JR bay. It also integrates a 5V regulator which is important for eg ELRS non-PWM receivers: https://radiomasterrc.com/products/radiomaster-sbus-wireless-trainer-modules

mha1 avatar Jul 01 '25 09:07 mha1

6579905 seems to have removed the pin pull up. This might be the source of the problem in #6355 as well. Previously init called pinInit.Pull = LL_GPIO_PULL_UP; but I think that was removed. GPIO_IN_PU might have been the correct argument in line 42 of aux_ports.cpp instead of GPIO_IN.

I don't know if that information was moved somewhere else or if there is a reason not to have it setup the way it was. The inverter circuit used isn't going to work unless the pin has pull up enabled. If you want it to work and are able to do a custom build all you have to do is change the value I mentioned and it should work again.

pagrey avatar Jul 01 '25 14:07 pagrey

line 42 of aux_ports.cpp

This line initialises the pin that controls the power output in AUX1 / AUX2 (if supported). It is initialised as output, not as input, and thus has no pull-up, as output pins are either push-pull (default), or open-drain (very seldom used).

raphaelcoeffic avatar Jul 01 '25 17:07 raphaelcoeffic

It's not exactly the right topic, but after testing, I can now confirm that the trainer setup with the GR-12 via the "RadioMaster Sbus Wireless Trainer Module" works flawlessly in the latest EdgeTX version (2.11.2).

Since I'll stick with the JR Bay setup and the problem with my AUX setup only exists for me, I'll close this case.

If further similar cases become known later and it would be helpful for development here, I'd be happy to conduct further tests. Please just let me know.

Thank you for your feedback and support!

soumas avatar Jul 04 '25 15:07 soumas

There is no issue per say, aux1 requires inverted sbus, jr bay doesn't because there is an hardware inverter in there (but in turn will not work with inverted)

3djc avatar Jul 04 '25 15:07 3djc

Okay, 3djc, I'm not sure if you've correctly identified the original problem or if I'm misunderstanding you. The original reason for my question was that a functioning trainer setup (GR-12 --> Inverter --> AUX1) suddenly stopped working starting with version 2.11.0.

This is still the current situation - so there's definitely a change starting with version 2.11.0 that's causing this problem for me (or perhaps for others).

This issue is no longer relevant to me personally, though, as I've switched to the JR Bay (GR-12 --> JR Bay) based on mha1's suggestion, and it works perfectly.

soumas avatar Jul 04 '25 19:07 soumas

No, it simply never worked this way, aux1 is a serial port and cannot hardware decode uninverted SBUS. Never did and never will (at least on this generation of radio. With the upcoming h7 based models, this will become possible)

3djc avatar Jul 04 '25 20:07 3djc

Okay, there's probably no point in explaining again that my setup worked and that I successfully used it for wireless trainer-student communication. Then I must have been a wizard until version 2.11.0 :) Thanks anyway, 3djc!

soumas avatar Jul 04 '25 20:07 soumas

Well, I suggest you try it again, because I just did. Flashed 2.10.6, connected the same receiver as before with inverted SBUS, worked fine. Reprogramed it to output SBUS like your GR12, doesn't work...

3djc avatar Jul 04 '25 20:07 3djc

I understand that. However, unlike your test setup, I have – as described above – a hardware SBUS inverter between the GR-12 output and the AUX1 input. So, theoretically, the same signal should arrive at AUX1 as yours.

soumas avatar Jul 04 '25 20:07 soumas