|
Terrenus HRPT v2.2 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectterrenus.telemetry.CHRPTDecoder
public class CHRPTDecoder
The CHRPTDecoder
class uses a CHRPTStream
to
decode CMA CHRPT data.
Constructor Summary | |
---|---|
CHRPTDecoder(CHRPTStream stream)
Create a new decoder using the specified stream. |
Method Summary | |
---|---|
int |
getAuxSyncErrors(int frame)
Gets the number of errors in the frame auxiliary sync bits, or 0 if no errors are present. |
InstrumentData |
getData(int frame,
Instrument inst)
Gets the frame data for a specific instrument. |
int |
getDayCount(int frame)
Gets the frame day count. |
int |
getFrameSyncErrors(int frame)
Gets the number of errors in the frame sync bits, or 0 if no errors are present. |
int |
getMillisecond(int frame)
Gets the frame millisecond. |
static int |
getMillisecond(short[] timeCode)
Gets the millisecond based on CHRPT time code data. |
Spacecraft |
getSpacecraft()
Gets the spacecraft detected by this decoder. |
int |
getSpacecraftId()
Gets the spacecraft address identified for this CHRPT data. |
int |
getSpacecraftId(int frame)
Gets the spacecraft address for the frame. |
CHRPTStream |
getStream()
Gets the telemetry stream used for data. |
long |
getTime(int frame)
Gets the start time of frame capture in milliseconds since the epoch. |
boolean |
hasErrors(int frame)
Gets the frame error flag. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CHRPTDecoder(CHRPTStream stream) throws java.io.IOException
java.io.IOException
Method Detail |
---|
public boolean hasErrors(int frame) throws java.io.IOException
TelemetryDecoder
hasErrors
in interface TelemetryDecoder
frame
- the frame to return the flag for in the range
[0..FRAMES-1].
java.io.IOException
- if an error occurred reading data from the
stream.public CHRPTStream getStream()
TelemetryDecoder
getStream
in interface TelemetryDecoder
public int getFrameSyncErrors(int frame)
public long getTime(int frame)
getDayCount(int)
and getMillisecond(short[])
since some frames may
have bit errors. The actual frame time is computed by examining
a number of frame times, inferring the correct data start time
from those times, and then computing the frame time using the
frame index and the known frame step interval. This presents the
CHRPT data as a continuous, uniformly stepping set of frames and
is very useful for computing correct Earth locations for every
sensor scan even when the frame itself contains unusable sensor
data.
getTime
in interface TelemetryDecoder
frame
- the frame to return the time for, starting at 0.
public int getSpacecraftId()
getSpacecraftId(int)
since some frames may have bit errors.
The actual spacecraft address is detected by examining a number
of CHRPT minor frames.
public int getSpacecraftId(int frame) throws java.io.IOException
java.io.IOException
public int getDayCount(int frame) throws java.io.IOException
java.io.IOException
public static int getMillisecond(short[] timeCode)
timeCode
- the time code data as an array of four short
values.
public int getMillisecond(int frame) throws java.io.IOException
java.io.IOException
public int getAuxSyncErrors(int frame)
public InstrumentData getData(int frame, Instrument inst) throws java.io.IOException
TelemetryDecoder
getData
in interface TelemetryDecoder
frame
- the frame to return data for in the range
[0..FRAMES-1].inst
- the instrument to return data for.
java.io.IOException
- if an error occurred reading the instrument
data from the stream.public Spacecraft getSpacecraft()
TelemetryDecoder
getSpacecraft
in interface TelemetryDecoder
|
Terrenus HRPT v2.2 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |