Rotary Encoders stopped working

Discuss suspected bugs with other users and Sim Innovations Staff

Moderators: russ, Ralph

Post Reply
Message
Author
ecdcrew
Posts: 10
Joined: Mon Jan 25, 2021 11:16 pm

Rotary Encoders stopped working

#1 Post by ecdcrew »

This is before the 11am MSFS update, on my cesnna audrino mega panel, only 2 of 7 Roatary encoders work.

I tested them using Lua directly in AM, and they work, so the problem may be simconnect/msfs...

Any advice?

I already cleared cache, persistence, rebooted, flashed over....

User avatar
Ralph
Posts: 7924
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: Rotary Encoders stopped working

#2 Post by Ralph »

Make sure that you are using the latest plugin. It can also be a network issue.

ecdcrew
Posts: 10
Joined: Mon Jan 25, 2021 11:16 pm

Re: Rotary Encoders stopped working

#3 Post by ecdcrew »

I am, latest plug-in and latest version

User avatar
Ralph
Posts: 7924
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: Rotary Encoders stopped working

#4 Post by Ralph »

Did you check software dials, like an altimeter?

ecdcrew
Posts: 10
Joined: Mon Jan 25, 2021 11:16 pm

Re: Rotary Encoders stopped working

#5 Post by ecdcrew »

After a few hours of.... I want to say debuging, but more like bludgeoned investigation, the error is hw_dial_add("item", x, function)

The x is causing a legacy code issue...

I leave it to you. Without the x integer, no issues. Has to be a legacy to new code matter.

I could be wrong

Default Cessna panel... 9 encoders.

User avatar
Ralph
Posts: 7924
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: Rotary Encoders stopped working

#6 Post by Ralph »

X can be various things. This is the API for the rotary encoder: http://siminnovations.com/wiki/index.ph ... w_dial_add

ecdcrew
Posts: 10
Joined: Mon Jan 25, 2021 11:16 pm

Re: Rotary Encoders stopped working

#7 Post by ecdcrew »

Yes, I read the API 1000 times. Humbly I say that noting brought the 9 encoders back to life other than completely disregarding the optional variables.

I think somehow when many rotary encoders are present, the Lua script fails. (That is a panel full of encoders)


Community Panel Cessna Instruments, non modified Lua Script:
One or two fine. 7 fail.


Community Panel Cessna Instruments, with modified Lua
Remove the optional API variable, present at all hw_dial_add.... all 9 work.

User avatar
Keith Baxter
Posts: 4685
Joined: Wed Dec 20, 2017 11:00 am
Location: Botswana

Re: Rotary Encoders stopped working

#8 Post by Keith Baxter »

Hi,

Post your instrument here so that members can have a look give some help.

Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board,  32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card 

User avatar
Ralph
Posts: 7924
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: Rotary Encoders stopped working

#9 Post by Ralph »

I'm not sure if you're talking about script in the instruments that come with Air Manager or your own script.

User avatar
Keith Baxter
Posts: 4685
Joined: Wed Dec 20, 2017 11:00 am
Location: Botswana

Re: Rotary Encoders stopped working

#10 Post by Keith Baxter »

Ralph wrote: Sat Nov 20, 2021 3:25 pm I'm not sure if you're talking about script in the instruments that come with Air Manager or your own script.
Ralph,

Correct it is very unclear, The OP needs to give us the code else we are looking for UFO's in the Kimberly hole. :mrgreen:

Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board,  32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card 

Post Reply