Results 1 to 5 of 5
Thread: Digtal to Analogue Gauges

05072010, 01:34 PM #1
Digtal to Analogue Gauges
I've thought about how to get the analogue instruments to operate.
These "vu Meters" are easy to find and do not cost so much. We will use digital outputs to control the needle up and down.
3 outputs corresponding to 8 steps.
4 outputs corresponding to 16 steps.
5 outputs corresponding to 32 steps.
6 outputs corresponding to 64 steps.
7 outputs corresponding to 128 steps.
I'm used three outputs for these test.
How is it done?
1: Find out how much resistance there has to be in series with your analog gauges for it to show 100% of full voltage.
2: Let us assume that resistance must be 20 Kohm.
Then the total resistance of all six resistors together must be 20,000 ohms. All six resistors is the same size, therefore one can calculate the resistance for each resistor, because we know that the amp / flow through R1+2+3+4 is one time, through R5+6, two times and through R7 is 3 times, and overall, the amps is 6 times (1 +2 +3). Ohm law: volt = amp x resistance
3: Where we have only one resistor we know that we have only 50% of the total amp power. Therefore, the resistance must only be the double of the resistance. Therefore, 20000 x 2 = 40,000 ohms, so each resistors are 40 kohm. Or 6 x 20Kohm / 3 = 40 Kohm
Diagram
You can of cause select R1+2+3+4 as one resistor (4 x 40Kohm) 160 KOhm
(If you want to use the four outputs, you must count the total amp power 1 +2 +3 +4 = 10
The last resistance must then pull a current of 4 out of 10 10 x 20000 / 4 = 50000 Ohm)
The script for 3 output kontrol:
Var 1100, Link IOCP, Offset 2750 // Get APU RPM 0  80% IOCPServer beta offfset
{
IF V1100 < 2 // meter 0%
{
V1101 = 0 // Output 1
V1102 = 0 // Output 2
V1103 = 0 // Output 3
}
IF V1100 > 4 // First needle movment 17 %
{
IF V1100 < 10
{
V1101 = 1 // set 1
V1102 = 0
V1103 = 0
}
}
IF V1100 > 9 // Set 33 %
{
IF V1100 < 24
{
V1101 = 0
V1102 = 1 // set 2
V1103 = 0
V1104 = 0
}
}
IF V1100 > 25 // Set 17% + 33%
{
IF V1100 < 40
{
V1101 = 1 // set 1 +
V1102 = 1 // set 3
V1103 = 0
}
}
IF V1100 > 39
{
IF V1100 < 53
{
V1101 = 0
V1102 = 0
V1103 = 1
V1104 = 0
}
}
IF V1100 > 52
{
IF V1100 < 77
{
V1101 = 1
V1102 = 0
V1103 = 1
}
}
IF V1100 > 66
{
IF V1100 < 90
{
V1101 = 1
V1102 = 1
V1103 = 1
}
}
}
Var 1101, Link IOCARD_OUT, Output 11 // 17 %
Var 1102, Link IOCARD_OUT, Output 12 // 33 %
Var 1103, Link IOCARD_OUT, Output 13 // 50 %
__________________________________________________________
http://www.md80project.dkSincerely,
Claus

Post Thanks / Like  1 Thanks, 0 Likes, 0 Dislikesskino thanked for this post

05072010, 03:07 PM #2
 Join Date
 Jan 2007
 Location
 NEW ZEALAND
 Posts
 878
Re: Digtal to Analogue Gauges
Hi Claus,
Nice to se a different approach.Im using a a PWM to 5vdc converter for my Analogue gauges.This is run from a Servo card.
Thanks for opening my eyes to a simple method not thought of.
Les

05072010, 03:27 PM #3
Re: Digtal to Analogue Gauges
You could also use a simple potentiometer, and servo, and usb servo card. 05V output for less than 10.00!

05072010, 03:43 PM #4
Re: Digtal to Analogue Gauges
Sincerely,
Claus

05072010, 04:35 PM #5
Re: Digtal to Analogue Gauges
This is a good idea. I already thought of it.
But a different (crazzy) variant found:
On a old small monitor, many white squares arranged on a small Fsuipccontrolled Program and controlled so that the square is brighter, the larger the value is passing the wanted. Possible 256 steps. For the engine temperature. could mean, value 0 = black square.
Value = 128 square gray and Value 256 = white. I think the principle is clear. To get these values to now the rebuilt Hardwaregauges on the screen is a mask attached and exactly where the squares are a photo resistor is appropriate, the value directly decouple (via a variable resistor for the oaks and a diode to) on the meter exist.
It is important to use a very stable voltage source, because otherwise arise measurement error. I work with 6 ads in test mode, all of which are powered by a Nokia Mobilphone Charger. Since almost no power is drawn the charger works very stable and remains cool. If however hold out for long is debatable. But that's what finished laboratory supplies or something.
The photo resistors are used by me for the recording of all 256 brightness values do not enough sensitivity. I can read about 120150 steps and I have therefore limited to 100 steps.
Here's a picture of the still very experimental control software. Next to each
'Control square' is a slider with which the value by about 10% above and below can be corrected.
Similar Threads

Levers: Analogue Vs Digital
By tomcat78 in forum I/O Interfacing and HardwareReplies: 4Last Post: 11072010, 12:13 PM 
Matrox TH2go Analogue being sold
By richard hutchinson in forum Cockpit Outside VisualizationReplies: 0Last Post: 09192010, 05:16 AM 
analogue software gauges, anyone?
By stabell in forum General Builder Questions All Aircraft TypesReplies: 18Last Post: 10232008, 07:22 PM 
DH2GO/THH2GO Analogue or Digital?
By Drewsta in forum Cockpit Outside VisualizationReplies: 6Last Post: 06282008, 07:32 AM 
Analogue output?
By MalcolmH in forum FS2Phidget UsersReplies: 8Last Post: 12022004, 02:57 AM
Danny, I would first try it on a direct port. Your hub needs to be powered by a high current 5v...
OC USB OUTPUTS CARD