edu.uiuc.cs.seclab.modem.xbee.cmd
Class XBeeEnergyDetectCmd

java.lang.Object
  extended by edu.uiuc.cs.seclab.modem.xbee.XBeeAtCmd
      extended by edu.uiuc.cs.seclab.modem.xbee.XBeeSpecialCmd
          extended by edu.uiuc.cs.seclab.modem.xbee.cmd.XBeeEnergyDetectCmd

public class XBeeEnergyDetectCmd
extends XBeeSpecialCmd

ATED - Scan channels for activity


Nested Class Summary
 
Nested classes/interfaces inherited from class edu.uiuc.cs.seclab.modem.xbee.XBeeAtCmd
XBeeAtCmd.Mode
 
Field Summary
static java.lang.String CMD
           
protected  byte duration
          Scan duration per channel
static int SLACK
           
protected  long startTm
           
 
Constructor Summary
XBeeEnergyDetectCmd(byte duration_)
           
 
Method Summary
protected  java.lang.String getApiParams()
          Convert the parameters associated with this command to a binary API-format buffer suitable for transmission to the modem.
 java.lang.String getAtCmd()
          Get the two-character AT code associated with this command.
 java.lang.String getShortDesc()
          Return a short (one-line) description for command suitable for display in parameter table.
 long processResp(XBeeAtRespPacketImpl impl, XBeeAtCmd.Mode mode)
          Process a response to an AT command and return a bound in milliseconds on when all expected responses will be received.
 java.lang.Object unmarshalRespParams(java.lang.String params)
          Unmarshal the parameters returned from API command
 
Methods inherited from class edu.uiuc.cs.seclab.modem.xbee.XBeeAtCmd
getPktImpl
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CMD

public static final java.lang.String CMD
See Also:
Constant Field Values

duration

protected byte duration
Scan duration per channel


SLACK

public static final int SLACK
See Also:
Constant Field Values

startTm

protected long startTm
Constructor Detail

XBeeEnergyDetectCmd

public XBeeEnergyDetectCmd(byte duration_)
                    throws ModemException
Throws:
ModemException
Method Detail

getApiParams

protected java.lang.String getApiParams()
Description copied from class: XBeeAtCmd
Convert the parameters associated with this command to a binary API-format buffer suitable for transmission to the modem.

Overrides:
getApiParams in class XBeeSpecialCmd

getAtCmd

public java.lang.String getAtCmd()
Description copied from class: XBeeAtCmd
Get the two-character AT code associated with this command.

Specified by:
getAtCmd in class XBeeAtCmd

getShortDesc

public java.lang.String getShortDesc()
Description copied from class: XBeeAtCmd
Return a short (one-line) description for command suitable for display in parameter table.

Specified by:
getShortDesc in class XBeeAtCmd

processResp

public long processResp(XBeeAtRespPacketImpl impl,
                        XBeeAtCmd.Mode mode)
                 throws ModemException
Description copied from class: XBeeAtCmd
Process a response to an AT command and return a bound in milliseconds on when all expected responses will be received. Most commands only accept a single response, so we return 0 by default, indicating that processing has completed. Should be overridden in subclasses that expect multiple responses.

Overrides:
processResp in class XBeeAtCmd
Throws:
ModemException

unmarshalRespParams

public java.lang.Object unmarshalRespParams(java.lang.String params)
                                     throws ModemException
Description copied from class: XBeeAtCmd
Unmarshal the parameters returned from API command

Overrides:
unmarshalRespParams in class XBeeSpecialCmd
Throws:
ModemException