DI-1100 USB Data Acquisition (DAQ) System Communication Protocol

Similar documents
EE 314 Spring 2003 Microprocessor Systems

LC-10 Chipless TagReader v 2.0 August 2006

Stensat Transmitter Module

Debugging a Boundary-Scan I 2 C Script Test with the BusPro - I and I2C Exerciser Software: A Case Study

Cost efficient design Operates in full sunlight Low power consumption Wide field of view Small footprint Simple serial connectivity Long Range

Cost efficient design Operates in full sunlight Low power consumption Wide field of view Small footprint Simple serial connectivity Long Range

PC-based controller for Mechatronics System

Creating Arbitrary Waveforms in the U2300A Series and U2500A Series Data Acquisition Devices

DTMF Signal Detection Using Z8 Encore! XP F64xx Series MCUs

Understanding the Arduino to LabVIEW Interface

Mate Serial Communications Guide This guide is only relevant to Mate Code Revs. of 4.00 and greater

745 Transformer Protection System Communications Guide

5008 Dual Synthesizer Configuration Manager User s Guide (admin Version) Version valontechnology.com

EVDP610 IXDP610 Digital PWM Controller IC Evaluation Board

EE 109 Midterm Review

BMS BMU Vehicle Communications Protocol

User's Manual. ServoCenter 4.1. Volume 2: Protocol Reference. Yost Engineering, Inc. 630 Second Street Portsmouth, Ohio

H8238/MCM MODBUS POINT MAP

ROTRONIC HygroClip Digital Input / Output

TIP500. Optically Isolated 16 Channel 12 Bit ADC. Version 1.1. User Manual. Issue January 2010

TCSS 372 Laboratory Project 2 RS 232 Serial I/O Interface

BusWorks 900EN Series Modbus TCP/IP 10/100M Industrial Ethernet I/O Modules

Carbon Dioxide (Tiny CO2) Gas Sensor. Rev TG400 User Manual

Model: ADC-x/DIG-x. RS-232 / RS-485 Data Acquisition Digital I/O v2.2 Firmware. SuperLogics. Integrity Instruments. SuperLogics

MTS2500 Synthesizer Pinout and Functions

DI-2108 USB Data Acquisition (DAQ) System

MCT U.I. Driver Reference Manual Motor Control Technologies; LLC

Line-to-line RMS Volts, 3 phases 4 digits (XXX.X) Volts

Article Number: 457 Rating: Unrated Last Updated: Wed, Sep 2, 2009 at 3:46 PM

I-7088, I-7088D, M-7088 and M-7088D User Manual

Copley ASCII Interface Programmer s Guide

TIP551. Optically Isolated 4 Channel 16 Bit D/A. Version 1.1. User Manual. Issue December 2009

Servo Switch/Controller Users Manual

ASCII Programmer s Guide

Hello, and welcome to this presentation of the STM32 Digital Filter for Sigma-Delta modulators interface. The features of this interface, which

ANT Channel Search ABSTRACT

Artifex LIV 110. Laser Diode Characterization System. Engineering

MiniProg Users Guide and Example Projects

Interfacing the 1724-Type Microprocessor-Controlled EDFA via a Serial Communication Port

OHIO SEMITRONICS, INC. DIGITAL AC POWER MONITOR OSI SPECIFICATIONS

SC16A SERVO CONTROLLER

Tarocco Closed Loop Motor Controller

Featherweight GPS Tracker User s Manual June 16, 2017

DI-4208 USB Data Acquisition (DAQ) System

Training Schedule. Robotic System Design using Arduino Platform

ELECTRICAL VARIABLE ANALYZER RELAY EVAR

Mercury technical manual

UART2PPM. User s Guide. Version 2.04 dated 02/20/16. Gregor Schlechtriem

Syntax Identify i Returns an identification string and the firmware revision *Syscomp CircuitGear MKII VX.X Scope Query state

USB 3.1 ENGINEERING CHANGE NOTICE

How to Configure IFOV. Revision: 1.01

Gentec-EO USA. T-RAD-USB Users Manual. T-Rad-USB Operating Instructions /15/2010 Page 1 of 24

EG medlab. Three Lead ECG OEM board. Version Technical Manual. Medlab GmbH Three Lead ECG OEM Module EG01010 User Manual

2F. No.25, Industry E. 9 th Rd., Science-Based Industrial Park, Hsinchu, Taiwan Application Note of OGM220, AN001 V1.8

IP-48ADM16TH. High Density 48-channel, 16-bit A/D Converter. REFERENCE MANUAL Version 1.6 August 2008

Antenna Switch Box. Update, Feb 2012

CDR-915 Data Radio Module INTEGRATOR S GUIDE

IP-OptoAD16. Opto-Isolated 16-bit A/D Conversion IndustryPack. User s Manual

AW900BT. Features Guide. Version 1.0 draft 02 Last revised April 12, 2013

µchameleon 2 User s Manual

SV3C CPTX MIPI C-PHY Generator. Data Sheet

RedPitaya. FPGA memory map

Know your energy. Modbus Register Map EB etactica Power Bar

2320 cousteau court

Parameter Value Unit Notes

BEI Device Interface User Manual Birger Engineering, Inc.

WTPCT-M. eeder. Pulse Counter/Timer Module. Technologies FEATURES SPECIFICATIONS DESCRIPTION. Weeder Technologies

Know your energy. Modbus Register Map EM etactica Power Meter

Image Capture Procedure

Aquisition and Retrieval Performance of the Tektronix TDS 2014 as a Data Logger

Kongsberg Mesotech Ltd.

A word from the author:

Serial Communications Protocol V1.02

Design Implementation Description for the Digital Frequency Oscillator

XC83x AP Application Note. Microcontrollers. intouch Application Kit - Touch Sliders V1.0,

CHAPTER 1 INTRODUCTION...

USB-UT350(T) Portable Ultrasonic Pulser/Receiver and Analog to Digital Converter. User s Guide

Page 1/10 Digilent Analog Discovery (DAD) Tutorial 6-Aug-15. Figure 2: DAD pin configuration

BV4112. Serial Micro stepping Motor Controller. Product specification. Dec V0.a. ByVac Page 1 of 18

CubeSense. An integrated sun and nadir sensor module. User Manual

EE445L Fall 2014 Quiz 2A Page 1 of 5

USB4. Encoder Data Acquisition USB Device Page 1 of 8. Description. Features

SOLAR-360 : 360 Inclinometer, RS232 or RS485 Output

WCS-D5100 Programming Software for the Icom ID-5100 Data

The PmodIA is an impedance analyzer built around the Analog Devices AD bit Impedance Converter Network Analyzer.

TECHNICAL MANUAL UNIVERSAL BOP GPIB VISA INSTRUMENT DRIVER. 1) This manual is valid for the following Model and associated serial numbers:

Using Z8 Encore! XP MCU for RMS Calculation

SCM9B-D100 SERIES USERS MANUAL

How do ADCs work? Martin Rowe, Senior Technical Editor -- 7/1/2002 Test & Measurement World

SSI Technologies - Application Note AT-AN1 Acu-Trac Ultrasonic Fluid Level Sensors Product Overview

Manual IF2008A IF2008E

MAX11300PMB1 Peripheral Module and Munich (USB2PMB1) Adapter Board Quick Start Guide

HOMANN DESIGNS. DigiSpeed. Instruction manual. Version 1.0. Copyright 2004 Homann Designs.

C191HM POWERMETER AND HARMONIC MANAGER COMMUNICATIONS REFERENCE GUIDE

SMARTALPHA RF TRANSCEIVER

EDB9300UE Manual. Oscilloscope function

Topics Introduction to Microprocessors

Non-Packet Time-of-Day Distribution

SonoLab Echo-I User Manual

InsuLogix T MODBUS Protocol Manual

Transcription:

DI-1100 USB Data Acquisition (DAQ) System Communication Protocol DATAQ Instruments Although DATAQ Instruments provides ready-to-run WinDaq software with its DI-1100 Data Acquisition Starter Kits, programmers will want the flexibility to integrate the DI-1100 in the context of their own application To do so they want complete control over DI-1100 hardware, which can be accomplished by using the device at the protocol level This white paper describes how protocol-level programming of the DI-1100 is implemented across the Windows and Linux operating systems We'll define the DI-1100's command set and scan list architecture and finish with a description of the DI-1100's binary response format Windows programmers should consider the using the Net class and a suitable Net programming language as a more efficient method for programming the DI-1100 under that operating system Device Access The DI-1100 can be accessed using the Libusb open source library to control data transfers to and from the instrument via its USB interface in both Windows and non-windows implementations When a DI-1100 is connected to a PC in a Windows implementation the instrument appears in the Device Manager as a "DI- 1100" under the "libusb-win32 devices" tree: The following constants apply to the DI-1100 and must be correctly referenced from your program via Libusb: PID = 1100 16 VID = 0683 16 DI-1100 Command Set Overview The DI-1100 employs a simple ASCII character command set that allows complete control of the instrument All of the commands in the following table must be terminated with a carriage return character (0D 16 ) to be recognized by the instrument Command arguments (if any) are also ASCII, and the command and each argument must be separated by a space character (20 16 ) All commands echo if the instrument is not scanning Command arguments and responses as always in decimal

