Queried Sampling - Digi XBee ZNet 2.5 Product Manual

Oem rf modules
Table of Contents

Advertisement

Table 12:
Bytes
Name
Analog
1
Channel
Mask
Sampled
Variable
Data Set
The sampled data set will include 2 bytes of digital IO data only if one or more IO lines on the device
are configured as digital IO. If no pins are configured as digital IO, these 2 bytes will be omitted.
The digital IO data is only relevant if the same bit is enabled in the digital IO mask as shown in the
following figure:
Analog samples are returned as 10-bit values. The analog reading is scaled such that 0x0000
represents 0V, and 0x3FF = 1.2V. (The analog inputs on the module cannot read more than 1.2V.)
Analog samples are returned in order starting with AIN0 and finishing with AIN3, and the supply
voltage. Only enabled analog input channels return data as shown in the figure below.
To convert the A/D reading to mV, do the following: AD(mV)= (ADIO reading/0x3FF)*1200mV
The reading in the sample frame represent voltage inputs of 1144.9 and 342.5mV for ADIO0 and
ADIO1 respectively.

Queried sampling

The IS command can be sent to a device locally, or to a remote device using the API remote command
frame (see Chapter 8 for details). When the IS command is sent, the receiving device samples all
enabled digital IO and analog input channels and returns an IO sample. If IS is sent locally, the IO
sample is sent out the UART. If the IS command was received as a remote command, the IO sample is
sent over-the-air to the device that sent the IS command.
If the IS command is issued in AT firmware, the module returns a carriage return-delimited list
containing the above-listed fields. The API firmware returns an AT command response packet with
the IO data included in the command data portion of the response frame.
The following table shows an example of the fields in an IS response.
XBee ZNet 2.5 / XBee PRO Znet 2.5 OEM RF Modules Product Manual
Description
Indicates which lines have analog inputs enabled for sampling. Each bit in the analog
channel mask corresponds to one analog input channel.
bit 0 = AD0/DIO0
bit 1 = AD1/DIO1
bit 2 = AD2/DIO2
bit 3 = AD3/DIO3
bit 7 = Supply Voltage
A sample set consisting of 1 sample for each enabled ADC and/or DIO channel.
If any digital IO lines are enabled, the first two bytes of the data set indicate the state
of all enabled digital IO. Only digital channels that are enabled in the Digital Channel
Mask bytes have any meaning in the sample set. If no digital IO are enabled on the
device, these 2 bytes will be omitted.
Following the digital IO data (if any), each enabled analog channel will return 2 bytes.
The data starts with AIN0 and continues sequentially for each enabled analog input
channel up to AIN3, and the supply voltage (if enabled) at the end.
IO line monitoring
49

Advertisement

Table of Contents
loading

This manual is also suitable for:

Xbee pro znet 2.5

Table of Contents