Stormworks: Build and Rescue

Stormworks: Build and Rescue

35 ratings
Horizontal Stabilizer
   
Award
Favorite
Favorited
Unfavorite
Vehicles: Sea, Land, Mechanical
Microcontrollers: Calculation, Microcontroller
Tags: v1.1.3
File Size
Posted
294.938 KB
Feb 25, 2021 @ 12:17am
1 Change Note ( view )

Subscribe to download
Horizontal Stabilizer

Description
This microcontroller keeps your turret pointed in the same direction and is simple to set up.


First off your turret traverse should be done via a velocity pivot, facing with the positive arrow clockwise, this way it can turn 360 degrees freely and also very rapidly so, the prefered ratio with this stabilizer is 1:2 with 100% power after tuning, as i have found this ratio to provide a decent turn rate combined with precision.

Now for the MC to be able to detect what the turret is doing an angular velocity sensor is needed, place this on the turret (so when the pivot turns the sensor will turn too) with the positive arrow (again) clockwise.

Then simply connect all the connections, so your control input from the gunners seat to the A/D input, the sensor to the sensors input and the pivot to the output of the controller. Incase you want to turn the stabilizer off for moving or if you arent in the turret, then you can turn it off via the On/Off input to the MC.

If you want a slower turret traverse or maybe even quicker, then make sure to change the property slider, it goes from 0.1 to 3 (1 is the standard, but if you want a really slow and precise or super quick you can just change this)


Checklist for the stabilizer to work properly:

-- Angular speed sensor (with positive arrow clockwise)
-- Velocity pivot (With 1:2 ratio on it and positive arrow clockwise)
-- Seat to control turret

Example creation using this stabilizer and also a vertical stabilizer:
https://steamcommunity.com/sharedfiles/filedetails/?id=2407189011

Notes:

Feel free to use this in your creations just remember to link this incase you upload it

This is only a horizontal stabilizer(!)

The tank in the thumbnail, video and pictures is not uploaded(yet)
21 Comments
l0891.超纪飞侠 Apr 23 @ 2:14pm 
is there a way to merge the control speed and the stabilizer PID in/output?
The Thing Mar 1 @ 12:33pm 
thanks, this works and made my turret not spin like a microwave
Zeke Feb 17 @ 7:24am 
without stabiliser the turret doesn't move at all and with the stabiliser it doesn't snap its very floaty and is not precise
Crolin10 Aug 20, 2024 @ 2:25pm 
The rotation arrows are correct, positive clockwise but the gun just keeps spinning left
President Luigi Jun 6, 2023 @ 5:07pm 
How did you come up with the math to make this work?
kylonr Feb 11, 2023 @ 7:14pm 
am I able to make the stab off when I spawn?
Novum33 May 24, 2022 @ 1:43pm 
Very shakey
Lazakamikaza  [author] Dec 12, 2021 @ 11:41pm 
Very nice. Im surprised people are still finding this stabilizer and using it as it is almost a year old by now

And yea im guessing your turret is just a fraction the weight of my original tanks turret (The one in the video clip)
Benbalooky Dec 12, 2021 @ 8:54pm 
Hey Laza, I wanted to describe my troubleshooting here so others can try what I did if they have a similar issue.

I have good news. In my troubleshooting I discovered two issues: The first one is that the platform the velocity pivot benefits from being rigid. If it wiggles around too much the stabilizer overcorrects like I described. Small attachments come in handy in this regard.

The second, and best thing I did was lowering the integral gain on the PID. I took it from 0.1 all the way down to 0.0008. If this seems drastic it is because the turret I'm using is quite small, so it is very sensitive. The other two values, proportional and derivative gain, were left at their default values.

During some extreme maneuvering the oscillations return. Toggling the stabilizer off then on has corrected this issue every time. Thank you!
Lazakamikaza  [author] Dec 12, 2021 @ 5:04am 
@Benbalooky it might have to do with the turret size, the original stabilizer was built for quite a large tank turret. Try lowering all the PID values inside the MC by some small amount and it should start working fine again, just be sure to not lower them too much as that might lead to it undercompensating. If i ever make a new version of this ill be sure to add a property setting for overall "sensitivity" as a multiplier for the pid values. DM me on steam if you have more issues with it :steamthumbsup: