Jump to content
The simFlight Network Forums
FSlikerX

Aerosoft Airbus & FSUIPC - General Question

Recommended Posts

Hi everybody out there,

I bought FSUIPC a long time ago...

...and I was/am still so happy that there is such a perfekt and functional software :)

Now I bouhgt Aerosofts Airbus A318/319/320/321 because I am looking forward to build a small cockpit-simulator with that Software.

So know my question:

Is it possible to export variables like the AP ALT, AP HDG or the Battery-levl out of the Airbus via FSUIPC? (without LUA,...)

And show this figures via such a device: (or simply to read them with another pogramm them?)

http://simple-solutions.de/shop/product_info.php?language=en&products_id=62

with this software:

wiki.simple-solutions.de/de/products/Arcaze/Arcaze-USB/Arcaze-FSUIPC-Connector

I hope you can help - I would be very glade if you could send me a short answer.

Thank you in advance,

FSlikerX

Share this post


Link to post
Share on other sites

Hi.

Sorry for the delay in approving your post. Unfortunately Pete is away at present and I was travelling (or, well, stuck in a traffic jam!) for most of yesterday.

 

Unfortunately, I'm not a cockpit builder (nor a LUA programmer) myself, just the forum admin, so I'll leave those with more knowledge and experience to answer your question.

 

Ian P.

Share this post


Link to post
Share on other sites

Hi,

I am trying to use that software. The answer is you have to use lua. Because that program only uses fsuipc offsets and Aerosoft doesnt has any.

So you can also read Values from the FSX via a LUA Script?

And do know, how to wirte such a LUA?

best wishes,

FSlikerX

Share this post


Link to post
Share on other sites

There are examples of how to read and write Local Variables (LVars) in the documentation, which can be found within the "Modules" directory of your FSX installation.

 

Cheers,

 

Ian P.

Share this post


Link to post
Share on other sites

There are examples of how to read and write Local Variables (LVars) in the documentation, which can be found within the "Modules" directory of your FSX installation.

 

Cheers,

 

Ian P.

Okay thank you... I will check that ofcause

Do you also knok, if it is possible to create/read such a locla variable in combination with the aerosoft airbus?

Share this post


Link to post
Share on other sites

The "Local" in LVars refers to the fact that they are unique to that add-on, rather than "global", referring to the entire sim.

 

As an aside, you might like to check out LINDA (http://www.fs-linda.com/) which may already include the LVars for the Airbus packages. Unfortunately I don't use it (LINDA, that is - I do use the 'Buses) so I cannot say for sure.

 

Cheers,

 

Ian P.

Share this post


Link to post
Share on other sites

Hey that seems to be great... awesome thank you :)

But unfotunatley it seems like that this pogramm only includes LUA Scripts for Inputs (buttons,...) not for Variable-output (like Batterylevel).

Or do you/anybody out there know how to read Vars with LINDA?

But anyway thank you for that tip :-)

Wishes

Edited by FSlikerX

Share this post


Link to post
Share on other sites

Hello FSliker,

I confirm with the FSUIPC & LUA modules and it is possible to program all Aribus Aerosoft.

Because the SDK (LVar) provided by Aerosoft is very complete.

Good luck for construction.

Michel

 

PFD&ECAM.jpg

Share this post


Link to post
Share on other sites

Hello FSliker,

I confirm with the FSUIPC & LUA modules and it is possible to program all Aribus Aerosoft.

Because the SDK (LVar) provided by Aerosoft is very complete.

Good luck for construction.

Michel

 

PFD&ECAM.jpg

Hi Michel,

 

thank you :)

So do you know how to read such LVras from the Airbus?

That would be awesome...

Share this post


Link to post
Share on other sites

Hi,

 

This is an example that can be answered your questions.

 

Michel

 

 

Exemple pour la programmation de 2 inter pour allumer les écrans de contrôle

Var 3118 switch le PFD & le ND

Var 3119 switch le ECAM1 & ECAM2