DI-1100 Command Set ASCII Command Action Basic communication info arg0 ps arg0 Scanning start arg0 stop slist arg0 arg1 srate arg0 LED color led arg0 Echoes the command and argument with additional information as defined by the argument Defines communication packet size Start scanning (never echoes) Stop scanning (always echoes) Defines scan list configuration Defines scan rate Sets the LED to a specified color Command Echo Protocol All commands echo if the instrument is not scanning Commands will not echo while scanning is active to prevent an interruption of the data stream In this sense, the start command never echoes, and the stop command always echoes In all the following descriptions of DI-1100 commands, any descriptions and examples related to a command echo assume that the DI-1100 is not actively scanning Basic Communication Commands The DI-1100 command set supports a number of basic command/response items that provide a simple means to ensure the integrity of the communication link between a program and the instrument These commands elicit simple, yet useful responses from the instrument and should be employed as the programmer's first DI-1100 communication attempt If these commands don't work with a functioning DI- 1100 then a problem exists in the communication chain and further programming efforts will be futile until they are resolved Responses to this set of commands include echoing the command, followed by a space (20 16 ), followed by the response, and ending with a carriage return (0D 16 ) For example: Command: info 1 'what model is connected? Response: info 1 1100 'command echo, plus connected model no Page 2 of 9

DI-1100 Basic Communication Commands ASCII Command Action info 0 Returns "DATAQ" info 1 Returns device name: "1100" info 2 Returns firmware revision, 2 hex bytes (eg 65 16 = 10110 for firmware revision 101) info 3 to info 5 Proprietary internal use for initial system verification info 6 info 7 to info 8 info 9 ps 0 ps 1 ps 2 ps 3 ps 4 ps 5 ps 6 ps 7 Returns the DI-1100's serial number (left-most 8 digits only; right-most two digital are for internal use) Proprietary internal use for initial system verification Returns the sample rate divisor value of 60,000,000 for the DI-1100 (see the srate command for details) Make packet size 16 bytes Make packet size 32 bytes Make packet size 64 bytes Make packet size 128 bytes Make packet size 256 bytes Make packet size 512 bytes Make packet size 1024 bytes Make packet size 2048 bytes The packet size command defines the number of bytes the DI-1100 sends with each transmission burst The larger the packet size the more bytes transmitted per burst Since a packet will not transmit until it is full, you should adjust packet size as a function of both sampling rate and the number of enabled channels to minimize latency when channel count and sample rate are low, and avoid a buffer overflow when sampling rate and channel count are high Command: ps 1 'make packet size 32 bytes Response: ps 1 'command echo Scanning Commands start Command The DI-1100 start commands support an argument that defines the instrument's scanning mode, and initiates scanning accordingly Since a start command immediately initiates scanning, the command is never echoed Page 3 of 9

DI-1100 Start Command Modes ASCII Command start 0 start 1 Action Normal scanning: The instrument begins scanning the channels enabled in its scan list through the slist command at a rate defined by the srate command Reserved for future use Command: start 0 'begin normal scanning Response: 'never echoes stop Command The protocol's stop command terminates scanning Since the stop command terminates scanning, it is always echoed Command: stop 'stop scanning Response: stop 'always echoes slist Command The DI-1100 employs a scan list approach to data acquisition A scan list is an internal schedule (or list) of channels to be sampled in a defined order It is important to note that a scan list defines only the type and order in which data is to be sampled, not the sampled data itself The DI-1100's scan list supports up to four analog channels Analog channels may be placed in the DI-1100's scan list in any order that satisfies the requirements of the application The DI-1100's scan list is a maximum of four elements long, which allows a hardware capacity measurement to sample all four analog channels The state of the DI- 1100's two digital ports is contained in the returned by the analog channel that appears first in the scan list Note that any analog channel may appear in the scan list only once slist positions must be defined sequentially beginning with position 0 During general-purpose use each entry in the scan list is represented by a 16-bit number, which is defined in detail in the DI-1100 Scan List Word Definitions table below Writing any value to the first position of the scan list automatically resets the slist member count to 1 This count increases by 1 each time a new member is added to the list, which must be filled from lowest to highest positions The first item in the scan list initializes to 0 (analog input channel 0) upon power up Therefore, upon power up, and assuming that no changes are applied to the scan list, only analog input channel 0 is sampled when scanning is set to active by the start command Page 4 of 9

