-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG]: SAS turns off without inputs #89
Comments
Thanks to Theresa on Discord, we have a screenshot of it happening. There is nothing in the KSP logs but there is an on screen message appearing 'SAS Disengaged" that is similar to the one triggered by having no EC left. In the screenshot, it is clear there is EC left. This is not deterministic as the same save reloaded just before the bug does not happen again everytime, but only sometimes. It happened without any controller plugged. |
Using the save provided by Theresa, I was able to reproduce it once in 8 tries. The message seems to be the same to the one triggered when no EC or no coms are available. Which is not the case the in save provided. By quickly reviewing the code running when no controller is plugged, nothing seems out of the ordinary. No link to Simpit code or features is established except for the fact that this seem to only happen when Simpit is installed (even when no controller is plugged). |
Disregard that PR, the solution is not as simple as I thought |
I've pushed 33a0a7e to my personal fork demonstrating a "working" fix for this issue. I assumed I could simply wrap As is, the code "works" again. I find wrapping individual toSerial providers within UnityMainThreadDispatcher kind of silly though, as it seems to contradict the entire intentions behind running these messages on a separate thread. Unfortunately I don't think we should just start passing the messages along the main update thread, unless we can disregard the Additionally, using the Main Thread limits the refresh rate minimum to the game framerate, which may or may not be a concern. |
It also just occurred to me that passing Its almost like we need some sort of async Tasks that can be started by our Event Thread, run on the main thread, then pass message content back to the Event thread that can then broadcast the messages to the respective serial ports with the proper TimeSlice delay I am NOT a Unity dev... is async/await even allowed in Unity? |
Description of the bug
Several users report some cases of SAS turning itself off without any inputs.
Nothing seems to appear in the logs when it happens. It seems to happen only when SimPit is installed and has been reported even when no controller is plugged in. It happens even if the controller does not send any command (meaning it is probably not a command that is badly interpreted).
No instance of SAS turning itself on has been reported.
How to reproduce
Not clear yet
The text was updated successfully, but these errors were encountered: