AUTOTHROTTLE AND AUTOPILOT AUTOMATIC DISENGAGE http://www.md80project.dk http://sites.google.com/site/danskemd80cockpitprojekt/
The parts needed for this build is: Input Output Optocoupler LTV 817 (Or similar) Transistor BD 679 (Or similar, NPN used when output is +) Resistors 100 4,7 Kohm Diode 1N4003 (Or similar) Relay 3-5 volt Finder 36.11.9.005.4001 (Or similar) Power supply (Old stuff) Circuit breaker: http://www.carlingtech.com/hm-cb-ms-series Power supply FGCP + input Input - input 0.2 Amp Output OUTPUT I use open cockpit master to control the needed output. On the output I need a relay, because the master don't have enough output power to trip the switch (circuit breaker) or to control a relay, therefore I place a resistor and a transistor on the output and I then use the master s 5 volt power supply to control a relay. Remember to place a diode over the relay coil to kill the induction current from the coil. Here I have build tree relays in a box that will control: AP, AT and stick shaker. Transistors are placed in shrinkable tubing, to prevent a shortcut.
POWER SUPPLY I need an extra DC power supply to trip the circuit breaker, because this need a high current. When the circuit breaker shall trip the relay will make a short circuit that will pull the power supply momentary to near 0 volt, therefor the supply can't be used to other things. There is no great demands for the power supply, but it must be able to deliver somewhere between 1-2 amps from 6 to 15 volts and be able to withstand an ultra short, short circuit. I use an old power supply that has been used for a video camera. On the top there is a battery charger. In the end there is a 6 volt output and that is what I use as a trip current. But remember when you choose the supply, that a lower voltage will give a smaller spark in relay and in the circuit breaker, with longer lifetime to follow.. INPUT To prevent a mix up between different voltages I need an optocoupler to transfer my alien supply over to my input. The optocoupler works like an LED on one side and an photo-diode one the other side. When the LED lights, the photo-diode will short circuit the input, just like a switch. Here we can see the two optocouplers mounted on the joystick, one for AT and one for AP. Again shrinking tube to prevent a short circuit. The optocoupler have to be connected correct otherwise the signal will not be transferred. You need a resistor to adjust the current for the optocoupler LED. Normally: supply voltage x 0.02 = Resistor size CIRCUIT BREAKER The circuit breaker can simulate the original switches. But I am convinced that the original contact is kept turned on by an electromagnet. When the fuse is turned on, it will complete the circuit through the optocoupler and there is a consumption of approx. 0.02 amperes through the optocoupler LED. When we want to trip the fuse, we will make a short circuit across the optocoupler, the the power supply provides now maximum current and this cuts out the fuse. To avoid large sparks in fuse, it is a good idea to use a fuse that will trip at the lowest possible power consumption, at the same time a smaller power supply can be used. The fuse I refer to can be obtained down to 0.2 amps. LINK: http://www.carlingtech.com/hm-cb-ms-series
How it works Power supply FGCP + input Input - input OFF 0.2 Amp Output Now the system is powered and the red wire gives supply to the switch (circuit breaker). The switch is in OFF position and stops the supply, therefor the optocoupler LED is not lit. Input gives supply to the optocoupler photo-diode, but this is open and do not lead the supply to the input. FSUIPC can read that the switch is in OFF position. Power supply FGCP ON + input Input - input 0.2 Amp Output Now the system is powered and the red wire gives supply to the switch (circuit breaker). The switch is in ON position and leads the supply to the optocoupler LED and it is lit. (There is also a + and - supply to the relay connections C and NO but this have no effect now) Input gives supply to the optocoupler photo-diode, and this is now closed and lead the supply to the input. FSUIPC can read that the switch is in ON position. If you now turn the switch to off, then you will have the previous situation.
Power supply FGCP + input Input - input TRIP 0.2 Amp Output Now the system is powered and the red wire gives supply to the switch (circuit breaker). The switch is in ON position and leads the supply to the relay. Now the output gives supply to the transistor and the relay activates to trip the switch, the relay will short circuit over the optocoupler LED and this will turn off. The power supply give full current to the switch (that is a circuit breaker) this will trip the it to OFF. FSUIPC can read that the switch is in OFF. UNDER THE FLOOR Relay box Under the floor in the right side of the cockpit I have placed two power supplies one for each switch. Here is the relay box also placed. The gray box to the right is the control unit for AT motor and the auto spoiler motor. To prevent electric noise, try to keep these units away from inputs signals, USB and other computer cables. All the wires from these units shall also be placed away from the computer cables. If you have to cross these wires do it in 90 degrees. Power supply Try to connect all you wires so it's possible to disconnect it from other. Remember to mark all connection so you connect it correctly.
THE MADDOG SETUP One of the first conditions that is needed for the autopilot and autotrottle switches to function properly, is to assigning two commands, one for the switch ON and one for the switch OFF. Therefore, I will start to open the maddog manager & setup, and then open setup / Keyboard and then assign buttons keystrokes. Here I assign the autothrottle to turn on when keystroke shift + control + T is received Select: AP_AUTOTHROTTLE Assign the command parameter to 1 that means a turn ON command. (Assigning the command parameter to 0 means a turn OFF command. Mark shift and control and put in the letter T (you can use other keystrokes if you want to.)
Now I assign the other keystrokes Here are the keys assignments: Autothrottle on: Shift Control T Autothrottle off: Shift Control Y Autotpilot on: Shift Control P Autotpilot off: Shift Control O
THE FSUIPC SETUP AT and AP switches are connected to the joystick. Through FSUIPC I assign keystrokes to be sent each time these buttons will change position. Open FSUIPC and open the menu Buttons + Switches For example, when I flip my cockpit AT switches to ON, FSUIPC will send keystroke "ctrl + shift + T" signal to the Maddog and that will flip the virtual switch to on. In off position the keystroke "ctrl + shift + Y" is send. Remember that FSUIPC Mouse Macro will not work. The Mouse Macro flips the virtual switch every time a change comes to the mechanical switch position. That means, that if the virtual autopilot switch is automatic disengaged, and then a split second after, the real switch is electric tripped, then the FSUIPC reads this and sends one mouse macro. This gives this reaction to the virtual switch: First it will go automatic to OFF and then it's forced back to ON through FSUIPC. When the specified ON/OFF keystroke is used is doesn t matter if a off command is send to a virtual switch that's already in off position.
SCRIPT. I have chosen to integrate the AT switch tripping script with my old autothrottle motor script Otherwise I could get problems with the autothrottle motor that not always could be activated. OBS: The script that s is not regarding AT switch tripping is marked with gray letters. I use two offsets to trip the switches, and I uses the special Maddog SIOC. Offset 0101 will be 1 when the autopilot is engaged and 0 when disengaged. Offset 2526 will be 0 when when the autothrottle is engaged and 100 when disengaged. //***********************AUTOPILOT**************************** Var 1760, Link IOCP, Offset 0101 // Read virtual Auto pilot switch: 1=on / 0=off IF V1760 = 0 // AP switch is inactive V1769 = 1 V1769 = DELAY 0,100 // Trip AT switch for 0.1 sec ELSE V1769 = 0 // AP switch is active Var 1769, Link IOCARD_OUT, Output 22 // AP switch disconnect Relay //***********************AUTOTHROTTLE********************** Var 5560, Link IOCARD_ANALOGIC, Input #3, PosL 6, PosC 55, PosR 160 CALL V5562 Var 5561, Link IOCP, Offset 2551 // THROTTLE 1 // Throtlle 1 0-100 % FROM VC Var 5562, Link SUBRUTINE L0 = V5560-128 // Throttle 2 kalib V5563 = L0 * 163 // Throttle 2 output Var 5563, Link FSUIPC_OUT, Offset $088C, Length 2 // Set axis in FSUIPC Var 5570, Link IOCARD_ANALOGIC, Input #4, PosL 16, PosC 60, PosR 170 CALL V5572 CALL V5581 CONTINUED NEXT PAGE // THROTTLE 2
Var 5572, Link SUBRUTINE L0 = V5570-128 // Throttle 2 kalib V5573 = L0 * 163 // Throttle 2 output Var 5573, Link FSUIPC_OUT, Offset $0924, Length 2 // Set axis in FSUIPC Var 5580, Link IOCP, Offset 2526 // Read virtual Auto throttle switch: 100=off / 0=on IF V5580 = 100 // AT switch is inactive V1599 = 1 V1599 = DELAY 0,100 // Trip AT switch for 0.1 sec ELSE V1599 = 0 // AT switch is active Var 1599, Link IOCARD_OUT, Output 21 // Disconnect AT switch Relay Var 5571, Link IOCP, Offset 2555 // Throtlle 1 0-100 % FROM VC Var 5577, Link FSUIPC_IN, Offset $023A, Length 1 CALL V5581 CONTINUED NEXT PAGE
Var 5581, Link SUBRUTINE L1 = V5570-129 L1 = L1 - V5571 // lever - VC throttle IF V5580 = 0 IF L1 < -1 V5591 = 1 ELSE V5591 = 0 IF L1 > 1 V5592 = 1 ELSE V5592 = 0 ELSE V5591 = 0 V5592 = 0 Var 5591, Link IOCARD_OUT, Output 12 // motor - Var 5592, Link IOCARD_OUT, Output 11 // motor + I hope that this tutorial helps you to make your own AP and AT system. Happy flights. Claus