|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.rapplogic.xbee.api.XBeeResponse
com.rapplogic.xbee.api.zigbee.ZNetRxBaseResponse
com.rapplogic.xbee.api.zigbee.ZNetRxIoSampleResponse
public class ZNetRxIoSampleResponse
Series 2 XBee. Represents an I/O Sample response sent from a remote radio. Provides access to the XBee's 4 Analog (0-4), 11 Digital (0-7,10-12), and 1 Supply Voltage pins
Note: Series 2 XBee does not support multiple samples (IT) per packet
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.rapplogic.xbee.api.zigbee.ZNetRxBaseResponse |
---|
ZNetRxBaseResponse.Option |
Constructor Summary | |
---|---|
ZNetRxIoSampleResponse()
|
Method Summary | |
---|---|
boolean |
containsAnalog()
Returns true if this sample contains data from analog inputs or supply voltage How does supply voltage get enabled?? See manual page 68 for byte bit mapping |
boolean |
containsDigital()
Returns true if this sample contains data from digital inputs See manual page 68 for byte bit mapping |
java.lang.Integer |
getAnalog(int pin)
Returns a 10 bit value of ADC line 0, if enabled. |
java.lang.Integer |
getAnalog0()
Consider using getAnalog(pin) instead |
java.lang.Integer |
getAnalog1()
|
java.lang.Integer |
getAnalog2()
|
java.lang.Integer |
getAnalog3()
|
int |
getAnalogChannelMask()
|
int |
getDigitalChannelMaskLsb()
|
int |
getDigitalChannelMaskMsb()
|
java.lang.Integer |
getDioLsb()
Returns the DIO LSB, only if sample contains digital; null otherwise |
java.lang.Integer |
getDioMsb()
Returns the DIO MSB, only if sample contains digital; null otherwise |
java.lang.Integer |
getSupplyVoltage()
|
boolean |
isA0Enabled()
Consider using isAnalogEnable(pin) instead |
boolean |
isA1Enabled()
|
boolean |
isA2Enabled()
|
boolean |
isA3Enabled()
|
boolean |
isAnalogEnabled(int pin)
|
boolean |
isD0Enabled()
Consider using isDigitalEnabled(pin) instead |
java.lang.Boolean |
isD0On()
Consider using isDigitalOn(pin) |
boolean |
isD10Enabled()
|
java.lang.Boolean |
isD10On()
|
boolean |
isD11Enabled()
|
java.lang.Boolean |
isD11On()
|
boolean |
isD12Enabled()
|
java.lang.Boolean |
isD12On()
|
boolean |
isD1Enabled()
|
java.lang.Boolean |
isD1On()
|
boolean |
isD2Enabled()
|
java.lang.Boolean |
isD2On()
|
boolean |
isD3Enabled()
|
java.lang.Boolean |
isD3On()
|
boolean |
isD4Enabled()
|
java.lang.Boolean |
isD4On()
|
boolean |
isD5Enabled()
|
java.lang.Boolean |
isD5On()
|
boolean |
isD6Enabled()
|
java.lang.Boolean |
isD6On()
|
boolean |
isD7Enabled()
|
java.lang.Boolean |
isD7On()
|
boolean |
isDigitalEnabled(int pin)
|
java.lang.Boolean |
isDigitalOn(int pin)
If digital I/O line (DIO0) is enabled: returns true if digital 0 is HIGH (ON); false if it is LOW (OFF). |
boolean |
isSupplyVoltageEnabled()
(from the spec) The voltage supply threshold is set with the V+ command. |
void |
parse(IPacketParser parser)
All subclasses must implement to parse the packet from the input stream. |
void |
parseIoSample(IIntInputStream parser)
This method is a bit non standard since it needs to parse an IO sample from either a RX response or a Remote AT/Local AT response (IS). |
static ZNetRxIoSampleResponse |
parseIsSample(AtCommandResponse response)
|
void |
setAnalog0(java.lang.Integer analog0)
|
void |
setAnalog1(java.lang.Integer analog1)
|
void |
setAnalog2(java.lang.Integer analog2)
|
void |
setAnalog3(java.lang.Integer analog3)
|
void |
setSupplyVoltage(java.lang.Integer supplyVoltage)
|
java.lang.String |
toString()
|
Methods inherited from class com.rapplogic.xbee.api.zigbee.ZNetRxBaseResponse |
---|
getOption, getRemoteAddress16, getRemoteAddress64, parseAddress, parseOption, setOption, setRemoteAddress16, setRemoteAddress64 |
Methods inherited from class com.rapplogic.xbee.api.XBeeResponse |
---|
equals, finish, getApiId, getChecksum, getLength, getPacketBytes, getProcessedPacketBytes, getRawPacketBytes, hashCode, isError, setApiId, setChecksum, setError, setLength, setRawPacketBytes |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ZNetRxIoSampleResponse()
Method Detail |
---|
public static ZNetRxIoSampleResponse parseIsSample(AtCommandResponse response) throws java.io.IOException
java.io.IOException
public void parse(IPacketParser parser) throws java.io.IOException
XBeeResponse
parse
in class XBeeResponse
java.io.IOException
public void parseIoSample(IIntInputStream parser) throws java.io.IOException
ps
-
java.io.IOException
public int getDigitalChannelMaskMsb()
public int getDigitalChannelMaskLsb()
public int getAnalogChannelMask()
public boolean isD0Enabled()
public boolean isD1Enabled()
public boolean isD2Enabled()
public boolean isD3Enabled()
public boolean isD4Enabled()
public boolean isD5Enabled()
public boolean isD6Enabled()
public boolean isD7Enabled()
public boolean isD10Enabled()
public boolean isD11Enabled()
public boolean isD12Enabled()
public boolean isA0Enabled()
public boolean isA1Enabled()
public boolean isA2Enabled()
public boolean isA3Enabled()
public boolean isDigitalEnabled(int pin)
public boolean isAnalogEnabled(int pin)
public boolean isSupplyVoltageEnabled()
public java.lang.Boolean isD0On()
public java.lang.Boolean isD1On()
public java.lang.Boolean isD2On()
public java.lang.Boolean isD3On()
public java.lang.Boolean isD4On()
public java.lang.Boolean isD5On()
public java.lang.Boolean isD6On()
public java.lang.Boolean isD7On()
public java.lang.Boolean isD10On()
public java.lang.Boolean isD11On()
public java.lang.Boolean isD12On()
public java.lang.Boolean isDigitalOn(int pin)
public boolean containsDigital()
public boolean containsAnalog()
public java.lang.Integer getDioMsb()
public java.lang.Integer getDioLsb()
public java.lang.Integer getAnalog0()
public void setAnalog0(java.lang.Integer analog0)
public java.lang.Integer getAnalog1()
public void setAnalog1(java.lang.Integer analog1)
public java.lang.Integer getAnalog2()
public void setAnalog2(java.lang.Integer analog2)
public java.lang.Integer getAnalog3()
public void setAnalog3(java.lang.Integer analog3)
public java.lang.Integer getAnalog(int pin)
public java.lang.Integer getSupplyVoltage()
public void setSupplyVoltage(java.lang.Integer supplyVoltage)
public java.lang.String toString()
toString
in class ZNetRxBaseResponse
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |