PDA

View Full Version : Interfacing an old Cessna nav indicator w/ resistive OBS encoder



forty-2
10-14-2012, 10:26 PM
Greetings -
After finishing up my Arduino keypad radio, I decided to reward myself with an eBay binge. I picked up a Cessna ARC IN-514R nav indicator (pic attached) for the hefty sum of $1. I'm successfully controlling the CDI & to/from flag, but the OBS knob is a brain scratcher.
7129

The OBS knob is not a synchro as I assumed it would be, but a continuous wire-wound potentiometer with 4 taps. I made a schematic of the device:
7128
I've never seen anything like it.

I went ahead and hooked it up to an arduino, using 4 analog inputs. Feeding the wiper with 5v, wiring the 4 poles to ground with a 1k resistor, & hooking up the analog between the pole & the resistor. I wrote a Max/MSP patch to dump the values into a table as I incremented the OBS knob by 10°. Take a look at the attached graph made in Excel from the values.
Its a bit lumpy; I'm sure the wiper could use a cleaning, but lumps aside, I just can't figure out how to take these values and turn them into a rotational angle. I'm hoping there's a simple analog circuit or equation that can turn this into something meaningful. I suppose I could do it with a big, convoluted look-up table, but that just seems lame.
Any ideas?
7127
Thanks!!

hyamesto
10-15-2012, 02:31 PM
Hello, forty-2
I have the same instrument and I'm in the same experiment.

7140
The original system works as follows:
Between the inputs 0 and 180, is injected with a sine signal, and between the inputs 90 and 270, cosine signal is injected.
The phase difference between both is sensed by the wiper. (The signals are generated by the ground station, the phase difference is calculated by the receiver in the plane, and show in the instrument)


Your approach is the same as the one I try to use, but with 10k resistors instead of 1 k (no matter).
The values in the following picture, are the internal values of the wire, between the taps. (in my instrument, of course).
I´m working with opencockpits cards, with 4 analog inputs of 8 bits each.
7142

7141


If you can, attached excel sheet, maybe we can do something.
Excel can infer or approximate the formula automatically. I've seen some tutorial how to do it, but I forgot where ...
Luck.
Sorry if my english is no good.
Horacio

forty-2
10-15-2012, 08:40 PM
Hi Horacio,
Your English is great, and a heck of a lot better then my Spanish!
I've posted the Excel spreadsheet. Yeah, I was wondering if there was a way Excel could do some of the work. I'll ask our Excel expert at the office, but that curve looks awfully daunting in a calculus kind of way.

Can you post the attachments again? I'm getting an error on the site when I click on them.

