Aircraft TMD file

  • The tmd file is the right place for that.

    Just open the tmd file of the aircraft with a decent text editor (e.g. the free Notepad++), then search for "Flap" and you will either see a servoclassic called "ServoFlaps" or just "Flap" or "Flaps" that usually uses the "FlapInput.Output" or "FlapMapping.Output" or "FlapLever.Output" as a target. The servoclassic is a polynomial with

    Code
    1. output = P0 + P1 * in + P2 * in * in + P3 * in * in * in;

    Usually we only use the linear P1 part for the flaps, so for any given input from 0.0 to 1.0 the output is just the product of the flap "p1" and the input. That means if you increase P1 you will get a larger deflection. That's the quickest way to get to a larger deflection, though that is not actually the correct way because the flap positions are needed "outside" of the aircraft, for example for the flight info bar at the top, the autopilot, when switching aircraft, etc. So just increasing the flap angle already can affect things like: when I switch from one aircraft to the next, how much flap will the next aircraft have at initialization.

    But for beginners, sure why not :D


  • So basically control surfaces are simulated as if the aircraft was a huge RC model with model servos moving the surfaces? :)

    ... So just increasing the flap angle already can affect things like: when I switch from one aircraft to the next, how much flap will the next aircraft have at initialization.


    About this initialization. Is one better off re-starting AFS2 if switching aircraft-to prevent this issue (for now)?

    Best Regards

    Balazs


    Ryzen 2700X, HyperX 32GB, Aorus RX580 8GB, win10/ubuntu18

    Saitek X52 HOTAS, Logitech G920 pedals

    freetrack/opentrack
    X-Plane 11, DCS modules: A-10C, Ka-50, FC3, Mirage 2000C, Persian Gulf


  • So basically control surfaces are simulated as if the aircraft was a huge RC model with model servos moving the surfaces? :)


    About this initialization. Is one better off re-starting AFS2 if switching aircraft-to prevent this issue (for now)?

    well servos are rudder machines, no matter how big the aircraft :D


    no, that doesn't help if the original aircraft sends out obscure data. Aerofly uses the flap mapping that is defined in the tmc file, the flap mapping that is send from inside the tmd and the flap position which is also send from within the tmd file to figure out what flap setting to select for the next aircraft. If you send out a position that is much higher than anticipated then when you change from one aircraft to the next flaps may just be full down, even though they were only first stage on the aircraft you modified.

    So to do this correctly you need to adjust the flaps mapping in the tmc file, in the tmd file and then check that your flap position (e.g. full down) matches that flaps mapping. Then you probably won't have any issues when switching aircraft, but this takes a bit more time, I mean you can just ignore all of that, just be aware that your flaps might not be where you want them to after switching aircraft. No need to restart, that is only saving your position to the config file, so its not fixing anything because its restoring it after launch :D

    I may make it sound like its a big deal, it really isn't. As soon as you put your next aircraft on the runway or in move it on the map it will auto-fix itself.

  • Btw, is there a syntax highlight setup existing for aerofly text formats for any text editors? It can help to unveil typos and banal syntax errors.


    For e.g. notepad++ or sublime it would be nice.

    Best Regards

    Balazs


    Ryzen 2700X, HyperX 32GB, Aorus RX580 8GB, win10/ubuntu18

    Saitek X52 HOTAS, Logitech G920 pedals

    freetrack/opentrack
    X-Plane 11, DCS modules: A-10C, Ka-50, FC3, Mirage 2000C, Persian Gulf

  • yes there is. We have highlighting for EditPad Pro, I made one for Notepad++ (expanded from the old Aerofly RC 5 toolset).

    If I remember I can upload the notepad++ highlighting this evening. Its not really dynamic in Notepad++, so I need to keep it up to date manually.

    But it highlights the code nicely and highlights key words and all known parameters.

  • yes there is. We have highlighting for EditPad Pro, I made one for Notepad++ (expanded from the old Aerofly RC 5 toolset).

    If I remember I can upload the notepad++ highlighting this evening. Its not really dynamic in Notepad++, so I need to keep it up to date manually.

    But it highlights the code nicely and highlights key words and all known parameters.


    Superb, thank you!

    Best Regards

    Balazs


    Ryzen 2700X, HyperX 32GB, Aorus RX580 8GB, win10/ubuntu18

    Saitek X52 HOTAS, Logitech G920 pedals

    freetrack/opentrack
    X-Plane 11, DCS modules: A-10C, Ka-50, FC3, Mirage 2000C, Persian Gulf

  • Thank you ! So far I had been using the C language colors, that highlight quite well parameters and comments.


    Cheers

    Antoine

    Config : i7 6900K - 20MB currently set at 4.00GHz, Cooling Noctua NH-U14S, Motherboard ASUS Rampage V Extreme U3.1, RAM HyperX Savage Black Edition 16GB DDR4 3000 MHz, Graphic Card Gigabyte GeForce GTX 1080 8GB, Power supply Corsair RM Series 850W, Windows 10 64 bit.

  • Hi,


    I am looking for some standard aircraft TMD (and TMC?) template files. The online tutorials refer to them, but I can't find them in the SDK or Robin model I downloaded. Can someone help / point me to them?


    I am trying to build a simple Piper Arrow, have found some 3D model for free on the web, but attaching it to the Robin TMC file makes the converter and the simulator crash... Would like to start from the simplest form possible and build it up from there.


    Thanks in advance!
    JB