PDA

View Full Version : Airbus gauges for the MIP



TobiBS
03-02-2009, 06:18 PM
Hello Builders,

is there any place, where you can buy the two gauges, needed for the main instrument panel of an airbus A320? I talk about the clock and the brake pressure indicator. I know that the clock can be displayed via PM, but I thought about a full hardware solution via USB without any other hard- or software dependence (except for a self written interface).

I don't know a supplier for these gauges and the only reference for this parts I found were for the clock:
http://www.a320homecockpit.de/00000096221175917/00000096330b5b70c/000000981809c183b/index.html
And for the pressure indicator:
http://www.a320homecockpit.de/00000096221175917/00000096330b5b70c/000000983310ea712/index.html

I liked the idea with three small servos and therefore started to plan it, here is my intermediate model of it:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/Brakepressure_front.png
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/Brakepressure_back.png
If you like the faceplate, you can download a 1MP version of it from http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/faceplate.png or I can provide you a svg, if you like.

My question: Has any of you already built the gauge like this and has any advise? I currently have no good solution for fixing the needles on the servos except glueing, because I don't know how to get the gear wheel as a geometry in a needle. The interface can easily be done via a microcontroller, or with given solutions that are available on the market right now.

Well the other have of my project is the digital style clock, with at least the most important functions, first the pictures of it:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/Airbusuhr%20ISO%20vorne.png
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/Airbusuhr%20ISO%20hinten.png

Here also the question, I have seen that some of you use a monitor version of the clock, but I found no supplier or builder and the guy from the link in the introduction has not yet finished this clock. Is anyone out there, that already built this clock? I have big problems to find the correct display type, the 4 digit clock types are only available in green, yellow or white ones are produced, but it seems no distributor sells them to private customers.

Well I hope I get some replies on this and maybe you have solutions for any of my problems or at least some tips. If you want to get any more informations (preleminary circuit diagram or PCB-circuit layout of the clock or dimensions, drawings, etc. from any of the projects), just let me know.

Tobias,
Germany

Didrik
03-02-2009, 07:38 PM
Sorry for being as much OT as I possibly can but, what software have you used to build those prototypes?

TobiBS
03-02-2009, 07:52 PM
Sorry for being as much OT as I possibly can but, what software have you used to build those prototypes?
The whole CAD stuff is done in Solid Edge, the development of PCBs and the circuit diagrams are done with Eagle and the faceplate for the pressure indicator is done with Inkscape. I am then using the graphics or the PCB layout as a texture to represent it in Solid Edge. If you like to know more, feel free to ask.

TobiBS
03-19-2009, 04:19 PM
Even though, nobody replied on the initial topic, I hope I am not boring you with the progress of the gauges. I am doing the brakepressure indicator first.
I etched the PCB last week, soldered it yesterday and after some tests yesterday evening, resolderd it today. The result with one servo attached looks like this:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/PCB_V1-0.jpg

In the afternoon I tested the device, on the first hand there was a problem in my self written software, then with the external oscillator, but I managed to get it work and now the software reads out the values of left/right brake applied from FS, converts it to a servo position and sends it via USB to my PCB, which drives the servo, which looks like you can see in this short video (some braking applied with my pedals, therefore the movement is not very smooth):
http://www.mycockpitvideos.com/video/149/USB-Servo-Adapter-first-try

I hope you like it and I inform you after building the rest around it, if you like. If you have any questions, feel free to ask.

Kennair
03-19-2009, 04:36 PM
Hi Tobias, and welcome to the site. You'll never bore anyone here with progress on any portion of a simulator, that's what draws us here ;) You look like you're well skilled in CAD, PCB and code, which puts you well qualified to help many others here. Please continue to keep us posted with your progress, we love to see innovation so I'm sure there'll be many questions coming your way.

Ken.

TobiBS
03-20-2009, 07:39 AM
Hi Tobias, and welcome to the site. You'll never bore anyone here with progress on any portion of a simulator, that's what draws us here ;)
I know, was just kdding to catch attention,;)