(je n'avais que 2 inter rotatif, mais avec 4, on peux controler les 4 écrans séparement comme dans la réalité)

Extrait SIOC

.................
................
...............
Var 1996 name Jostick67, Link FSUIPC_OUT Offset $334C Length 4
.................
................
...............

// ********************* ECRAN CONTROLE On/off ***********************

Var 3118, name PFD_ONOFF, Link IOCARD_SW, Input 34, Type I // On & Off PFD
{
&Jostick67 = TOGGLE 8
}

Var 3119, name ECAM_ONOFF, Link IOCARD_SW, Input 86, Type I // On & Off ECAM
{
&Jostick67 = TOGGLE 7
}

Extrait FSUIPC4.INI
[buttons]
.............................
.............................
.............................
99=P66,30,CL25:R,171 ; ECAM ALL
102=P66,31,CL25:R,180 ; ECAM TO config
103=P67,0,CL25:R,210 ; PROBE ANTI ICE
104=P67,1,CL25:R,211 ; WING ANTI ICE
105=P67,2,CL25:R,212 ; ENG1&2 ANTI ICE
108=P67,3,CL25:R,55 ; VS push
109=P67,4,CL25:R,56 ; VS pull
110=P67,5,CL25:R,501 ;TEST ECAM
111=P67,6,CL25:R,301 ;Baro unit
112=P67,7,CL25:R,220 ;ECAM SWITCH
113=P67,8,CL25:R,221 ;PFD SWITCH

 

Extrait LUA

.............................
.............................
.............................
-- ECAM ON/OFF

if ipcPARAM == 220 then

if (ipc.readLvar("L:AB_MPL_ECAMU_Power") == 1) then
ipc.writeLvar("L:AB_MPL_ECAMU_Power", 0)
ipc.sleep(100)
ipc.writeLvar("L:AB_MPL_ECAML_Power", 0)
ipc.writeLvar("L:SmallOverheadPushButtons", 1)
else
ipc.writeLvar("L:AB_MPL_ECAMU_Power", 1)
ipc.sleep(100)
ipc.writeLvar("L:AB_MPL_ECAML_Power", 1)
ipc.writeLvar("L:SmallOverheadPushButtons", 1)
end

end

-- PFD ON/OFF

if ipcPARAM == 221 then

if (ipc.readLvar("L:AB_MPL_PFD_Power") == 1) then
ipc.writeLvar("L:AB_MPL_PFD_Power", 0)
ipc.sleep(500)
ipc.writeLvar("L:AB_MPL_ND_Power", 0)
ipc.writeLvar("L:SmallOverheadPushButtons", 1)
else
ipc.writeLvar("L:AB_MPL_PFD_Power", 1)
ipc.sleep(500)
ipc.writeLvar("L:AB_MPL_ND_Power", 1)
ipc.writeLvar("L:SmallOverheadPushButtons", 1)
end

end

.............................
.............................
.............................

REM
LVars du SDK
AB_MPL_PFD_Power
AB_MPL_ND_Power
AB_MPL_ECAMU_Power
AB_MPL_ECAML_Power

Share this post


Link to post
Share on other sites

Hi,

This is an example that can be answered your questions.

Michel

That seem so be realy great...

Ohhhh thank you but I think my question is mistakeable...

The correct question should be: Is it possible to export for example the SET/target Altitude or the set HDG that is also shown on the AP with FSUIPC (or with Linda,...)?

That was my false Sorry

Thanks a million,

FSlikerX

Share this post


Link to post
Share on other sites

That seem so be realy great...

Ohhhh thank you but I think my question is mistakeable...

The correct question should be: Is it possible to export for example the SET/target Altitude or the set HDG that is also shown on the AP with FSUIPC (or with Linda,...)?

That was my false Sorry

Thanks a million,

FSlikerX

Share this post


Link to post
Share on other sites

The Lua ipc library supports a function to read the local panel variables (Lvars) too, not just write them. The function is 

 

value = ipc.readLvar("name of Lvar")

 

You can even declare an event ("event.Lvar") to call a function when the value changes, with an interval specified to define the polling rate.

 

The Lua library documentation is installed in your FSUIPC Documents folder, inside the FS Modules folder.

 

Pete

Share this post


Link to post
Share on other sites

Hello,

 

before opening up a new thread, I thought, it's may be better to jump in here, as I am just being at a very similar step in my effort to run my first lua script...

 

I already have my script saved in the fsx/modules folder ("mg_airbus_pedestal.lua") an now want to run it by button assignment. But I can't find the script in the dropdown list within FSUIPC's button assignment section.

I tried it with reloading FSX and I tried to check, where the other LUA scripts are located, that are in the dropdown list by default. Nothing helped...

 

I guess, I am missing something somewhere. Would be great, if you could point me in the right direction!

 

So hopefully, I haven't mixed up the content here...

 

thanks!

Michael

Share this post


Link to post
Share on other sites

The Lua ipc library supports a function to read the local panel variables (Lvars) too, not just write them. The function is 

 

value = ipc.readLvar("name of Lvar")

 

You can even declare an event ("event.Lvar") to call a function when the value changes, with an interval specified to define the polling rate.

 

The Lua library documentation is installed in your FSUIPC Documents folder, inside the FS Modules folder.

 

Pete

First of all: Sorry for the double-posts

Thank you Pete :)

