View Full Version : Everything ready to building Ilyushin Il-62
Qwseyvnd
01-07-2014, 10:12 PM
Hi to all everyone users in this forum.
Now I have prepared everything; now I am ready to building Ilyushin Il-62 cockpit.
I have been ordered some items to Arduino such as stepper motor, slider potentiometer, 4-digit 7-segment LED digit, 2 buttons, 1 breadboard, 1 H bridge, DC Barrel power, 1 Voltage Regulator to making a prototype of instrument.
It will be interfaced with Arduino and X-Plane.
:)
Qwseyvnd
01-07-2014, 11:36 PM
This is my first picture. 8511
GPreddy
01-08-2014, 05:10 PM
It'll be great to see someone build a Russian aircraft! Good luck, and keep us posted!
Steve
Qwseyvnd
01-08-2014, 05:41 PM
Of course I will updating this thread.
Qwseyvnd
01-08-2014, 07:09 PM
A small update.
8512
Qwseyvnd
02-07-2014, 04:24 PM
An small update: I am still waiting for the mail from USA.
Qwseyvnd
03-04-2014, 09:39 AM
I got the mail.
Shawn
03-04-2014, 09:02 PM
I love the updates, a little short on content but packed full of enthusiasm. :p
Qwseyvnd
03-05-2014, 06:34 PM
87728773877487758776
Paul Thomas
03-06-2014, 03:27 PM
Not Ilyushin IL 52 but ....... http://cgi.ebay.ca/ebaymotors/TU-95MS-Soviet-Bomber-/121288805711?forcev4exp=true#ht_4974wt_1275
Qwseyvnd
03-14-2014, 08:39 AM
Minor update: I ordered a too strong stepper motor that requires 1.7A; so when I have money, I will order a stepper motor with less than 1A.
Shawn
03-14-2014, 01:20 PM
I ordered a few RC servos to attempt to build a simple gauge using the Arduino mega. I have no idea how it's all going to work but will be following your progress as you go to try and learn with you.
Shawn
Perik
03-14-2014, 03:22 PM
Hi Qwseyvnd.
I suggest you go to a Computer Dump in your area and pick up
a few Laser printer / scanner etc and you'll soon have more than
enough stepper. A HP Laser have usually 5-10 steppers - maybe more
and in many different sizes. Small steppers you do find in CD/DVD players and desktop scanners.
I've collected over years all kind of equipment I may need in the project.
If you live in Oslo area I can help you with a few :-)
Qwseyvnd
03-14-2014, 05:00 PM
No no, you don't understood. I need stepper motor because some gauges go more than 360 degrees. For example, altitude.
Qwseyvnd
03-23-2014, 04:21 AM
Now the 1/16 stepper motor and two potentiometer is reached :)
Qwseyvnd
04-06-2014, 08:33 PM
Just since thursday to yesterday, I were in Berlin; there I took photos of Il-62' cockpit which contains instruments and measurement that i noted on the paper. I took exactly 139 photos. Also I bought three pieces Darlington Array "ULN2004AN" and four pieces rotary switch, it is for prototype. When I am finished with the necessary, I will order 3 switch CNC.
Qwseyvnd
04-07-2014, 10:32 AM
A small update.
I have been bought four pieces of rotary switch and three pieces of darlington array ULN2004A.
Qwseyvnd
04-07-2014, 06:55 PM
Finished to putting parts on a breadboard with wires to the Arduino Mega 2560. It is a prototype item. Soon I will make a tape with number from null to nine, 0 -> 9 then paste it to the liverpate cylinder item.
9022
Qwseyvnd
04-12-2014, 05:03 AM
Soon finished to printing almost 725 pages of Il-62M documents that including aerodynamics and system.
Qwseyvnd
04-13-2014, 11:27 AM
Argh, I must replace the printer again because this is damaged again.
I want to say that if I sell this home cockpit, I will not provide the source code that I has programmed; otherwise, I must publishing it in online by arduino license. I do not wish because of security reasons of myself which that I am sick with a diagnose that is schizofreni. And, I do not want that it will be using to unlawful situations. So I will just sell to a private person for hobby using or a foundation that can running it. The worst fate if I become misunderstood by other and suspected.
The full story of the reason: I became sick in the U.S. and I saw a lot murder, blood, war, dead people that arise, unknown persons, persons that came from no place, etc. In 2012, I got a ESTA visa waiver without any problem; but in 2013 I got problem because I thinking by that of what I have wrote in the internet so the U.S. discovered. Then I sent an e-mail to the american embassy in my country and asked. They replied that I must travel to the embassy and make an application, etc. Everything just because of this Satan and his image 666 and he destroyed everything in six days.
I hoping that the community understanding me.
Qwseyvnd
04-14-2014, 07:40 AM
Now I am learning about the processor power and bits of information because I need to measure how much processing power I need. I see that I need least 32 bit processor.
And I learn the X-Plane SDK to find out how much precision in altitude, speed, measure of each movement, fuel measurement in decimals or whole number, and such.
Qwseyvnd
04-18-2014, 05:19 AM
Now I have been calculated a part, it seems I need between 16 and 64 kilobyte memory.
Qwseyvnd
04-18-2014, 05:52 PM
Now I found that using an external processor such as AVR, PIC, ARM, and such will might be slow. And, using USB port will maybe result difficult programming. So, in conclusion, I will use an OpenGL 4.3 graphics card. I will use for example four pixels to run a stepper motor, one pixel to a switch, etc. It is much easier to programming that than to use USB to an external computer with its own processor. That is usually slow eight bits or 16 bits processor with few pins. I will use RJ45 between pins and motor and such to make it easier to remember which wire shall connect to. One RJ45 has 8 pins which is enough to drive two stepper motor in each gauge. An example, throttle gauge shows two different values in two needles.
Qwseyvnd
04-18-2014, 05:57 PM
I will use this: http://www.prisjakt.no/product.php?p=1285192
Zotac GeForce GT 620 Synergy EditionWhich has OpenGL 4.4; it is perfect because I has an Official Guide by Khronos Group version 8, let me check...The name of the title: OpenGL Programming Guide, Eighth Edition. The Official Guide to Learning OpenGL, Version 4.3. ISBN-13: 978-0-321-77303-6.
Qwseyvnd
04-26-2014, 06:36 AM
I have researched more. The DVI cable cannot reach long range, so I will trying to use some pieces of Arduino or make my own small interface card for that.
Qwseyvnd
04-27-2014, 04:17 AM
Small update...
I cannot find out how to programming a decent stepper motor. I am novice in programming.
Perik
04-27-2014, 06:51 AM
Hi
Without any or very little programming experience you seem to have set up
a very optimistic plan for your build. Homemade stuff will in most cases require both
interfacing and programming skills plus a lot more ;-)
For Arduino and stepper you could start looking at at this thread:
http://www.mycockpit.org/forums/showthread.php?t=27379
though still expect a lot of programming but you are not alone ;-)
Another and may be the easiest route to follow for a novice in programming
is OpenCockpits stepper interface:
http://www.opencockpits.com/catalog/electronic-cards-iocards-stepper-motors-c-21_33.html
http://www.opencockpits.com/uploads/manual_usbstepper_eng.pdf
Here is a nice review of OC stepper interface:
http://mutleyshangar.com/reviews/jack/smc/smc.htm
You'll still need to learn some SIOC programming but it's not too difficult.
OC has more or less a complete range of I/O hardware and is a solid
platform for a custom-built simulator project.
Qwseyvnd
05-05-2014, 04:01 PM
Update:
I am tried to getting a potentiometer with unipolar stepper motor to run. It was not a successful experiment.
Qwseyvnd
05-05-2014, 06:19 PM
I see that I cannot upload a fritzing file.. I will upload one screen picture with fritzing picture.9150
Qwseyvnd
05-09-2014, 04:38 PM
Update:
I ordered the programming book C++11 written by Bjarne Stroustrup.
Qwseyvnd
05-09-2014, 09:10 PM
I tried to programming to run the motor as a prototype but now I thinking that I destroyed the ULN2004AN so I will trying a simpler to programming with.
Now I will programming 4 encoder switch and two buttons. How it works: encoder switch will store the kilometer counting of X and Y.
The buttons will choose 1, 2, 3, 4, 5, 6, 7, 8, 9, or #10 waypoint.
So the 7-segment, which is an prototype of stepper motor.
The first programming will show how long it shall run to reach the waypoint in straight way up to 200 km, if I reach 200 km, it will count to negative so I must turn the airplane 180 degrees.
At a later point, choose waypoint #1 to 10 in use which is SID and STAR. Basically it is a map of X and Y coordinate with limit 400 km X and Y. Also, #5 to #10 can be a rectangle of 5 waypoints that is go-around algorithm.
Qwseyvnd
05-10-2014, 07:21 AM
I will explorer how to connect X-Plane SDK with pins on an arduino card, or equivalent.
Qwseyvnd
05-10-2014, 07:39 AM
Update:
I will connect resistor at serial from #1 to #2 rotary encoder with X and Y coordinate to just one pin on an arduino card; so, it will be eight different values to read. I got this idea from a person who made a switch with resistor to just one pin on the interface item.
I will have 20 rotary encoder to connect with; so it is 40 values to read in each 1 byte. 1 byte has 256 different values to write and read! So, there is a lot more to put in.
Qwseyvnd
05-10-2014, 03:40 PM
Update:
I do not find 39 pieces of low Ohm. The requirement below 40 milliAmps and 5 Voltage. They shall be connected serial.
Qwseyvnd
05-13-2014, 08:25 PM
5 Volt
40 mA
125 Ohm
19 resistors, not 39.
6.2 Ohms each and 2 watt each. Thus, it is 38 watts to provide, correct ?
Perik
05-14-2014, 01:57 AM
Hello Qwseyvnd
First of all I’m unsure what you are trying to achieve.
Are you planning to connect a resistor ladder to an A/D input on the Arduino?
And when you talk about Rotary Encoder – do you mean an 8 positions Rotary switch.
Look here for some component overview: http://www.737ng.co.uk/components.htm
and this page for some more technical stuff: http://www.737ng.co.uk/technical.htm
Ian has many well written articles about different topics like this one:
http://www.737ng.co.uk/autobrake.pdf which may be close to
what you are looking for.
Please supply schematics / drawings to visualize what’s in your mind…..
And it would be nice to know the layout and function of the panel/flight
instrument you are about to make….
Qwseyvnd
05-14-2014, 03:26 PM
Well... to understanding me, try PT Il-62M freeware addon for FS2004, then try to navigate it in flight simulator, then you are understanding what I am trying to expression about the upper panel black box on the navigation panel. I have been searching in Youtube but found not any good video that illustrate the navigation system.
I have roughly 1700 pages about this airplane.
Perik
05-15-2014, 02:11 PM
You are a brave man, Qwseyvnd.:D
I don’t have access to FS9 so I'm unable to try the Il62.
I would never touch such a project without a lot more technical
documentation available - at least if you plan to go real.
It’s a huge project with a lot of coding and manufacturing.
First of all you should check with the guys behind the PT Il-62M code and ask
if you can have access to the entire package or if they can write an SDK for you to
talk to / from your own interface code. They could maybe use FSUIPC offsets.
A key point here is how well the PT Il62 system internals are simulated.
If you don’t have access to those or they are badly implemented,
then you need to write your own system logic – impossible without
detailed acknowledge about operations and access to technical manuals....
For your specific question about the X and Y input I think I would go for ordinary
encoders. Do you know if the Waypoint buttons are latched or just
momentary and can you push and activate more than one button at a time?
BTW - Nice panel…..
http://www.jetphotos.net/viewphoto.php?id=7436220&nseq=1
And how do you plan to operate this aircraft as a single pilot or are you part of a team?
And what about the Russian language? :-)
Qwseyvnd
05-15-2014, 08:00 PM
9180
As you see, NV-PB gets the airplane direct to waypoint, as you see, for example, X coordinate might be minus 20 km, Y coordinate might be plus 250 km, and the flight heading must be 200 degree heading or more or less depends on where I began to departure at the point of earth. Or same system with the GO-KR panel, which I shall made 20 rotary encoder with 19 resistors, it gets the airplane from runway or ADF, VOR or RSBN station to use km correction directly to waypoint with calculation where the heading must be and counting kilometer to zero at the waypoint. If the airplane does not use correction, the deviation might be +-10% in 7000 km oversea. By that, that's actually a simple computer inside that without advanced such as FMC but supplied with magnetic variation, doppler, and some other items that is explained in the document. There is a option to add INS-21 computer glonass system which is similar to Intertial navigation syste,.
Qwseyvnd
05-16-2014, 10:28 PM
A BIG update:
Might I planning to build my own computer with Zilog z80 16-bit processors which I will provide maximum 1750 watt power supply.
Roughly specifications:
256mb hard drive which will provide terrain mesh and some airports and visible runway and such. No support for texture, so I will use green for country, desert in some areas, white snow, line snow and rains instead pixels, black runway, white markings on runway, a few lights so I can see that it is night, 4 bit filtering set at day and night, blue sea, visible sun and moon, triangle clouds. Maybe traffic if it is possible. I will not promise a lot because change fast.
Shawn
05-16-2014, 11:25 PM
Well, even though I don't really understand exactly what you are doing I am finding your updates extremely interesting. Please try and post more photos when you start to get things pieced together.
Cheers
Shawn
Perik
05-17-2014, 03:50 AM
Hi Øyvind
Interesting move…:mrgreen:
As Shawn I’m unsure where you’re going.
It seems you’re on a different planet than the rest of us so please make up a
bigger picture of what’s in your mind – not just fragments. It’s very confusing
trying to follow your path jumping from one planet to the next….
BTW – Z80 is an 8-bit processor (not 16) and I think I still have a few samples
around and a copy of CP/M operating system (back from 1976) if you need.
But you’ll need an 8” Floppy drive.;)
Qwseyvnd
05-17-2014, 11:20 AM
Thank you. I will buy new which is listed on Digikey.
I am calculating this
16-bit, not 8-bit because of 640*480, 16 cores of z80, 8 MB RAM and 18 MHz * 16 = 288 MHz. That should be enough to drive the system engine with some limits, workaround, and tricks. The MIPS is about equivalent as Pentium Pro at 175 MHz. I thinking that I will use Displayport for such and it will be black and white colors, But if I am able, trying 256 colors depth. Where to find Displayport interface ?
Watch this video
https://www.youtube.com/watch?v=CaK0-V9_7Hw
This looks a lot better with just 64 kilobyte executable than Playstation 4 with 8 gigabyte RAM with vector.
The cause:
http://stackoverflow.com/questions/6081368/64kb-demos-how-do-they-work
They generate their content procedurally. i.e. they don't add 3d models, bitmaps, sample based audio-files,... but generate that from code or some low detail representation.
I know what they are using.
nVidia NV1 which is STG-2000 has processing power 350 MIPS. The z80 at 50 MHz processes 80 MIPS, multiply it with 12 for 18 MHz. 4 cores left for 50 MHz each, it gives 320 MIPS which is equivalent to Pentium at 170 MHz.
I thinking that the full flight simulator that is provided in '80s has slightly modified processor unit and they might are multi-core.
But first, I will try that on X-Plane. z80 project comes afterwards because I want to complete it with X-plane because it is a future project that updates regular, which my z80 will never update and it will be a stand alone flight simulator and no more. I have the documents about the aerodynamics on the Il-62 which I downloaded from the internet. With the height data, I will have ASCII file SRTM data into generate code such code, that's what I am thinking to do.
Qwseyvnd
05-17-2014, 12:40 PM
I am watching z80 because I do not know how to work with SDK with the instruments. So, I thinking, why not make a stand-alone application. And, it is difficult to learn to program USB, and whatever I have to do almost everything from scratch, but not with rendering engine and physics engine; therefore, I thinking why not programming a stand-alone application based on the documents that I have.
Qwseyvnd
05-19-2014, 10:44 PM
I examined to build CPU for flight simulator would take too long.
Qwseyvnd
05-20-2014, 07:23 PM
Update:
I explored about graphics processing unit with displayport.
NVIDIA support team said that it is possible to use displayport to control Stepper motor, switches, LED diodes, rotary encoders.
Qwseyvnd
05-20-2014, 10:11 PM
Update:
I have been sent e-mail to VESA about datasheet for displayport.
Qwseyvnd
05-22-2014, 05:27 PM
Update:
I have been bought a new laptop because if I upgrade my old laptop from 2010, it would cost about same including the risk.
The new laptop costs roughly 950 dollar,
If I bought new laptop with same specification as the old laptop (ASUS N73Jn), it would cost 4500 kr with guarantee and new but N73Jn is used so it is half price of new. So it does not matter. The laptop that I have been bought, I will using to programming plugin and such, just for experimenting use for X-Plane.
Qwseyvnd
05-25-2014, 08:47 PM
Update:
I thinking that I need to live in Germany for a while because they have a lot of electronic items in physical shops. It is easier to buying in a physical shop because there I can communicate personally, etc. I can live in Germany up to half year yearly because I am living at permanently disability pension.
Soon a new update.
Qwseyvnd
05-26-2014, 06:55 PM
Here's update.9190 I have asked the Arduino forum if this is correct build in the schematic design.
Qwseyvnd
05-26-2014, 10:07 PM
The first successful stepper motor example one revolution, which it spinning but the motor does not go around.
Soon I upload an image.
Qwseyvnd
06-12-2014, 07:52 PM
I have been tried in Arduino Forum without big success, so I trying here.
I have an Arduino MEGA2560, 4 rotary encoder for experiment use; in final edition, I will have 20 pieces to use. I want to have 19 resistors to connect them chains from #1 to #20 to just ONE analog pin which is on MEGA2560.
I know that this card operates at 5 Volt and each analog pin can tacle up to 40 mA; thus, that is 125 Ohms. Is that correct, 6,2 Ohms multiply with 19 to getting 117,8 Ohms?
How much power do I need?
In Digikey, I see that I find just, JUST, one resistor with 2 watts and the tolerance is +-1%; so, I need 38 watts ?
Qwseyvnd
06-12-2014, 08:04 PM
Finally I found a way form showing just the same I think.
http://www.microchip.com/forums/download.axd?file=0;694632&where=message&f=1pin%20keymatrix.gif
http://www.microchip.com/forums/m694613.aspx
As you see, this just use ONE pin. Exactly what I am trying to do.
Qwseyvnd
06-14-2014, 03:48 PM
Update:
I am trying to understand voltage divider.
Qwseyvnd
06-14-2014, 08:37 PM
Successful made prototype for rotary encoder serial with the arduino. I haven't yet programmed in the IDE.
Qwseyvnd
06-15-2014, 08:00 PM
Now I have made schematic for the breadboard which includes two standard rotary encoder, which is correct set up. Now I investigate how to interface it with X-Plane SDK.
This function will works that if I turn X or Y, it will make a coordinate point from origo point which can be an airport, then the airplane turn and run to this waypoint/intersection. It is the first prototype; then, I add 9 more with each two rotary encoder which is the complete part of navigation panel.
Qwseyvnd
06-22-2014, 01:40 PM
Update about toggle switch
In the Arduino forum, they said it is not possible to have binary toggle switches in one analog pin; but it is possible if I using 3.3v and 5v to make more possiblities.
In the thread I made, one user who wrote said: "Even in real life they must have been a nightmare to wire up."
I have a lot of free time.
Qwseyvnd
06-22-2014, 01:42 PM
What I achieved with Arduino card:
- How to set up stepper motor
- How to set up led
- how to set up two rotary encoders.
- How to set up two toggle switches.
Now I need to investigate the SDK.
Qwseyvnd
06-23-2014, 04:43 PM
From start until now were a lot of technical paper, now I am doing electronic.
Qwseyvnd
07-08-2014, 01:04 PM
Arduino Due
NV-PB 8 *4 stepper motors 32 32
RSBN/VOR correction 5 *4 stepper motors 20 20
52 pins use for Due.
Arduino MEGA2560
LED lys 6 6 6
Brytere 11 11 6
Kompass stepper motor 6 *4 stepper motors 24 24
GO-KR 10 *3 30 but using 5 pins
RSBN/VOR degree/km 2 *4 stepper motors 8
49 pins use for MEGA2560
With the SAM3X8E processor from Atmel, based on the 32 bit ARM Cortex M3 architecture running at 84MHz item, I will using it to calculate navigation if 84 MHz and 96KB SRAM are enough for that.
Qwseyvnd
07-21-2014, 07:16 PM
Update:
I have ordered electronics for circa $ 400. It is for navigation which is necessary to make a necessary system for prototype.
Qwseyvnd
08-01-2014, 07:06 PM
938693879388938993909391
Avro748
08-01-2014, 11:31 PM
So you're going the Arduino route, interesting...
Can't wait to see this thing unfold.
Qwseyvnd
08-09-2014, 12:56 PM
Now I have completed circuit on breadboard with eight rotary encoder and four buttons to start with; it is to store XY coordinate to use such with SID/STAR or a waypoint near the airport.9443
Qwseyvnd
08-15-2014, 11:13 PM
Update: Will using Blender to display some necessity visual instruments for prototype test to test the breadboard prototype before I am buying the CNC machine because it is not necessary to spend 10.000 kr NOKfor this item before I am sure to do.
Qwseyvnd
08-16-2014, 09:09 AM
Update:
9454
I made this because I need to test the breadboard with visual that it works before I am going to buying CNC to build navigator panel.
Qwseyvnd
08-16-2014, 06:11 PM
Came further.9456 Now it is just for to test rotary encoders, buttons, and LED lamps, and toggle switches. At a later point, I will buying CNC machine to making DIY instruments. Nowadays I am connecting rotary encoders, led lamps, toggle switches to test; when it is successful with this prototype counter, I will surely buying CNC machine.
Qwseyvnd
08-17-2014, 09:14 AM
Now I am investigate how to integrate X-Plane plugin with blender to get it working with prototype 3D models.
Qwseyvnd
09-18-2014, 04:01 AM
Now I have ordered a 6040 with 4th axis option.
Qwseyvnd
10-09-2014, 11:12 PM
Expected arrived CNC 6040 around 21. october clock 8 A.M. or P.M.
Qwseyvnd
10-09-2014, 11:17 PM
Today I will go to a metal scrap company and asking where to buy metals.
Qwseyvnd
10-17-2014, 09:45 AM
CNC machine arrived.
Now I have been bought 1.5 kg thin copper wires, 0,5mm thick; to be using for stepper motors. It costs 60 kr = around $ 9,16. The metal scrap company is just 25m away from where I live.
Qwseyvnd
10-18-2014, 07:03 PM
I must return the chinese CNC machine because it missing some important things, and I couldn't fit the CNC block on the board because it is 1-3mm too big.
Then I will buy a german quality CNC for $ 6800.
http://www.gustavsenas.no/default.pl?showProduct=17919&pageId=1288
Avro748
10-18-2014, 07:43 PM
Bummer.
Be careful about some of these wholesale Chinese brands, I haven't heard many good success stories from them around here. I can tell you're putting a lot of time and money into this; hopefully this other one will work better.
Qwseyvnd
10-23-2014, 04:18 PM
A good news, my dad fit it fine when he put this in horizontal position but I tried vertical which caused problem. Tomorrow I will assembly it; then, buy mill.
Qwseyvnd
11-01-2014, 08:05 PM
Some serious issues with this CNC machine from China.
I asked him questions which are compiled into one question: do you have the required competence to sell this item? He didn't replied clearly.
Amazon replied to me afterwards:
Important cite: I'm contacting our seller investigation team to make sure that this seller actions are investigated and if required banned from selling the items from our website.
Now I will buy the Step-CNC machine for $ 9.000 with #1 quality operating instructions!!!
I am deaf, which is enough life issue with deafness, and do not want to become a person with serious accident just because of a seller without required competence.
Qwseyvnd
11-12-2014, 08:48 PM
While I waiting he pay back money to me, if not, Amazon will return every money to me; I will trying to programming Arduino card with led lights as a prototype for the stepper motors. I will using one potentiometer that I have in available to behave as a ground speed to provide the X and Y coordinate.
I am very exciting about that!
BushPilotWannabe
11-14-2014, 12:13 AM
Hi
I think that I understand what you are trying to do. I have just finished rebuilding Jim's Multi_Radio_Project using three analog pins for all inputs. Rotary switch with an additional contact for a two axis autopilot select on one, Rotary encode and the built in push button getting four codes out, Increment, Decrement, Increment with push button, and Decrement with push button on another, and all of one single push button on the third. Eight or more additional pushbuttons will be added to this circuit after the current switch panel built for digital input is rewired.
But to run 20 encoders without push buttons on one pin may be expecing too much. Not that adding 20 push buttons would help. Believe me they won't. Although there is a thread mentioning the start of a project to put 50 or 100 encoders on one analog input. The Arduino ADC provides levels 0 to 1023, so 20 encoders with 40 channels (pins) would have 25 levels between channels and 41 small resistors (one on both sides to be safe) is theoretically possible. BUT, there will be a wide range of voltage or current supplied to the input for a short time. Is the Atmel ADC built into the chip that good? Finding the right resistor mix may be quite difficult. Oops forgot about the code. Once a change to the input pin is detected you will need 60 if statements similar to " if(((levelRead + ?) > measuredLevelForThisPin) && (levelRead - ?) < measuredLevelForThisPin))) { successfullyDetectedVoltageOnEncoderEightChannelB = true ; } Haven't run this for typos. Just reinstalled and updated my Linux partition and the Arduino USB cable resets the computer. Too lazy to transfer this over from the "web computer" to the FS computer. The "?" in the code will have to be found by trial and error. This code will trap a level near to what you observed with movement stopped. Conditions change during a hours flight. If the range is too narrow, all samples will be rejected. If it too wide you may catch the ADC moving between two samples.
Wiring the circuit to input 40 mA is not necessary. This is only signal current. The ladder for the rotary switch uses resistors R4 through R11 of a simple 12 resistor network of 4.75k resistors and this is in parallel with a 100k ohm external pull up resistor when the encoder contacts are closed. I don't know why whoever posted the keypad blog used a resistor network usually used for DAC (opposite to ADC) circuits. DAC circuits want to produce very even voltage steps. Will have to read more on the subject. The best news is this is a human input situation and much time may go by without using any encoder. AND while analog input is comparably slow, you do not have to read 40 digital inputs more than once to eliminate contact bounce. However with simple resistance ladders two contacts not intentially closed at the same time will really cause trouble. Both channels of the encoder will make contact half way through the quadrature cycle. This produces a new voltage divider somewhere between the voltage dividers for channel A and channel B. On multi encoder circuits if the results of this new voltage divider gets close to one for another encoder, resistor selection will be a real nightmare.
You have a posted a picture http://www.mycockpit.org/forums/attachment.php?attachmentid=9443&d=1407604119 with eight encoders and it looks like standard digital connection. Did you use the standard Rotary or Quadrature library for this assembly?
My general aviation radio stack project looks like it will need 7 dual function rotary encoders (dual rotary encoders if I can afford them AND find the right knobs) and around 28 pushbuttons. Will see how you are making out.
Bye
BushPilotWannabe
11-21-2014, 01:41 PM
Update. Have built a single encoder with attached perforated board 14mm x 18mm. (+) and (-) lines IN and one analog line OUT. Also breadboarded 10 rotary encoders with one analog line OUT. Both left / right and push left & turn / push right & turn are available. So far have written simple code for one encoder only so I do not know how fast the Arduino Uno will process the 60 level recognition instructions required.
This works using - full quadratic cycle between notch - encoders which unhappily may eliminate half cycle dual encoders. The rotary encoder can not remain in contact with the resistor ladder when stopped in a detent.
BushPilotWannabe
11-22-2014, 02:56 PM
EDIT. I was premature and overly optimistic in the performance of multi rotary encoders connected to a resistance ladder. Three maybe four encoders can be connected using the built in pushbutton as a separate switch or maybe one or two encoders can be connected using the push and turn function. This saves five or more pins not the twenty to thirty that I was wanting.
This works using "full quadratic cycle between notch" encoders which may, unhappily, eliminate half cycle dual encoders. The rotary encoder can not remain in contact with the resistor ladder when stopped in a detent. Other encoders or switches will pass analogRead levels not anticipated in the programming.
This has turned into a thread by itself. Sorry! I will post one when claims can be proven.
Qwseyvnd
12-30-2014, 02:24 AM
Now I have been ordered Heiz High-Z S-1000.
Qwseyvnd
12-30-2014, 03:51 AM
I want to inform to the users in MyCockpit.Org
I will try, probably promise if I can do that, to post the images of completed cockpit when it is finished; because I am too sick to have internet connected a lot in my apartment.