How to control a servo by using a Gyro sensor?

Hello guys my name is Ralf and I am 16 year old boy from the Netherlands. I have a question about programming the Arduino. So, my question is: "Can I trigger a servo by using a gyro sensor? If so can somebody help me?"

I am building a rocket for my school project and I want a reliable parachute deployment. So I came up with an idea:) So my idea was, when the rocket is standing up, the gyroscope reset himself to 0 degrees. When the rocket fuel is empty the rocket wil fall down towards earth, so the rocket will point down and when the rocket rotates the amount of degrees will change so maybe I could make a variable of it. So what I want, when the rocket is tilted more than 90 degrees the servo shoot spin!

Little test how it could be!

var rocket(gyro.write)
servo(rocket > 90 degrees) than Servo should spin

Hopefully someone knows an answer:)

Hi RalfOfzo, why do not you use an altitude sensor, and just check the height difference. It will be positive in the ascent, null when reaching the maximum and negative in the descent, then you will be able to deploy your parachute.