Do you fortuitous know a list with the LVars of the aerosoft Airbus or the SDK of te Airbuses? (or is it included in the lua libery document?)

And also another question: Do I simply have to drop the LUA file in the Modules-Folder to run it?

Best wishes,

FSlikerX

Share this post


Link to post
Share on other sites

I already have my script saved in the fsx/modules folder ("mg_airbus_pedestal.lua") an now want to run it by button assignment. But I can't find the script in the dropdown list within FSUIPC's button assignment section.

 

The name "mg_airbus_pedestalis too long. Needs to be 15 characters or less.

 

Pete

Share this post


Link to post
Share on other sites

Yeah! It's working!

 

After 2 weeks of working from fsuipc via Linda to LUA and endless hours of software trial & error' ing I now have my very first button of my self made airbus cockpit working!

Time for a beer now -

 

cheers and thanks for making my day, Pete!

 

Michael

Share this post


Link to post
Share on other sites

Yeah! It's working!

After 2 weeks of working from fsuipc via Linda to LUA and endless hours of software trial & error' ing I now have my very first button of my self made airbus cockpit working!

Time for a beer now -

cheers and thanks for making my day, Pete!

Michael

Hi Michael,

:) well done :)

So you build your own cockpit with the AEROSOFT airbus?

Share this post


Link to post
Share on other sites

I think it should be possible to read for example the battery-level out of the AS Airbus via SimConnet.

[ELECTRICAL BATTERY LOAD Battery load
ELECTRICAL BATTERY VOLTAGE Battery voltage]

Due to that fact: Is it possible to read data from the Airbus with FSUIPC or do I still need a LUA pogramm?
 

Share this post


Link to post
Share on other sites

I think it should be possible to read for example the battery-level out of the AS Airbus via SimConnet.

[ELECTRICAL BATTERY LOAD Battery load

ELECTRICAL BATTERY VOLTAGE Battery voltage]

 

These are the variables used by FS when it is controlling the sub-systems. Sophisticated aircraft like the PMDG 737NGX, the 777X and the Aerosoft Airbuses implement their own subsystems. There may be some overlap, you'd have to check. The variables you mention are available in FSUIPC offsets if you are not using SimConnect.

 

The Lua program method is the only way to real local gauge variables (LVars) without writing a module or gauge to go inside FS. 

 

Pete

Share this post


Link to post
Share on other sites

These are the variables used by FS when it is controlling the sub-systems. Sophisticated aircraft like the PMDG 737NGX, the 777X and the Aerosoft Airbuses implement their own subsystems. There may be some overlap, you'd have to check. The variables you mention are available in FSUIPC offsets if you are not using SimConnect.

 

The Lua program method is the only way to real local gauge variables (LVars) without writing a module or gauge to go inside FS. 

 

Pete

Hi Pete,

https://drive.google.com/file/d/0B52r0OXN32CXWkk4Z01xZnJUdUE/view?usp=docslist_api

This is the newest SDK for the Airbuses...

Is it possible to read for example the selected ALT (AB_AP_ALT_Select) with the following command:

ALT_value = ipc.readLvar(AB_AP_ALT_Select)

?

Share this post


Link to post
Share on other sites

https://drive.google.com/file/d/0B52r0OXN32CXWkk4Z01xZnJUdUE/view?usp=docslist_api

This is the newest SDK for the Airbuses...

Is it possible to read for example the selected ALT (AB_AP_ALT_Select) with the following command:

ALT_value = ipc.readLvar(AB_AP_ALT_Select)

?

 

Sorry, I've no idea whatsoever what the names in that SDK section refer to. If they are Lvars (local panel variables, often named with L: beforehand), then, yes, Lua can read the values But names are strings, so it should look like

 

ALT_value = ipc.readLvar("AB_AP_ALT_Select")

 

You'll need to read and understand the SDK to decide, I think.

 

Pete

  • Upvote 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.