Jacques Balayla Posted Monday at 04:56 PM Report Posted Monday at 04:56 PM Hi, I've recently purchased a stream controller (Soomfon) and it's working beautifully with the Fenix L:Var/Lua file in FSUIPC - I assign a keyboard key and it binds to that function - then use the box to call on that key combo and absolutely everything works perfectly (overhead panel buttons, FCU, Lights, etc) but the APU start button does not seem to work after following normal procedures - APU Master SW - APU start - APU bleed. The master switch works and so does the bleed - but not the APU start - any ideas why? My Lua file is the following: -- Toggle APU Start Button local val = ipc.readLvar("S_OH_ELEC_APU_START") if val == 0 then ipc.writeLvar("S_OH_ELEC_APU_START", 1) else ipc.writeLvar("S_OH_ELEC_APU_START", 0) end
John Dowson Posted Monday at 05:12 PM Report Posted Monday at 05:12 PM Does the lvar change values? Ifthe script is sunning as expected and the lvar is changing values, then you need something more than just to set that lvar. Why not try the presets instead: APU Start Button Push and APU Start Button Release Use logging to see if the script is running and the lvar is being updated: set logging for Lua Plugins and WAPI debug level logging.
Jacques Balayla Posted Monday at 05:43 PM Author Report Posted Monday at 05:43 PM Will try and report back. Do you have the APU Start Button Push and APU Start Button Release l:var functions for the fenix?
John Dowson Posted Monday at 06:03 PM Report Posted Monday at 06:03 PM 16 minutes ago, Jacques Balayla said: Do you have the APU Start Button Push and APU Start Button Release l:var functions for the fenix? They are MF presets, and there is also FNX320_APU_START_SWITCH. You can assign to presets directly (check the select fir Preset checkbox), or in lua you can use ipc.execPreset function. I don't have the fenix to check these. John
John Dowson Posted Monday at 06:10 PM Report Posted Monday at 06:10 PM Btw, the calc code for FNX320_APU_START_SWITCH is: (L:S_OH_ELEC_APU_START) 2 + (>L:S_OH_ELEC_APU_START) i.e. it is incrementing the lvar by 2, not 1. So maybe try: - Toggle APU Start Button local val = ipc.readLvar("S_OH_ELEC_APU_START") if val == 0 then ipc.writeLvar("S_OH_ELEC_APU_START", 2) else ipc.writeLvar("S_OH_ELEC_APU_START", 0) end The calc code for the press/release presets looks rather strange to me, as it seems to be sending two values to the lvar, which I didn't think possible: push: 1 (L:S_OH_ELEC_APU_START) ++ (>L:S_OH_ELEC_APU_START) release: 0 (L:S_OH_ELEC_APU_START) ++ (>L:S_OH_ELEC_APU_START) If the presets are not working, you can ask about this on the MF support discord server (MSFS2020 channel). John
Jacques Balayla Posted 10 hours ago Author Report Posted 10 hours ago Hi John, Tried your code - im afraid it doesn't work. So odd that it's just the APU start - even with the right variables. Im really at a loss here...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now