public class GPS extends SimpleGPS
Modifier and Type | Field and Description |
---|---|
private java.util.Date |
date |
private GSVSentence |
gsvSentence |
private RMCSentence |
rmcSentence |
ggaSentence, gsaSentence, vtgSentence
Constructor and Description |
---|
GPS(java.io.InputStream in)
The constructor.
|
Modifier and Type | Method and Description |
---|---|
float |
getCompassDegrees()
Return Compass Degrees
in a range: 0.0-359.9
|
java.util.Date |
getDate()
Return a Date Object with data from GGA and RMC NMEA Sentence
|
Satellite |
getSatellite(int index)
Get NMEA Satellite.
|
int |
getSatellitesInView()
The satellites in view is a list of satellites the GPS could theoretically connect to (i.e.
|
int |
getSatellitesTracked()
Returns the number of satellites being tracked to
determine the coordinates.
|
protected void |
sentenceChooser(java.lang.String header,
java.lang.String s)
Internal helper method to aid in the subclass architecture.
|
private void |
updateDate()
Update Date values
|
private void |
updateTime()
Update Time values
|
addListener, close, getAltitude, getCourse, getFixMode, getFixType, getHDOP, getLatitude, getLatitudeDirection, getLongitude, getLongitudeDirection, getPDOP, getPRN, getSelectionType, getSpeed, getTimeStamp, getVDOP, notifyListeners, removeListener, run
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
private RMCSentence rmcSentence
private GSVSentence gsvSentence
private java.util.Date date
public GPS(java.io.InputStream in)
in
- An input stream from the GPS receiverpublic float getCompassDegrees()
public java.util.Date getDate()
public Satellite getSatellite(int index)
index
- the satellite indexpublic int getSatellitesTracked()
getSatellitesTracked
in class SimpleGPS
public int getSatellitesInView()
protected void sentenceChooser(java.lang.String header, java.lang.String s)
sentenceChooser
in class SimpleGPS
header
- s
- private void updateTime()
private void updateDate()