AlMassimo Posted June 22, 2022 Author Report Posted June 22, 2022 Uselessly stubborn I must say... Did not work of course... weird that the frequency is updated, but the course not, only after list Lvars... well, I'll do a list Lvars just after setting the flight plan, not a big deal, but still weird for me.
AlMassimo Posted June 22, 2022 Author Report Posted June 22, 2022 I found this on log : 153141 3692 *** EVENT: Cntrl= 66984 (0x000105a8), Param= 0 (0x00000000) COM3_VOLUME_SET 153454 3692 *** EVENT: Cntrl= 67230 (0x0001069e), Param= 1 (0x00000001) AP_MANAGED_SPEED_IN_MACH_OFF 154047 3692 *** EVENT: Cntrl= 67230 (0x0001069e), Param= 1 (0x00000001) AP_MANAGED_SPEED_IN_MACH_OFF 154141 3984 **** Lvar 'FLIGHTPLAN_APPROACH_COURSE' not found: cannot add to offset 0xA022 154157 3692 *** EVENT: Cntrl= 66964 (0x00010594), Param= 1 (0x00000001) COM1_RECEIVE_SELECT 154157 3692 *** EVENT: Cntrl= 66965 (0x00010595), Param= 0 (0x00000000) COM2_RECEIVE_SELECT 154157 3692 *** EVENT: Cntrl= 66966 (0x00010596), Param= 0 (0x00000000) COM3_RECEIVE_SELECT 154157 3692 *** EVENT: Cntrl= 66978 (0x000105a2), Param= 100 (0x00000064) COM1_VOLUME_SET 154157 3692 *** EVENT: Cntrl= 66981 (0x000105a5), Param= 0 (0x00000000) COM2_VOLUME_SET 154157 3692 *** EVENT: Cntrl= 66984 (0x000105a8), Param= 0 (0x00000000) COM3_VOLUME_SET 154204 3984 Lvars/Hvars received - checking aircraft autos.... 154204 11212 LUA.1: beginning "D:\FSTools\FSUIPC7\ipcReady.lua" 154344 3692 *** EVENT: Cntrl= 67251 (0x000106b3), Param= 10 (0x0000000a) NAV1_RADIO_SET_HZ 154454 3692 *** EVENT: Cntrl= 65708 (0x000100ac), Param= 2048 (0x00000800) NAV1_RADIO_SET 154547 3692 *** EVENT: Cntrl= 67230 (0x0001069e), Param= 1 (0x00000001) AP_MANAGED_SPEED_IN_MACH_OFF The messge appears ONLY for COURSE not for ILS, so it was not loaded at all in fsuipc.ini I tried with wasm reload when Lvar was correctly listed but still it was not loaded on offset A024
John Dowson Posted June 22, 2022 Report Posted June 22, 2022 As I keep saying, you need to increase the LvarScanDelay further. To see the actual lvars currently available, assign a button or key to the control List local panel vars. If you use that, no rescan will be performed and you will see that the lvars you are using are not available, due to your LvarScanDelay parameter being too low. There is nothing that FSUIPC7 can use that tells it when ALL lvars are available, and indeed, some lvars are created quite some time after aircraft load. Also, take a look at the index numbers of the lvars you are using - the higher the number, the later they are created. I suspect the ones you are using are created after some time. 2 minutes ago, AlMassimo said: The messge appears ONLY for COURSE not for ILS, so it was not loaded at all in fsuipc.ini I tried with wasm reload when Lvar was correctly listed but still it was not loaded on offset A024 Yes - lvars are only added to offsets on initial load, after the first scan. They are not added to offsets on a rescan. This is why you should increase the LvarScanDelay to an appropriate value, when ALL the lvars you are using are available. I am spending a lot of time on this and just repeating myself. It is obvious, to me at least, what your issue is, and I am telling you how to solve this. PLEASE just follow my advice, it would save us both a lot of time... John
AlMassimo Posted June 22, 2022 Author Report Posted June 22, 2022 Ok sorry I thought it was an interesting issue, but of course it's not for all, for me all this was very instructive though. best regards ant thanks for your time
AlMassimo Posted June 22, 2022 Author Report Posted June 22, 2022 ANYWAY (and I wont bother you any longer on this subject) since a simple list Lvars solve everything, it appears to me that Fsuip CAN do something to update Lvars created much too later to solve the problem by increasing lvar scan delay... to what, 120 secs ? No way, at least for me, I'll do a list Lvars and all works. Bye John
John Dowson Posted June 22, 2022 Report Posted June 22, 2022 22 minutes ago, AlMassimo said: it appears to me that Fsuip CAN do something to update Lvars created much too later to solve the problem by increasing lvar scan delay Increasing the LvarScanDelay IS the way you solve this. Listing lvars is NOT a solution, as this would still not add any lvars to offsets - this is only done on the first scan, as I said. I cannot change the fact that lvars are created such a long time after aircraft load, only provide facilities to allow for this, which I have done. 22 minutes ago, AlMassimo said: No way, at least for me, I'll do a list Lvars and all works. But why list lvars? Just perform a rescan/reload. You can do this in lua using ipc.reloadWASM(). You can even create a small lua script that calls this on a timer (event.timer) periodically (say, every 10seconds). The script can also exit itself once all the lvars you are using are loaded and available (and it is no longer needed). You can check if an lvar is available by using ipc.getLvarId(“name”) - the returned value would be nil if the lvar doesn't exist. Alternatively, you could have a section in your script that checks the availability of the lvars you are using before it starts to use them, and if not available then perform a ipc.reloadWASM() until they are.
AlMassimo Posted June 22, 2022 Author Report Posted June 22, 2022 WOW this is something I have to try!!! THANKS this IS the best way IMO! I'm sorry I didn't figure it out before...
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