net.sf.marineapi.nmea.sentence
Interface VHWSentence

All Superinterfaces:
HeadingSentence, Sentence

public interface VHWSentence
extends HeadingSentence

Water speed and heading in respect to true and magnetic north.

Example:
$IIVHW,,,213,M,0.00,N,,K*2F

Author:
Warren Zahra, Kimmo Tuukkanen

Field Summary
 
Fields inherited from interface net.sf.marineapi.nmea.sentence.Sentence
ALTERNATIVE_BEGIN_CHAR, BEGIN_CHAR, CHECKSUM_DELIMITER, FIELD_DELIMITER, MAX_LENGTH, TERMINATOR
 
Method Summary
 double getMagneticHeading()
          Returns the current magnetic heading.
 double getSpeedKmh()
          Returns the current water speed.
 double getSpeedKnots()
          Returns the current water speed.
 void setMagneticHeading(double hdg)
          Sets the magnetic heading.
 void setSpeedKmh(double kmh)
          Sets the water speed in km/h.
 void setSpeedKnots(double knots)
          Sets the water speed in knots.
 
Methods inherited from interface net.sf.marineapi.nmea.sentence.HeadingSentence
getHeading, isTrue, setHeading
 
Methods inherited from interface net.sf.marineapi.nmea.sentence.Sentence
getBeginChar, getFieldCount, getSentenceId, getTalkerId, isProprietary, isValid, reset, setBeginChar, setTalkerId, toSentence, toSentence, toString
 

Method Detail

getMagneticHeading

double getMagneticHeading()
Returns the current magnetic heading.

Returns:
Heading in degrees magnetic.

getSpeedKmh

double getSpeedKmh()
Returns the current water speed.

Returns:
Speed in km/h (kilmetres per hour)

getSpeedKnots

double getSpeedKnots()
Returns the current water speed.

Returns:
Speed in knots (nautical miles per hour)

setMagneticHeading

void setMagneticHeading(double hdg)
Sets the magnetic heading.

Parameters:
hdg - Heading in degrees magnetic.
Throws:
IllegalArgumentException - If value is out of bounds [0..360]

setSpeedKmh

void setSpeedKmh(double kmh)
Sets the water speed in km/h.

Parameters:
kmh - Speed in kilmetres per hour.

setSpeedKnots

void setSpeedKnots(double knots)
Sets the water speed in knots.

Parameters:
knots - Speed in knots (nautical miles per hour)


Copyright (C) 2010-2014 Java Marine API authors. All Rights Reserved.