User Guide

1 2 3 4 5 6
7
8 9
Configuring Digital I/Os
INfinity 610 User’s Guide
71
Example (Input)
The following example triggers a series of modem commands, when DIO
input 4 goes high.
modem.dio.in.4.positive_level = RUN_SCRIPT
modem.dio.in.4.script.num_cmds = 3
modem.dio.in.4.script.cmd1 = "modem.antennas.perform_check()"
modem.dio.in.4.script.cmd2 = "modem.diag.current_temperature"
modem.dio.in.4.script.cmd3 = "modem.stats.tag_read"
Example (Output)
In the following example, DIO output 3 will trigger low when the reader is in
active mode.
dio.control.3 = modem
modem.dio.out.3.op = ACTIVE_MODE
modem.dio.out.3.polarity = NEGATIVE
7.4. Digital I/O Monitoring and Control Scripts
Several digital I/O monitoring and control scripts are provided with the
reader to allow you to monitor the digital I/Os and take specific actions.
These Python application scripts can be used as is or modified to suit your
particular application. For detailed information on loading Python scripts,
refer to Chapter 5 – Embedded Reader Applications of the INfinity 610
Protocol Reference Guide.
7.4.1. scan_trigger.py
This routine monitors the state of the digital input pin specified as the input
parameter. If the state of the pin is low, the operating mode is set to standby. If
the I/O pin state changes to high, the operating mode is set to active.
Inputs: <pin> – (optional) Input pin number (1–4). Default is digital in 1.
<trigger logic level> –(optional) 0 or 1. Default is trigger on 1.
Examples:
scan_trigger.py Monitors digital input pin 1
scan_trigger.py 1 Monitors digital input pin 1
scan_trigger.py 4 Monitors digital input pin 4
scan_trigger.py 3 0 Monitors digital input pin 3, trigger on 0