![Digi XGI-20CZ7-E00-W0 User Manual Download Page 80](http://html1.mh-extra.com/html/digi/xgi-20cz7-e00-w0/xgi-20cz7-e00-w0_user-manual_2496341080.webp)
Program XBee Industrial Gateway using
Python
XBee Industrial Gateway Python application and Remote
Manager
Digi XBee Industrial Gateway
80
8. From a web browser, log in to
9. Click
Documentation
and then click
API Explorer
. API console appears.
10. From the API console, select
POST HTTP Method
and write the following SCI request that
includes the
set_digital_output
command. The
set_digital_output
command will be sent to
the remote XBee node within the RCI
do_command
element, as follows:
<sci_request version="1.0">
<send_message>
<targets>
<device id="{device_id}"/>
</targets>
<rci_request version="1.1">
<do_command target="xbgw">
<set_digital_output addr="{xbee_mac}" name="DIO4">low</set_
digital_output>
</do_command>
</rci_request>
</send_message>
</sci_request>
Where:
n
{device_id}
is the ID of your XBee Industrial Gateway device.
n
{xbee_mac}
is the MAC address of the XBee node that you attached to your computer.
For example:
<sci_request version="1.0">
<send_message>
<targets>
<device id="00000000-00000000-00409dff-ff5c3BBd"/>
</targets>
<rci_request version="1.1">
<do_command target="xbgw">
<set_digital_output addr="0013A2004031A8E1"
name="DIO4">low</set_digital_output>
</do_command>
</rci_request>
</send_message>
</sci_request>
The
set_digital_output
command sets the value of the
DIO4
to
low
, which will turn
ON
the
User LED 4 (DS4)
of the board.
11. Click
Send
.