You look like you're well skilled in CAD, PCB and code, which puts you well qualified to help many others here. Please continue to keep us posted with your progress, we love to see innovation so I'm sure there'll be many questions coming your way.
In CAD you maybe right, but to be honest this was the only third PCB I did in my life, first one was in school several years ago, the second one was an rather easy adaption from the Airbus 5-Pole XLR jack to jacks that can be connected to a standard sound interface, which only needed 6 resistors and 2 capacitors:

Headset:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/Headsets.jpg

Soundinterface:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/Audiointerface.jpg

So in fact it was the first real challange with this small SMD chips and stuff.

I keep you informed on the status.

TobiBS
04-01-2009, 02:02 PM
OK, here is an update of what I have done:

I redesigned the PCB to fit on a square of 50x50cm, I designed a second board in the same size to keep the inverter for the EL-foil in place. The base plate was done by our shop and the srews and distance bolts are standard parts.

The main problem were the small needles of the gauge, I wanted to make them from plastic with a CNC mill, we tried several options and at the end I decided to do the bottom first and then build a device to hold it while doing the upper plate.

OK, here are some preliminary report pictures:

Device mounted with a b/w faceplate below, not the best figures, wanted to use the worst one for the tests:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/real_front.jpg

Here you can see the whole device from the side, with base plate, interface PCB in the middle and inverter PCB at top:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/real_side.jpg

Finally a bad picture with my mobile phone camera, mounted in the panel without faceplate:
http://www-public.tu-bs.de:8080/~y0028089/Airbusparts/real_panel.jpg

A better picture of the finally mounted device will follow, when I am done with it.

brianwilliamson
04-01-2009, 06:31 PM
Thank you Tobias for this very interesting project. I will have to now add this to my list of future things to do !!
Cheers...............Brian W.

Matt Olieman
04-02-2009, 06:28 AM
WOW Tobias, nice to see this come to life. Job well done and inspirational :)

Matt Olieman

pdpo
04-03-2009, 04:12 AM
Hi there,

Any chance you might share with us the layout and parts list of the PCB
and some explanationm on how this works. Seems very interseting?

Greetz Peter

TobiBS
04-03-2009, 05:13 AM
Hi there,

Any chance you might share with us the layout and parts list of the PCB
and some explanationm on how this works. Seems very interseting?

Greetz Peter

Of course,

if it helps you and is not for commercial purpose, here it goes.

Here is the schematic:
http://www-public.tu-bs.de:8080/~y0028089/IFF/Interfaceplatine.pdf

It is rather simple, a FTDI FT232R does all USB stuff, so no worry about that, it is connected with a simple RX/TX interface to the Atmel Mega 8, which is the microcontroller that does all the work. The FT232R works in bus powered configuration, so we need no external power supply.

To get exact timing I am using an external oscillator with 8 MHz, despite that all is configured with a minimum of parts. The ISP connector is used to program the Mega 8.

The servos are then connected to 4 outputs of the Mega 8.

Here is the board layout, as you can see all parts are SMD, the only holes and drills are needed for the mounting and for the USB connector:
http://www-public.tu-bs.de:8080/~y0028089/IFF/Interface_Platinenlayout.pdf

To identify what goes where, here is the mounting scheme:
http://www-public.tu-bs.de:8080/~y0028089/IFF/Interface_Bestueckungsplan.pdf

and of course to identify what is what, a partlist:

Partlist

Exported from Interfaceplatine.sch at 03.04.2009 11:01:07

EAGLE Version 5.2.0 Copyright (c) 1988-2008 CadSoft

Part Value Device Package Library Sheet

