class Gps::Nmea::Gga
Attributes
age_of_diff[RW]
altitude[RW]
altitude_unit[RW]
fix_quality[RW]
hdop[RW]
latitude[RW]
latitude_direction[RW]
longitude[RW]
longitude_direction[RW]
num_satellites[RW]
time[RW]
time_str[RW]
Public Class Methods
new(line)
click to toggle source
# File lib/gps/nmea/gga.rb, line 10 def initialize(line) @line = line fill_parts fill_data end
Private Instance Methods
fill_data()
click to toggle source
# File lib/gps/nmea/gga.rb, line 18 def fill_data @time_str = Sentence.time_part_to_str @parts[0] @time = Time.parse time_str @latitude = @parts[1].to_f @latitude_direction = @parts[2] @longitude = @parts[3].to_f @longitude_direction = @parts[4] @fix_quality = @parts[5].to_i @num_satellites = @parts[6].to_i @hdop = @parts[7].to_f @altitude = @parts[8].to_f @altitude_unit = @parts[9] @age_of_diff = @parts[10].to_f end