Is there a way to write a program that will control a hinge actuator? For example; lets say I want to be able to make a single hinge get input from pitch, yaw, and roll for a fin on a starship style ship. In order for it to fall in a controlled manner, it would need to receive input from all three axis's. I don't understand code that well and I'm trying to use this as a way to understand. I think it would use a PID or something like to stay level over a target area (or just stay level without a specific target). But getting one actuator to be controlled by all 3 axis of movement is beyond my comprehension. This is probably way to advanced for a novice to code like me, but I've been able to control a "starship" manually by moving the forward and aft flaps to control the pitch.

I know there are probably thousands of people trying to build starship replicas but I'm really intrigued by the massive engineering challenge this is. Any tips would be helpful, thanks!

Tags
Question

3 Comments

  • Log in to leave a comment
  • Profile image

    you can set the rotators/hinges to use a variable that is controlled by a vizzy program, and able to use a custom pid - the input for the rotator/hinge would have to be typed in like this {name of part with program.flightprogram.name of variable} - so, if the vizzy is on the Command Chip and the variable name is "Fin", the input would be {Command Chip.flightprogram.Fin}
    then the rotator/hinge will operate by whatever you set the "Fin" variable to (in the vizzy program)

    3.2 years ago
  • Profile image

    @YaMomzBox420 I have tried that method. The only thing is that sometimes the input will go negative and the flap will end up pointing down, but now that I think of it I would just have to make sure the ships orientation is point the right way. This just gave me a bunch of ideas to try.

    +1 3.2 years ago
  • Profile image
    1,159 YaMomzBox420

    I've been dealing with the same thing to an extent. I built a low quality starship to test the idea and basic aero, but it was hard to use the flaps properly as a control surface with my set-up. I'm not very good with vizzy so I never really figured it out on my own, but I did think of something that might work. If you set the flaps control(in the part properties tab of the designer) to pitch/roll then the autopilot should automatically control them the way intended(although I'm not sure since I haven't tested that yet). I also believe vizzy could control them in a similar fashion if set that way

    3.2 years ago

No Upvotes

Log in in to upvote this post.