AVR MEGA8-AI MEGA8-AI TQFP32-08 atmel 1
C1 10nF C-EUC0603 C0603 rcl 1
C2 47nF C-EUC0805 C0805 rcl 1
C3 100nF C-EUC0603 C0603 rcl 1
C4 100nF C-EUC0603 C0603 rcl 1
C5 100nF C-EUC0603 C0603 rcl 1
C6 100nF C-EUC0603 C0603 rcl 1
C7 4.7uF ELKO ELKO Bremsdruckanzeiger 1
ISP STIFTLEISTE STIFTLEISTE STIFTLEISTE Bremsdruckanzeiger 1
LED green LEDCHIPLED_0603 CHIPLED_0603 led 1
OSCIL 8,0MHz QUARZOSZILLATOR QUARZOSZILLATOR Bremsdruckanzeiger 1
R1 0 R-EU_M1206 M1206 rcl 1
R2 0 R-EU_M1206 M1206 rcl 1
R3 0 R-EU_M1206 M1206 rcl 1
R4 10k R-EU_R0805 R0805 rcl 1
R5 150 R-EU_R0805 R0805 rcl 1
SERVO1/2 STIFTLEISTE STIFTLEISTE STIFTLEISTE Bremsdruckanzeiger 1
SERVO3/4 STIFTLEISTE STIFTLEISTE STIFTLEISTE Bremsdruckanzeiger 1
USB USB-BUCHSEUSB-BUCHSE USB-BUCHSEUSB-BUCHSE USB-BUCHSE Bremsdruckanzeiger 1
USB2UART FT232RL FT232RL SSOP28 ftdichip 1


The Mega8 then needs a bit of programming and you need to have some software on the FS PC to communciate with the module. That's it.

Matt Olieman
04-03-2009, 05:31 AM
Nice info Tobias, thank you!

Matt Olieman

TobiBS
06-18-2009, 02:21 PM
OK, here is the final result:

http://www-public.tu-bs.de:8080/~y0028089/IFF/brakepressindicator.jpg

As you can see it is unlighted on the picture and therefore the white areas are some kind of pink, which is the color of the sheet if it is off. If anyone likes, I can provide pictures when lighted, hope you like it already.

pdpo
06-19-2009, 03:41 AM
Hi,

I had lost track of this post and saw it back today but I cant download any of the PDF files?

Greetz Peter

TobiBS
06-19-2009, 04:20 AM
I had lost track of this post and saw it back today but I cant download any of the PDF files?

Sorry, that was my mistake, I accidently deleted them from the server, I changed the links, it should work now, but I don't have the first pictures anymore, but I think the PDFs and the final result is enough, when I unfasten it the next time, I will take a picture from the side and upload it again, if anyone needs this.

pdpo
06-19-2009, 04:38 AM
Hi,

thanks very much, now ive downloaded the files ... this would make it posible to build the board for me too but the software is still missing. I am trying to learn from this since it would help me to understand how a communication between pc and atmel can be done.
I had already before taken up looking at the atmega64 and see what this can do all.
I had also downloaded already some bascom book but time is (as always) the limiting factor.
Anyway it would be nice if you could share that too but I would equally understand if you would not share it. I can just ask..you are free to refuse of course....:-)

Greetz Peter

TobiBS
06-19-2009, 02:06 PM
thanks very much, now ive downloaded the files ... this would make it posible to build the board for me too but the software is still missing.
Would be nice if you do that based on this layout, I hope it works a second time. :-)


I am trying to learn from this since it would help me to understand how a communication between pc and atmel can be done.
Actually my concept is currently a very easy one way communication, from the computer to the µC without any confirmation of command reception or something like that.


I had already before taken up looking at the atmega64 and see what this can do all.
I had also downloaded already some bascom book but time is (as always) the limiting factor.
I didn't program with BASCOM but don't fear ASSEMBLER, I did it with C which is also very easy to understand compared with ASsEMBLER. The source code does nothing more than receiving and setting the servos, it has exactly 100 lines.


Anyway it would be nice if you could share that too but I would equally understand if you would not share it. I can just ask..you are free to refuse of course....:-)
Well I think it is okay to share the code for the firmware, but I'd like to state again that I don't want that any part of my idea is being commercialized without my knowledge and approval.

