AirPanther Posted October 17, 2023 Report Posted October 17, 2023 Good day, I am inhibiting the throttles using 0x310A. This works great, but I noticed that every 10-12 seconds the throttles will uninhibit for a fraction of a second, then re-inbhibit. This causes the throttle to jump, which is bad if, for instance, I set full throttle digitally, with the throttle handles at idle on takeoff... I never reach takeoff speed. I recognize that the 0x310A offset has to be resent at least every 10 seconds, and that appears to be the problem. I am retransmitting the value every second, but when I look at the FSUIPC console log, it appears that the offset only gets rewritten to 1 after it changes to 0 (hence the split second change). It is as if all my offsets will only resend if they change even though I call .process() each time. The code below is wrapped in a timer with a 1 second interval, but it only takes effect once the inhibit changes to '0' after 10 seconds, even though it is constantly being resent, so the Any thoughts? Thanks, Robert public Offset<BitArray> ControlInhibit = new Offset<BitArray>(0x310A, 1); ControlInhibit.Value[3] = true; Process();
Paul Henty Posted October 17, 2023 Report Posted October 17, 2023 Hi Robert, 26 minutes ago, AirPanther said: but when I look at the FSUIPC console log, it appears that the offset only gets rewritten to 1 after it changes to 0 (hence the split second change). It is as if all my offsets will only resend if they change even though I call .process() each time. That's correct. By default, all offsets will be read on process() except when you have changed the value, in which case the new value is written. They then go back to reading again. If you want an offset to only be written (even when the value hasn't changed) you need to mark it as WriteOnly by setting the parameter in the constructor: public Offset<BitArray> ControlInhibit = new Offset<BitArray>(0x310A, 1, true); // Write only That will make the DLL write the current value every time you call process. You could also consider putting this offset in a named group so you can process() this at a different time from other offsets you might be using. Here's how you would do that... public Offset<BitArray> ControlInhibit = new Offset<BitArray>("inhibit", 0x310A, 1, true); FSUIPCConnection.Process("inhibit"); ... but it's not required. Paul
AirPanther Posted October 17, 2023 Author Report Posted October 17, 2023 Big thanks, Paul; Looks like that solved the problem! The FSUIPC Console log still only shows changes, but the inhibit seems to be holding permanently. I did add the "inhibit" group since I have a bunch of variables (more than a hundred) in the main group. So for efficiency, I have the inhibit by itself. I really appreciate your help! Robert 1
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