#Gyroscope / Pitch & Roll Indicator

1 messages · Page 1 of 1 (latest)

pastel laurel
#

(Edit: changed output from redstone comparators to rotational force, hat tip to @olive ore for the brilliant idea)

The Gyroscope outputs rotational force proportional to the pitch, roll, and yaw of the ship relative to the world. This rotational force could be used to build basic autopilot / steadying / station-keeping controls.

(note: I'm going to use pitch, roll, and yaw below, assume we're talking about a ship whose aft is to the north and starboard is to the east, in ship-space)

It works like so:

  • One face takes an input rotational force. In the block's default orientation, this is the bottom, but the block may be oriented in any direction, similar to a piston block.
  • All other faces are outputs.
  • Top and bottom outputs are based on yaw: rotation of the ship within the world's XZ plane.
  • North and south outputs are based on roll: rotation of the ship within the world's XY plane.
  • East and west outputs are based on pitch: rotation of the ship within the world's YZ plane.
  • Each output RPM is calculated as a linear mapping between the ship's rotation (-180º, +180º], and the input RPM [-<input RPM>, +<input RPM>]. E.g., given an input of 32 RPM, a 45º rotation would produce an output of 8 RPM. Given an input of 120 RPM, a -30º rotation would produce an output of -20 RPM.
  • The Gyroscope consumes stress proportional to input RPM. Higher input RPM provides greater precision, but consumes more stress.

Bonus idea: it would be useful to be able to tell tilt relative to a particular attitude (e.g., the attitude of the ship when the block starts receiving rotational force), not just to the game world. This would This could be a separate block, or one block with two modes, similar to the redstone comparator.

junior quarry
#

Would be cool to make it able to be placed in different orientations for yaw as well.

olive ore
#

Valkyrien Computers

pastel laurel
#

Meh, lua's cheating. I want to do it in redstone 😛

pastel laurel
olive ore
#

i have an idea

#

a Gyroscope

it outputs rotational power out of every side, rotation direction based upon the ship's rotation

just a bit of spit balling

pastel laurel
#

hmm...replace redstone signal strength with rpm? interesting idea

olive ore
#

this way it can already be used with Create and using other things like Speedometer to translate ot redstone

pastel laurel
#

Gyro -> Speedometer -> Comparator -> awesome redstone auto-pilot circuit

olive ore
#

exactly

pastel laurel
#

If they made a flap bearing that was actually controlled by rotation instead of redstone, you might be able to gear things so you don't even need the circuit

olive ore
#

so youll never believe what power i gave the Flap Bearing ComputerCraft peripheral XD

pastel laurel
#

lol

olive ore
#

plus, with redstone, it would theoretically come out all sides, which with Quazi-Connectivity is a bad combo

pastel laurel
#

I shouldn't have called it a redstone signal, I'm really just suggesting the sides work as inputs to a comparator. So that shouldn't be a problem.

#

But I really like your rotational force idea tbh

misty radish
pastel laurel
#

for me part of the fun/challenge is building things in "hardware": redstone circuits, Create logistics and machinery, etc.

#

but I mean, I'm just speaking for myself here. Not judging others for using CC to do cool stuff

#

really it's all about options for different play styles: like you can use CC to whoosh inventory items around like data, or you can build a conveyor belt Rube Goldberg machine with Create.

I know I can write a program to do it, so for me the fun is in not doing that. 🙂

sullen salmon
#

Maybe

#

Idk now my brain hurts

pastel laurel
#

Hmm, if the gyro outputs rotational force, and if Clockwork get support for transferring rotational force between ships...you could use a gyro "ship" as a very cursed rotational speed controller.

#

Unrelated to that horrible idea...I'm thinking about how to map tilt angles to rotational force. It could just be RPM = angle, with the output range being [-179 RPM, 180 RPM], or it could be a linear mapping onto [-255 RPM, 256 RPM], with 256 RPM = 180º. But that means it would often output really low RPM, which would be pretty hard to work with.

#

maybe better idea: scale the angle-to-RPM function based on the input RPM. So if the input is 32 RPM, then 180º = 32 RPM, 90º = 16 RPM, etc. The cool thing about this is that higher input RPM yields more precision, but has a higher SU cost.

pastel laurel
# olive ore input from what side tho

One face - the bottom face, in the block's default orientation - would take input. The other faces would give output, based on which ship-space axis the face is orthogonal to. Make it positionable in different orientations (like a piston, for example), so the player can put the input on whichever face works best for their situation.

versed flint
#

isnt the point of a gyroscope is to not tilt? except for that it would be cool, also use the gyroscope to make the ship more stable depending of the redstone signal its receiving

pastel laurel
#

A gyroscope contain a spinning element that maintains its orientation. The gyroscope uses this to measure the orientation of the gyroscope (and by extension, the ship it is part of). They are often used for attitude control in spacecraft.