And another thing would be great: If anyone here is programming a driver for the gauge, please also make it open source or at least send it to me, because mine is actually very worse.

Here is the code, comments are all in German, but it should be easy to translate or you can ask here.


// Vordefinieren der Taktfrequenz F_CPU in Herz für delay.h
#ifndef F_CPU
#define F_CPU 8000000UL
#endif

// Baudrate
#define BAUD 9600UL // Definition
#define UBRR_VAL ((F_CPU+BAUD*8)/(BAUD*16)-1) // Berechnungen
#define BAUD_REAL (F_CPU/(16*(UBRR_VAL+1)))
#define BAUD_ERROR ((BAUD_REAL*1000)/BAUD)
#if ((BAUD_ERROR<990) || (BAUD_ERROR>1010)) //Fehlermeldung
#error Systematischer Fehler der Baudrate grösser 1%
#endif

//Einbinden der Bibliotheken
#include <avr/io.h>
#include <avr/interrupt.h>
#include <util/delay.h>

// Servoabhängige Optionen, eingestellt für CMS digital Servo
#define basetime 0.9 // Minimalzeit eines Impulses in ms
#define steptime 4 // Auflösung der 250 Schritte in us
#define waittime 0 // Wartezeit zwischen Ausgabesignalen in ms

// Variablendeklaration
volatile uint8_t servo[4]={125,125,125,125}, kanal, i; // Servopositionen, Schleifen
uint8_t buffer, bytenummer, auswahl; // Datenübertragung

ISR (USART_RXC_vect) // Interruptroutine bei Zeichenempfang
{
buffer=UDR; // Zwischenspeichern
switch(bytenummer) // Abfrage der Bytenummer
{
case 0: // Steuerbyte (muss 255 sein)
if(buffer==255) bytenummer=1;
break;

case 1: // Auswahlbyte (25x, x=Servonummer)
if( (buffer>=251) && (buffer<=254) )
{
auswahl=buffer-251;
bytenummer=2;
}
else
{
bytenummer=0;
}
break;

case 2: // Datenbyte (0 bis 250)
if(buffer<=250)
{
servo[auswahl]=buffer; break;
}
bytenummer=0;
break;
}
}

int main (void) // Hauptprogramm
{
// Ausgänge setzen (4 Servos an PC0-PC3)
DDRB=0x00;
DDRC=0x0F;
DDRD=0x00;

// Alle Ports auf 0 setzen
PORTB=0;
PORTC=0;
PORTD=0;

// UART Baudrate setzen
UBRRH = UBRR_VAL >> 8;
UBRRL = UBRR_VAL & 0xFF;

// UART Receive und Interrupt Enable
sei();
UCSRB |= ( 1 << RXEN );
UCSRB |= ( 1 << RXCIE );

while(1)
{
cli();
PORTC|=(1<<kanal);
_delay_ms(basetime);
for (i=0;i<servo[kanal];i++)
{
_delay_us(steptime);
asm volatile ("nop");
}
PORTC=0;
kanal++;
sei();
_delay_ms(waittime);
if(kanal>3)
{
kanal=0;
}
}
}

pdpo
06-20-2009, 03:32 PM
Hi,
again thanks fro the next part of the puzzle.
One more auestion though. Does the FDTI chip act as a serial port for a PC
program? How does a PC program talk to this chip?

Greetings Peter

TobiBS
06-21-2009, 12:39 PM
One more auestion though.
But you asked to questions.:p


Does the FDTI chip act as a serial port for a PC program?
The driver of the FTDI chip supports two modes, one is an emulated COM port, the other one is a direct USB support, which is in my eyes easier to use, because you don't have to care for the port, only for the name of the device and you need only 4 commands from the SDK or so.


How does a PC program talk to this chip?
As you can see in the code above, the reception of commands is done in the ISR (USART_RXC_vect) subroutine.

And to get this thing to work, you need to transmit the control character 255, then the number of the servo which position is following plus 250 (251 for servo 1, 254 for servo 4). The third and last parameter is then the desired position from 0-250.

