Go Nmea Versions Save

A NMEA parser library in pure Go

v1.8.0

1 year ago

New Sentences 💌

  • ABM: AIS addressed binary and safety related message (#100)
  • ACK: Acknowledge alarm (#100)
  • ACN: Alert command (#100)
  • ALC: Cyclic alert list (#100)
  • ALF: Alert sentence (#100)
  • ALR: Set alarm state (#100)
  • ARC: Alert command refused (#100)
  • BBM: AIS broadcast binary message (#100)
  • HBT: Heartbeat supervision sentence (#100)
  • PSKPDPT: Depth of Water for multiple transducer installation (#94)
  • TLB: Target label (#100)
  • TTD: Tracked target data (#100)
  • VSD: AIS voyage static data (#100)

Enhancements 🎉

  • Add support for optional values (#99)

Bug fixes 🐛

  • Fix XDR missing N (Newtons) as measurement unit enum value (#95)

Thank you! 🥇

@aldas @@bezineb5 @icholy


Full Changelog: https://github.com/adrianmo/go-nmea/compare/v1.7.0...v1.8.0

v1.7.0

2 years ago

New Sentences 💌

  • DTM - Datum Reference
  • OSD - Own Ship Data
  • RSD - RADAR System Data
  • TLL - Target latitude and longitude
  • TTM - Tracked Target Message
  • VBW - Dual Ground/Water Speed

Thank you! 🥇

@aldas


Full Changelog: https://github.com/adrianmo/go-nmea/compare/v1.6.0...v1.7.0

v1.6.0

2 years ago

New Sentences 💌

  • AAM - Waypoint Arrival Alarm (#88)
  • ALA - System Faults and alarms (#88)
  • APB - Autopilot Sentence "B" (#88)
  • BEC - Bearing and distance to waypoint (dead reckoning) (#88)
  • BOD - Bearing waypoint to waypoint (origin to destination) (#88)
  • BWC - Bearing and distance to waypoint, great circle (#88)
  • BWR - Bearing and distance to waypoint (Rhumb Line) (#88)
  • BWW - bearing (from destination) destination waypoint to origin waypoint (#88)
  • DBK - Depth Below Keel (obsolete, use DPT instead) (#88)
  • DOR - Door Status Detection (#88)
  • DSC - Digital Selective Calling Information (#88)
  • DSE - Expanded digital selective calling (#88)
  • EVE - General Event Message (#88)
  • FIR - Fire Detection event with time and location (#88)
  • HSC - Heading steering command (#88)
  • MTA - Air Temperature (obsolete, use XDR instead) (#88)
  • RMB - Recommended Minimum Navigation Information (#88)
  • RPM - Engine or Shaft revolutions and pitch (#88)
  • RSA - Rudder Sensor Angle (#88)
  • VDR - Set and Drift (#88)
  • VLW - Distance Traveled through Water (#88)
  • VPW - Speed Measured Parallel to Wind (#88)
  • VWR - Relative Wind Speed and Angle (#88)
  • VWT - True Wind Speed and Angle (#88)
  • XDR - Transducer Measurement (#88)
  • XTE - Cross-track error, measured (#88)

Enhancements 🎉

  • DBS - Validate field units in sentences (#88)

Thank you! 🥇

@aldas

Full Changelog: https://github.com/adrianmo/go-nmea/compare/v1.5.0...v1.6.0

v1.5.0

2 years ago

New Sentences 💌

  • HDG - Heading, Deviation & Variation (#87)
  • HDM - Heading - Magnetic (#87)
  • MTW - Mean Temperature of Water (#87)
  • ROT - Rate of turn (#87)
  • TXT - Transmission of text messages (#87)
  • PHTRO - (Proprietary) Vessel pitch and roll (Xsens IMU/VRU/AHRS) (#87)
  • PRDID - (Proprietary) Vessel pitch, roll and heading (Xsens IMU/VRU/AHRS) (#87)
  • PSONCMS - (Proprietary) Quaternion, acceleration, rate of turn, magnetic field, sensor temperature (Xsens IMU/VRU/AHRS) (#87)

Enhancements 🎉

  • Add NMEA 2.3/4.0 related field (FAA mode and Navigation status) (#87)
  • Improved docs with formats, examples and links (#87)
  • GLL - added FAA mode field (NMEA 2.3+) (#87)
  • GNS - added Navigation status field (NMEA 4.1+) (#87)
  • GSA - added System ID field (NMEA 4.1+) (#87)
  • GSV - added System ID field (NMEA 4.1+) (#87)
  • RMC - added FAA Mode (NMEA 2.3+) and Navigaton status (NMEA 4.1+) fields (#87)
  • VTG - added FAA mode field (NMEA 2.3+) (#87)
  • Added Makefile to make testing/checking easier from command line (#87)

Thank you! 🥇

@aldas

Full Changelog: https://github.com/adrianmo/go-nmea/compare/v1.4.2...v1.5.0

v1.4.2

2 years ago

Enhancements 🎉

  • Allow omitting the DPT scale field (#84)
  • Add specific error type (NotSupportedError) when parsing not supported sentence (#85)

Thank you! 🥇

@aldas @icholy

Full Changelog: https://github.com/adrianmo/go-nmea/compare/v1.4.1...v1.4.2

v1.4.1

2 years ago

Bug fix 🐛

  • GSV failure when no satellite in view (#82)

Thank you! 🥇

@bezineb5 @icholy

v1.4.0

2 years ago

New Sentences 💌

  • MDA - Meteorological Composite (#81)
  • MWD - Wind Direction and Speed (#81)
  • MWV - Wind Speed and Angle (#81)

Thank you! 🥇

@Maescool @icholy

v1.3.0

3 years ago

New features

TAG Block struct

type TagBlock struct {
	Time         int64  // TypeUnixTime unix timestamp (unit is likely to be s, but might be ms, YMMV), parameter: -c
	RelativeTime int64  // TypeRelativeTime relative time, parameter: -r
	Destination  string // TypeDestinationID destination identification 15 char max, parameter: -d
	Grouping     string // TypeGrouping sentence grouping, parameter: -g
	LineCount    int64  // TypeLineCount line count, parameter: -n
	Source       string // TypeSourceID source identification 15 char max, parameter: -s
	Text         string // TypeTextString valid character string, parameter -t
}

Ref.: https://github.com/adrianmo/go-nmea/blob/master/tagblock.go#L10

Code example

NMEA 4.10 TAG Block values can be accessed via the message's TagBlock struct:

package main

import (
	"fmt"
	"log"
	"time"
	"github.com/adrianmo/go-nmea"
)

func main() {
	sentence := "\\s:Satelite_1,c:1553390539*62\\!AIVDM,1,1,,A,13M@ah0025QdPDTCOl`K6`nV00Sv,0*52"
	s, err := nmea.Parse(sentence)
	if err != nil {
		log.Fatal(err)
	}
	parsed := s.(nmea.VDMVDO)
	fmt.Printf("TAG Block timestamp: %v\n", time.Unix(parsed.TagBlock.Time, 0))
	fmt.Printf("TAG Block source:    %v\n", parsed.TagBlock.Source)
}

Output (locale/time zone dependent):

$  go run main/main.go
 
TAG Block timestamp: 2019-03-24 14:22:19 +1300 NZDT
TAG Block source:    Satelite_1

Thank you!

@klyve @simeonmiteff @icholy

v1.2.0

4 years ago

Deprecation

Message parsing is now talker-agnostic, i.e., it is based on the sentence data type only. For a sentence like $XXYYY,220516,A,23,5133.82,W*42, where XX is the talker and YYY is the sentence data type, the parser will only account for the YYY data type, which is what defines the structure and format of the sentence.

In your code, given a sentence like the following:

sentence := "$GPRMC,220516,A,5133.82,N,00042.24,W,173.8,231.8,130694,004.2,W*70"

Instead of using the old, deprecated prefixes (e.g. nmea.PrefixGPRMC) that included the talked ID and the data type:

s, _ := nmea.Parse(sentence)

// Deprecated nmea.PrefixGPRMC, use nmea.TypeRMC instead
if s.Prefix() == nmea.PrefixGPRMC {
    m := s.(nmea.GPRMC)
    fmt.Printf("Validity: %s\n", m.Validity)
    ...
}

Use the DataType() sentence method to determine the parsed sentence data type and then cast it to the right type:

s, _ := nmea.Parse(sentence)

if s.DataType() == nmea.TypeRMC {
    m := s.(nmea.RMC)
    fmt.Printf("Validity: %s\n", m.Validity)
    ...
}

New features

  • Ability to register custom message parsers to allow parsing of sentence types that are currently not supported by the library [link].

New sentences

  • GNS - Combined GPS fix for GPS, Glonass, Galileo, and BeiDou
  • THS - Actual vessel heading in degrees True and status
  • VDM/VDO - Encapsulated binary payload
  • WPL - Waypoint location
  • RTE - Route
  • VHW - Water Speed and Heading
  • DPT - Depth of Water
  • DBS - Depth Below Surface
  • DBT - Depth below transducer

Thank you!

@icholy @bmurray @sthorshaug @BertoldVdb @kvartborg @krasi-georgiev @krawczyk87 @yavosh

v1.1.0

5 years ago

New Sentences

  • GPHDT - Actual vessel heading in degrees True (#34)