I was wondering about the phase difference approach, but thought it was only applicable to Synchros / resolvers. With this 'multi-tap potentiometer', I would think you'd just see a varying mix between the two signals, but no changing phase shift. Couldn't hurt to try, I suppose. I can generate the waves & read the result on the wiper in Max/MSP (Cycling 74 (http://www.cycling74.com)) using my laptop's audio jacks. I'm gonna go hack apart some 1/8" cables!

Cheers,
Paul

hyamesto
10-15-2012, 09:13 PM
Paul:
The attachment are only pictures of my instrument and internal meditions of the resistor between taps. I don´t know why aren´t showed.
Anyway, here again
7139

Let me see the excel sheet tonight in calm.
Regards.
Horacio.

forty-2
10-16-2012, 12:08 AM
I couldn't find any 1/8" cables to sacrifice, so sketched up a quick simulation / schematic.

I'm assuming 2k between adjacent poles (though I'm reading closer to 1.75k), and the wiper is shown as a potentiometer between 270° & 360°

My first thought didn't work, because of a glaring error - the grounds; one adjacent pair will always be at the same potential:
7136

However this approach shows promise:
7137

The scope confirms that the phase on the wiper shifts as it's moved.

7138

YES! I can mock this up in Max/MSP using 4 audio outputs towards the end of the week. Then the question is: how do we do this in hardware?

Cheers,
Paul

hyamesto
10-17-2012, 03:03 AM
Ok, the images seems to be fixed right now. (not my fault).
Maybe you not understood my reply.
The original operating of the instrument is based on signals (sinus and cosines). It´s just for your information.
I have a simple description (in spanish, sorry) of the diagram of operation. (wikipedia can give you an idea but very faint)
(Just search "VHF omnidirectional range")
In real life, the equipment to check the operation, its a signal generator with differents types of outputs. (serves several instruments, like adf, ils, etc)
Anyway, your approach with audio signals is like the original operating of the instrument, but not practical for doing in hardware.
(Four sinus generators, to much, and another circuit for phase-shift measure).
The approach to using four analogs inputs is like an idea I had long ago.
But.... (why ever there is a but....)
If you look the internal potenciometer (photo and diagram), you can view a very strange connections.
The internal resistance between taps are diferents. (1.82k and 2.43 k).
Why the order of the taps is ilogical? I don´t know.
I expected
0º (yellow), 90º (brown) 180º(red) and 270º (orange),
but the photo and the diagram shows you
0º (yellow) - 270º (orange) - 90º (brown) and 180º (red)
71457146
The orange wire in the photo is missing (photo is not of my instrument, but when i open mine, is the same, with all the wires in the same order, like the original squematics).
The wipe (green cable) go from 0º to 270º it´s ok, but why from 270º to 90º or from 0º to 180º? The logical dictates 270º to 180º, or 0º to 90º.
Anyway, deducting a function of the excel its complicated (i´ve tried using polinomics, but without luck). Maybe a fourier series.....but is beyond my knowledge.
Sorry for the long and late reply, (a big thunderstorm in my city, let me without electricity, internet, water...)
I hope I've helped...I'll keep experimenting in others alternatives (like 2 opposite common linked pots with limit removed and slave in sync with the OBS card, like the simkits approach)
Keep in touch.
Horacio.

737NUT
10-17-2012, 09:36 AM
I can tell you what I did,I split it into 2 pot inputs to my oc card. One counts up 0 to 180 and the other down from 180 to 0. By using SIOC I was able to take the inputs, add them together,then subtract 360 and I got it to work very well. The only minor issue is if you turn it to fast while passing 180 or 0 it looses track. I just make sure I turn it slow when at the the poles. :)

Rob

hyamesto
10-17-2012, 11:24 AM
Why the order of the taps is ilogical? I don´t know.
I expected
0º (yellow), 90º (brown) 180º(red) and 270º (orange),
but the photo and the diagram shows you
0º (yellow) - 270º (orange) - 90º (brown) and 180º (red)
71457146

Horacio.

:oops::oops::oops::oops: Why? I answer myself. Ohm´s law. Parallel resistance between 0º & 90º < 0º & 270º or 0º & 180º.:mrgreen::mrgreen::mrgreen:

hyamesto
10-17-2012, 11:28 AM
Rob:
Have you used some external resistor between oc card inputs and the instruments?
Maybe can you make a squematics?
Thanks in advance.
Horacio.

forty-2
10-17-2012, 10:53 PM
Horacio -
woah, sorry you were without water & electricity! I was just traveling for work, and happy to be back home!
Yeah, I'm familiar with the real-world operational details, and yes, you're right that doing what I did in the schematic simulation would be a pain to do in hardware (but a fun challenge!).

Rob - Thanks for chiming in! Sounds like you've got a simpler approach, and like Horacio, I'd love it if you could share a schematic. I can almost visualize it, but it escapes me.
thanks!

forty-2
10-19-2012, 11:40 PM
Rob,
Are you using the same gauge as we are? I tried the approach I think you described and I finally realized something: The distances between the numbers on the gauge isn't linear.
30 to 60 is less then 0 to 30. In fact, it appears that 30 to 45 is the same as 0 to 30. This pattern repeats around the dial, you can see it in my first photo.
Is this why our purely DC resistive approach isn't working? probably?

