Gyro sensor detects the
rate of change of angle. IF you refer to the datasheet, you will find the factored analog signal, i.e. 2.0mV/deg/sec. Typical neutral reading at 1.5v.
Using the uC, you poll for analog reading from the gyro. at 1.502V, you know that your robot is rotating at 1deg/sec clockwise (or anticlockwise). At 1.6V, it rotate at 300 deg/sec, and voltage less than 1.5v means it rotate at opposite direction).
Once you have the measurement, here comes the hard part.
There is
no rule as to how you wish the robot (or helicopter in this case) to respond when it detect a change in rotation.
A bit of background on helicopter. As the top propeller rotates, it generate a counter reaction torque, which result in the body to rotate in the opposite rotation. Hence, the helicopter is fixed with a tail propeller, to provide thrust so that the body will not rotate. (If you observe in movies, the helicopter will start to spin when the tail propeller malfunction)
Therefore, using the z-axis accelerometer to detect the acceleration in z-axis, you common the main rotor (main propeller) to control the speed, hence your helicopter will be able to level at certain height. Using the z-axis gyro reading, you set the speed of the tail rotor, how much thrust it need to spin so that the helicopter will not spin. Alternatively, you can use trial and error to find out the correct rotor speed.
You might also want to read up some basic feedback controller concept, i.e. the PID controller. PID controller is one of the many (probably most used) control algorithm. Programming PID controller is quite easy actually, there are plenty of code examples. Another part of your code will require some amount of signal processing algorithm (filter) of the analog signal.
By the way, for your helicopter, how many axis you wish to control? up, down, turn left, turn right, rotate left, right, etc...? The more you wish to control, the more difficult it's going to be.