The slist command along with two arguments separated by a space character is used to configure the scan list: slist offset config offset defines the index within the scan list and can range from 0 to 10 to address a total of eleven possible positions config is the 16-bit configuration parameter as defined in table DI-1100 Scan List Word Definitions For example, the command slist 5 10 configures the sixth position of the scan list to specify data from the counter Assuming that we wish to sample analog channels 2, 4 the following scan list configuration would work: slist 0 2 slist 1 4 Note that since the act of writing to scan list position 0 resets the slist member counter, the above configuration is complete upon writing scan list position 1 Further any scan list position (except position 0) may be modified without affecting the contents of the rest of the list DI-1100 Scan List Word Definitions * Bit Position Function 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Analog In, Channel 0 0 0 0 0 Analog In, Channel 1 0 0 0 1 All Unused Bits = 0 Analog In, Channel 2 0 0 1 0 Analog In, Channel 3 0 0 1 1 Ignore 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 * To be consistent with general programming standards, analog channel numbers begin with 0 instead of 1 as indicated on the product label Command: slist 0 0 'enabled analog channel 0 Response: slist 0 0 'command echo Command: slist 1 4 'enabled analog channel 4 Page 5 of 9

Response: slist 1 4 'command echo srate Scan rate Command Command srate defines a sample rate divisor used to determine scan rate, or the rate at which the DI- 1100 scans through the items in the scan list that you defined with the slist command srate is specified with an integer (int) argument (the divisor) within the range of 750 to 65,535 inclusive, and the resulting scan speed per scan list element is defined by the following equation: Sample rate per scan list element (Hz) = 60,000,000 srate This approach results in a per channel sample rate ranging from 9155413 to 80,000 Hz The host program may achieve a further reduction in sample rate below 9155413 Hz by using selective sampling methods whereby every nth point is selected as the converted value For example, a sample rate per scan list element of 10 Hz is achieved by applying an integer value of 60,000 to the srate command, and further selecting every 100th value from the reported data stream Every 1000th reading is effectively 1 Hz Averaging every n values on each channel is more difficult but recommended since it reduces noise by a factor of the square root of n Note that the divisor (60,000,000) used in the above equation can change between data acquisition products The command info 9 can be used to determine the value for each product LED Color Command The DI-1100 has a panel-mounted, multi-color LED (labeled Active) that is available for general-purpose use The led command accepts one argument that defines the color of the LED and takes the following form: led arg0 Where: Page 6 of 9

arg0 Color arg0 Color 0 Black 4 Red 1 Blue 5 Magenta 2 Green 6 Yellow 3 Cyan 7 White Command: led 1 'set the led color to blue Response: led 1 'the led color is blue Binary Stream Output Format The DI-1100's data output format is a binary stream of one 16-bit word per enabled measurement In the table below A x values denote analog channel ADC values, and D x digital inputs Scan list position (measurement 0 (Analog in 0) 1 (Analog in 1) 2 (Analog in 2) 3 (Analog in 3) Word Count 1 2 3 4 Binary Data Stream Example (all functions and channels enabled in order) Byte Count B7 B6 B5 B4 B3 B2 B1 B0 1 A3 A2 A1 A0 0 0 D1 D0 2 A11 A10 A9 A8 A7 A6 A5 A4 3 A3 A2 A1 A0 0 0 0 0 4 A11 A10 A9 A8 A7 A6 A5 A4 5 A3 A2 A1 A0 0 0 0 0 6 A11 A10 A9 A8 A7 A6 A5 A4 7 A3 A2 A1 A0 0 0 0 0 8 A11 A10 A9 A8 A7 A6 A5 A4 Analog Channel Binary Coding The DI-1100 transmits a 12-bit binary number for every analog channel conversion in the form of a signed, 16-bit Two's complement value: Page 7 of 9

DI-1100 ADC Binary Coding A 11 A 10 A 9 A 8 A 7 A 6 A 5 A 4 A 3 A 2 A 1 A 0 Counts Voltage 0 1 1 1 1 1 1 1 1 1 1 1 2047 9995 0 1 1 1 1 1 1 1 1 1 1 0 2046 9990 0 0 0 0 0 0 0 0 0 0 0 1 1 0004 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 1-2047 -9995 1 0 0 0 0 0 0 0 0 0 0 0-2048 -100 Applied voltage as a function of ADC counts has the following relationship: Page 8 of 9

Control Revision Date Description 10 Mar 20, 2017 Original release level 11 Apr 5, 2017 Corrected errors in the ADC Binary Coding Table and formula Page 9 of 9