public class MicE extends PositionMessage implements SendableMessage
AX25Message.Precedence
abc, altitude, altitudeUnit, COMPRESSED_LAT_SCALING, CONV_MPH_TO_METERS_PER_SEC, DHM, enabledForTransmit, encodeCompressed, fLatitude, fLatPrecision, fLongitude, fmtMonitorFreq, HMS, HUNDREDTH_MINUTE_F, isCustom, latitude, LN_BASE1_08, longitude, ONE_DEGREE_F, ONE_MINUTE_F, TEN_MINUTES_F, TENTH_MINUTE_F
appendCR, APRS_AND_OPENTRAC_AND_RAW, APRS_AND_RAW, comment, msgType, S_PERMANENT, S_PERMANENT_UC, symbolCode, symTableId
APRS_AND_OPENTRAC, ax25Frame, extensions, invalid, originatingCallsign, originatingDest, PERMANENT, rcptTime, thirdParty, timestamp, UTC
Constructor and Description |
---|
MicE(byte[] body,
int offset,
java.lang.String thirdParty,
AX25Callsign dest,
long rcvTimestamp)
Decode a Mic-E message from a byte array,
|
MicE(long now)
Alternate constructor for creating a locally-originated MicE message.
|
Modifier and Type | Method and Description |
---|---|
void |
disableForTransmit()
Specify that message should no longer be transmitted.
|
static java.lang.String |
encodeDestination(double latitude,
double longitude,
byte status,
boolean isCustom)
Build the tocall destination "callsign" for a Mic-E message, containing the latitude, the status,
and part of the longitude information.
|
byte[] |
getBody(boolean countTransmission,
ProtocolFamily protocolId,
AX25Frame frame)
Get an instance of this message, suitable for transmitting.
|
char |
getMicETypeCode()
Get the Mic-E type code of the transmitter (if one exists).
|
AX25Message.Precedence |
getPrecedence()
Report the traffic-handling precedence for this message instance.
|
java.lang.String |
getRadioModel()
Get the model string (if any) decoded from the Mic-E model type codes in the free-text field.
|
static boolean |
isUseExperimentalYAACModelCode()
Test whether locally-generated Mic-E messages should use an experimental
model code for YAAC.
|
java.lang.String |
paramString()
Descriptive text about this message, to be included in the toString() method's response.
|
static void |
setUseExperimentalYAACModelCode(boolean useExperimentalYAACModelCode)
Specify whether locally-generated Mic-E messages should use an experimental
model code for YAAC.
|
appendAreaParameters, appendRepeaterParameters, appendSignpostParameters, bodyEquals, createObjectFromThisPosition, decodeDataExtension, decodeLatitude, decodeLongitude, decodeOnlyLatitude, decodeOnlyLongitude, encodeLatitudeCompressed, encodeLatitudePlainText, encodeLongitudeCompressed, encodeLongitudePlainText, extractCompressedLatitude, extractCompressedLongitude, extractLatitude, extractLongitude, getAbc, getAltitude, getAltitudeUnit, getHorizontalAccuracy, getLatitude, getLatitudeAccuracy, getLongitude, getPositionAltitude, getPositionLatitude, getPositionLongitude, getPositionTime, hasPosition, isCustom, isEnabled, isShowDate, isUsingCompressedFormat, looksLikeFrequency, looksLikeFrequency, setAbc, setAmbiguity, setCustom, setLatitude, setLocation, setLongitude, setShowDate, testIfValidCompressedLocation
compareTo, decodeDatestamp, decodeHurricaneParams, decodeTimestamp, decodeWeatherParams, decodeWeatherParams, dup, encodeTimestamp, extractComment, extractComment, extractSymbol, formatBody, getComment, getExtensionString, getMsgType, getProtocols, getSymbolCode, getSymTableId, hasWeather, inferSymbol, isAppendCR, isSymbolInferred, looksLikeLongFormatLatitude, setAppendCR, setComment, setSymbolCode, setSymTableId, toString
equals, extractSource, getAx25Frame, getExtension, getFirstDigipeat, getLastDigipeat, getNthDigipeat, getOriginalDestination, getOriginalSource, getOriginatingCallsign, getOriginatingDest, getRcptTime, getReadOnlyExtensionMap, getTimestamp, hashCode, hasThisFirstDigi, indexOf, indexOf, isDirect, isInvalid, isRf, onlyDigits, onlyDigits, onlyDigitsOrMinus, onlyDigitsOrPeriod, onlyDigitsOrSpace, onlyDigitsPlus, onlyPeriods, setAx25Frame, setInvalid, setOriginatingCallsign, setRcptTime, setTimestamp, split, storeExtension
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
dup, isEnabled
public MicE(byte[] body, int offset, java.lang.String thirdParty, AX25Callsign dest, long rcvTimestamp)
body
- byte array containing the Mic-E messageoffset
- index into the byte array where the Mic-E message startsthirdParty
- third-party routing path, or null if not routed from another networkdest
- destination callsign (to extract part of the position and status information from)rcvTimestamp
- time in Java milliseconds since 1 Jan 1970 UTC when this message was receivedpublic MicE(long now)
now
- current time in milliseconds since midnight Jan 1 1970 UTCpublic java.lang.String paramString()
paramString
in class PositionMessage
Message.toString()
public java.lang.String getRadioModel()
public AX25Message.Precedence getPrecedence()
getPrecedence
in class Message
public static java.lang.String encodeDestination(double latitude, double longitude, byte status, boolean isCustom)
latitude
- latitude in fractional degrees Northlongitude
- longitude in fractional degrees Eaststatus
- Mic-E status code in the range 0 to 7isCustom
- boolean true if this is a custom status code instead of a standard status codepublic byte[] getBody(boolean countTransmission, ProtocolFamily protocolId, AX25Frame frame)
getBody
in interface SendableMessage
countTransmission
- number of times the message has been transmitted.protocolId
- ProtocolFamily to generate the message in; currently,
only APRS and OPENTRAC are supported.frame
- AX25Frame into which the message will be placed; the decoded message (as opposed to the byte
array encoding) should be stored into the field frame.parsedAX25MsgAX25Frame.parsedAX25Msg
public void disableForTransmit()
disableForTransmit
in interface SendableMessage
public char getMicETypeCode()
public static boolean isUseExperimentalYAACModelCode()
public static void setUseExperimentalYAACModelCode(boolean useExperimentalYAACModelCode)
useExperimentalYAACModelCode
- boolean true if locally originated Mic-E messages have a model code