Need some input on this strange issue with a 3.1 and x-plane

Status
Not open for further replies.

raflyer

Well-known member
Set-up,

Same version X-plane 10 on both a laptop and a desktop. Same Teensy plugin on both pc's.

I have a Teensy 3.1 in a Throttle set-up with 10K pots. I am using the analog ref, and AGND and pins A0-A4 for the 5 pots.

I have it programmed to the throttle ratio dataref.

Plug it into my laptop, works perfect, controls the throttles very smoothly in x-plane.

Plug into my desktop, Throttle stuck at full and no movement shown. I checked the voltages on the Teensy and they change as they should when I move the throttle levers but nothing moves in the Sim. The teensy controls window shows output at 1.0 which is full throttle.

Plug it back into my laptop, everything works perfect.

Again, same version of x-plane and Teensy plugin. I actually copied the teensy plugin from the laptop over to the desktop. Still no joy.

I know someone will ask for the sketch but we know it is good as works perfect on the laptop.

Ideas??
Thanks
Rob
 
Maybe try the TeensyControls "Show Communication" feature in X-Plane.

http://www.pjrc.com/teensy/td_flightsim.html

If that doesn't reveal the problem, perhaps add some Serial.print() lines to your program, to print the actual measured values to the Arduino Serial Monitor. Run X-Plane in non-fullscreen mode, so you can also see the serial monitor window. See that page for an example.

If the values come through correctly in the serial monitor, but wrong things happen in the simulator, maybe use the DataRefEditor to view the datarefs.... also shown on that web page.
 
I also had a problem with X-Plane propeller settings a while ago and it turned out that sometimes there apparently are multiple datarefs that seem to control the same thing, but actually, some of them aren't inputs, but outputs.

To make it clearer: In my case, if I remember it right, I tried to control propeller pitch, setting the pitch value directly. However, the pitch value is a CONSEQUENCE of the pitch lever position - and some other variables, like oil pressure. Once I found the correct dataref to set the pitch lever position, things worked as expected.

So, the first question would be: do you use the same aircraft on both computers? If so, what are the actual datarefs you are modifying?

Apart from that, Serial.println() is your friend.

Hope this helps.
 
Just an FYI if anyone else runs into this, it was a ground issue. The laptop was isolated from the ground plane so the teensy worked fine. When plugged into the usb on the desktop, a short to gnd on input signal of the teensy would shut down the AREF output so it wouldn't read the pots. All i did was swap the power and ground feeds from the pots and it worked. Gotta love grounds loops in highly complicated aircraft wiring trying to replicated by an amateur person. :blink: :huh:
 
Status
Not open for further replies.
Back
Top