What you have to do in the firmware code is adopting the values to your servo, because I recognized that several servos need different timing. These are the basetime, steptime and waittime parameters. basetime is the time that is always a logical one, steptime is multiplied with 0-250 and then added to the basetime and waittime is the time that the µC waits after sending four commands to the servos to accomodate some manufacturer specifications.

If you use the CMS digital Servo from Carson, everything should be fine, if you choose a different one, I would recommend also a digital servo, the smallest you can find and the price should be around 10-15 Euro.

pdpo
06-21-2009, 01:44 PM
Well,
I cannot thank you enought for the detailed info. When time permits I'll have take a look at this and see if I can accomplish something too.
Just one more thing... out of your explanation I understand there is some driver available for this usb chip and there is an SDK to talk with it, correct?

Greetings Peter

TobiBS
06-21-2009, 02:01 PM
I cannot thank you enought for the detailed info. When time permits I'll have take a look at this and see if I can accomplish something too.
I wish you good luck and hope to see pictures of the result here.


Just one more thing... out of your explanation I understand there is some driver available for this usb chip and there is an SDK to talk with it, correct?
Yes that is exactly right, you can get the driver from http://www.ftdichip.com/Drivers/D2XX.htm, I think its worth to mention that it is not only available for Windows but also for MAC or Linux and there are some tools to test and configure the chip before you use it together with your software, it is called MProg.

The documentation I used for programming in C++ is avaliable on the page, too, here is the driect link: http://www.ftdichip.com/Documents/ProgramGuides/D2XXPG34.pdf

I think the lib and header comes together with the driver, all I needed for the software were the following commands:
FT_OpenEx to open the connection, some FT_Set* Commands to set the connection parameters (the µC firmware above is for a baudrate of 9600 Baud), the rest of the parameters is as follows:

ftStatus = FT_SetBaudRate (ftHandle, 9600);
ftStatus = FT_SetDataCharacteristics (ftHandle, FT_BITS_8, FT_STOP_BITS_1,FT_PARITY_NONE);
ftStatus = FT_SetFlowControl (ftHandle, FT_FLOW_NONE,'a','b');

As you can see we are using no flow control, 8 bits, 1 stop bit and no parity.

To send to the device, you use FT_Write, that is all you need.

pdpo
06-21-2009, 04:27 PM
Hi there,

Again THANKS....

Peter

TobiBS
06-21-2009, 04:51 PM
Hi there,

Again THANKS....

Peter

No problem, by the way: How far is your project and where is it located? Do you have pictures?

pdpo
06-22-2009, 08:12 AM
Hi there,

There are some pictures on this site in the foto gallery. Checkout the ones posted by PDPO
I am located in the north west of belgium.

Greetz Peter

TobiBS
08-05-2009, 12:04 PM
In Post #17 (http://www.mycockpit.org/forums/showpost.php?p=83659&postcount=17) I inserted the Code for the µC, but unfortunately the Code tags in this forum don't seem to work correctly, because the code is cut, before it ends, therefore if anyone needs the complete code, just drop me a mail.

TobiBS
03-01-2010, 06:20 PM
I finally developed a driver that is worth of being used, with a graphical interface, etc.
The interface is rather simple:
http://www-public.tu-bs.de:8080/~y0028089/IFF/Screenshot.png
But normally you do not see this interface, it starts up minimized to tray.

It displays the current readouts for braking pressure and ACUU PRESS (currently not supported) and the status of BOARD and FSUIPC connection. It continously tries to connect of both of them.

The software is written in Qt, for the compilation you need the FSUIPC_User Lib and Header from Pete Dowson as well as the ftd2xx Lib and Header from FTDI.

You can get the source from http://www-public.tu-bs.de:8080/~y0028089/IFF/Software.zip

And to say it clear now, all software and data in this thread provided by me is released under GNU GPL Version 3

Have fun with the software, I hope anyone makes use out of it, please post photos if you built one yourself.