UGH I actually took time to look that up but I found no results. Should have just tested it out. thanks. 

-dc

On Sun, Jun 30, 2013 at 2:55 PM, Nathan Lilienthal
<notifications@github.com> wrote:

>> +   #    @gyroscope.x,
>> +   #    @gyroscope.y,
>> +   #    @gyroscope.z
>> +   # )
>> +  end
>> +
>> +  private
>> +
>> +  tau = 0.98 # tweak according to drift
>> +  # @angle is the previously estimated angle using both gyro and accel data
>> +  def estimate_angle(readings, dt)
>> +    gyro, accel = readings[0], readings[1]
>> +    a = tau/(tau + dt)
>> +    gyro_angle = @angle ? @angle + gyro * dt : 0 # @angle defaults to 0
>> +    @angle = a * gyro_angle + (1-a) * accel
>> +    return @angle
> ### Rubyfoo
> Ruby implicitly returns the last value of a function. And since variable assignments returns the assigned value. `return @angle` is redundant, you can simply delete this line and everything will be the same.
> ---
> Reply to this email directly or view it on GitHub:
> https://github.com/nixpulvis/quadrocopter/pull/17/files#r4954664