Limiting dial roatation

Help creating logic scripts for Air Manager Instruments

Moderators: russ, Ralph

Post Reply
Message
Author
ifrpilot
Posts: 33
Joined: Sun Sep 02, 2018 9:18 pm

Limiting dial roatation

#1 Post by ifrpilot »

Is there code that will limit a dial's maximum rotation movement visually? So if I have a dial that starts at 9 o'clock and can be turned to 3 o'clock in 45 degree increments, I would set the click_rotate to 45. When I get to the last spot, I want the dial image to stop there even if I continue to rotate the knobster. When I rotate the knob/dial back the other way, it would change accordingly until it got back to the starting point (9 o'clock). I understand that I can't stop the physical rotation of the knobster, but I would like to stop the further rotation of the visual. Possible?

Thanks,
Steve

User avatar
Sling
Posts: 5237
Joined: Mon Sep 11, 2017 2:37 pm
Contact:

Re: Limiting dial roatation

#2 Post by Sling »

Yes possible. Either use a 5 position switch or separate the knob graphic from the dial function and control its position based on the value limits of whatever the dial controls.

Tony

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

Re: Limiting dial roatation

#3 Post by Keith Baxter »

Hi Steve

Use var_cap to limit max and min rotation.

http://siminnovations.com/wiki/index.php?title=Var_cap

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: 7878
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: Limiting dial roatation

#4 Post by Ralph »

I would also say a switch, that's exactly what it's for :)

ifrpilot
Posts: 33
Joined: Sun Sep 02, 2018 9:18 pm

Re: Limiting dial roatation

#5 Post by ifrpilot »

Thank you all! Sometimes my brain just shuts out the obvious solutions.

Steve

Post Reply