Page 11 of 11 FirstFirst ... 7891011
Results 101 to 106 of 106
  1. #101
    10+ Posting Member
    Join Date
    Sep 2014
    Location
    uk
    Posts
    12
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Boeing Style MCP/Autopilot panel modified for A320 FCU and nano v3

    Posted here only as it relates very much to Fess_ter's original code and Nano than to the specific A320 FCU project.

    Thanks one and all for your helpful tips.
    Using your ideas along with some experimentation I now have the 3 Max 7219 displays, the 4 rotary encoders and 4 inputs buttons integrated and working within FSX.

    To recap the project.
    A simple A320-style FCU using an Arduino Nano along with some modification of Fester's original Boeing-style MCP coding.

    Using the Nano's 17 available pins is used the following configuration (thanks Fesster for this info).

    *Digital Pins 10,11,12 for the 3 Max7219 to display SPD, HDG, ALT & VS respectively
    *Digital Pins 2-9 for the 4 rotary encoders used. Pins combination (2-3: 4-5: 6-7: 8-9) respectively.
    *Analog Pins A0; A1; A2; A3 as inputs to operate the LOC; Autopilot ; Autothrottle, Approach buttons respectively.
    *Analog pins A4; A5; A6; A7 as outputs for the respective LED annunciators, hopefully.

    Here are the appropriate sections of Fester's original code that I modified taking your suggestions into account.
    _______________________________________________________________________________
    ***************
    void setup() section
    ***************
    for (current_pin = 2; current_pin <= 9; current_pin++) // Get pins 2-9 ready as inputs
    {
    pinMode(current_pin, INPUT_PULLUP); // By setting the pins as INPUT_PULLUP it makes them all "HIGH" etc.etc.


    pinMode(2, INPUT_PULLUP); // A0-A3 INPUTS (A4-A7 as Outputs are for LED annunciators)
    pinMode(A0, INPUT_PULLUP); // Analog pin A0 is for (LOC)
    pinMode(A1, INPUT_PULLUP); // Analog pin A1 is for (AP)
    pinMode(A2, INPUT_PULLUP); // Analog pin A2 is for (ATTR)
    pinMode(A3, INPUT_PULLUP); // Analog pin A3 is for (APPR)
    pinMode(A4, OUTPUT); // Analog pin A4 is for (LOC LED)
    pinMode(A5, OUTPUT); // Analog pin A5 is for (AP LED)
    pinMode(A6, OUTPUT); // Analog pin A6 is for (ATTR LED)
    pinMode(A7, OUTPUT); // Analog pin A7 is for (APPR LED)
    ______________________________________________________
    ***************
    void INPUTPINS() // All of the Encoders, Buttons and Switches are checked for changes
    Section
    ***************

    all_pins_state = ""; //
    for (int current_pin = 2; current_pin <=17; current_pin++) // going to cycle thru all input pins 2 - 17
    ___________________________________________________________________________________________

    After implimenting these few changes in Fester's original Boeing the A320 FCU functions I required are now working.
    Minor caveat: I still need to test if the leds built into the momentary buttons used will work. But so far so good.
    Thanks again.
    Last edited by whateveryouneed; 09-08-2016 at 02:13 PM. Reason: double post

  2. #102
    New Member
    Join Date
    Mar 2017
    Location
    italy
    Posts
    1
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Boeing Style MCP/Autopilot panel

    sorry for my English, When I am trying to compile the Following code "milviz_MCP_Mega_wire.ino, says" redefinition of 'int current_pin' "In fact there are two equal lines " int current_pin "
    // Int current_pin
    and working without error.
    I'm trying to understand something I hope to succeed

  3. #103
    New Member
    Join Date
    Dec 2016
    Location
    Americana São Paulo
    Posts
    4
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Boeing Style MCP/Autopilot panel

    Boa noite amigo Palapa

    Estou com dificuldades para acender um led externo indicando que o AP tivado no meu FSX estou usando o famoso programa do nosso grande amigo JIM, o multi radios
    Se achar necessario posso te passar meu e-mail ok.

    abraços

  4. #104
    New Member
    Join Date
    Jun 2015
    Location
    LAGNY sur Marne FRANCE
    Posts
    1
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Boeing Style MCP/Autopilot panel

    Hello, I want to build my MCP synonymous, I looked in the programming details and I saw that to control the buttons "SPEED" or "SPD / MACH" is used codes ZZ788280 and ZZ788270, I searched On the net a file giving me the "ZZ" match of the other buttons that can be used.
    If someone can give me the address or the site on which I can find this file. Thank you very much for the answer.
    Daniel

  5. #105
    150+ Forum Groupie
    Join Date
    Nov 2013
    Location
    Evansville, Indiana
    Posts
    233
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Boeing Style MCP/Autopilot panel

    To All,

    This last year I re-coded my MCP to work with a single Arduino Mega and a LUA script thru FSUIPC. No Link2FS required.
    I have a LUA script specifically for the PMDG NGX and another LUA script for the MilViz 737-200 and stock aircraft.

    All of my home built hardware now use Arduino and LUA.

    ~Fess
    I will only ever be, half the Geek that I wished I was.
    TheGeekForge.Com

  6. #106
    10+ Posting Member
    Join Date
    Sep 2014
    Location
    uk
    Posts
    12
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Boeing Style MCP/Autopilot panel

    Fantastic Fess_ter. I would like to try your script on the default A320 FCU (FSX). Is this possible?

Page 11 of 11 FirstFirst ... 7891011