hyamesto
10-20-2012, 01:26 AM
Paul:
I just finished a test with new wiring, the results are quite promising, but it's late here in Argentina. Tomorrow I send the new wiring diagram and excel sheet with the results. Apparently, the answer is almost linear, and excel can calculate the formula.
Be patient.
Greetings.
Horacio.

hyamesto
10-20-2012, 04:16 PM
New wiring.


7171

Resistance connected to two analog inputs of 8 bits (256 steps each one).
7168
Try this with your instrument. If we share the same or similar curve, we can continue ......A
Excel file:

forty-2
10-23-2012, 08:37 PM
Horacio -
sorry for the delay. Nice work! I wired up as described and got the same curve:
(will it show up inline, who knows!)

Looks like we might be wired slightly differently, since mine is essentially upside down from yours, but the curve is the same, so that's what's important.

I never took mine apart like you did (well I did, but I put it back together), so I'm wired up directly to the terminals:
0° N/C
90° Input #1
180° Ground
270° Input #2

Now I see what Rob was talking about: Looking at one input for 1-180, and the other for 181-360.
Spreadsheet attached as well. I'm going to poke around in Max/MSP a bit more (its just the fastest dev environment for me) and see if I can come up with some math that makes everything line up.

Cheers,
Paul

hyamesto
10-23-2012, 11:29 PM
I just finish a new alternate wiring. The same curve here, but by mistake, in another test, I put direct 4.5 volts between 90 and 180 inputs.....
Burn the resistance, and now the inputs are unbalanced. I cannot get the original ohms between taps. The curves are erratic, and I think the instrument is now destroyed.... .:cry:
I will try to open and check, but i don´t hope happy results...
Be careful with your´s instrument.
Learned lessons:
The curves are really difficult to calculated by a simple function, (i tried lineal, quadratic, polymodals.... and ever give me an error of 2 to 5 degrees) Too much for the OBS. And the analogs inputs are very sensitive (never a fixed number, ever jumping from one to another in proximity). I go back to use an encoder, and a stepper, like the first design made a long time ago. (and works fine!!)
Let me know yours advances. maybe in the future,i can find another Vor like this. Good Luck. and remember, i´m always to help you.
Horacio.

forty-2
10-24-2012, 01:13 AM
OH NO! So sorry to hear it got toasted! At ~2mA, damn...
after subtracting the two, I was able to get within 3 - 5 degrees from 0° - 90°. then it flips back @ 90° & again @ 270°. The 'lump' in the curve coincides with the varying spacing around the dial (surely by some electrical math beyond me).
7194
It is jumpy, I haven't tried cleaning the contacts, that will help, but it would still need some smoothing in software anyway. Honestly, I'm kind of OK with 3 -5 degree accuracy for this piece: It'll be 'close enough' for NAV2, and it IS almost 50 years old, so I'll give it some respect ;)

Were you able to find an equation that turned this into a continuous line? I can't figure out how to straighten this out to a 0 - 360 without using a series of IF THEN functions.

All the best,
Paul

hyamesto
10-25-2012, 11:50 AM
I´m working with your excel file. Give me some time. And good news. I find the broken connection in my VOR, an maybe i can fix it.
Keep in touch.
Horacio.

hyamesto
10-26-2012, 05:27 PM
Paul:

Here is your´s last excel file, with my notes.
The function calculated for your instrument is:

A=VALUE OF 90 TAP
B=VALUE OF 270 TAP
C= VALUE OF HEADING (OBS)

IF A=B AND A= 200
THEN C=0 (for exact value)
GOTO END
ELSE
IF A=B AND A= 100 THEN C=180 (for exact value)
GOTO END
ELSE
IF A>B
THEN C=-1,841B+368,25 (with 200<B>100)
GOTO END
ELSE
IF A<B
THEN C=1,8505A-8,7421 (with 200<A>100)
END

The max error is about 4,5 or 6,28 degrees. (check excel).
Regards:
Horacio.

hyamesto
11-04-2012, 01:51 AM
Paul:

Any advance with the instrument and the function posted?
Regards.
Horacio.