Streszczenie treści zawartej na stronie nr. 1
Not Recommended for New Installations.
Please contact Technical Support for more information.
Optically Isolated Serial
Data Acquisition Module
232OPSDA Module
Documentation Number 232OPSDA1397
This product
Designed and Manufactured
In Ottawa, Illinois
USA
of domestic and imported parts by
B&B Electronics Mfg. Co. Inc.
707 Dayton Road -- P.O. Box 1040 -- Ottawa, IL 61350
PH (815) 433-5100 -- FAX (815) 433-5105
Internet:
http://www.bb-elec.com
ord
Streszczenie treści zawartej na stronie nr. 2
TABLE OF CONTENTS CHAPTER 1: INTRODUCTION ...........................................................1 232OPSDA FEATURES...........................................................................1 PACKING LIST .........................................................................................2 SOFTWARE INSTALLATION ......................................................................3 232OPSDA SPECIFICATIONS ..................................................................3 Analog
Streszczenie treści zawartej na stronie nr. 3
APPENDIX A: DEC TO HEX TO ASCII CONVERSION.......... A-27 APPENDIX B: 232OPSDA SCHEMATIC & BOARD .................B-29 ii Table of Contents Documentation Number 232OPSDA1397 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5105
Streszczenie treści zawartej na stronie nr. 4
Chapter 1: Introduction 232OPSDA Features The 232OPSDA is an optically isolated data acquisition module that is connected to your computer’s RS-232 serial port. It provides 2500V of optical isolation protection between the I/O and RS-232 side of the module. The 232OPSDA offers six channels of 12-bit A/D, one digital input, and one digital output. The six A/D input channels can be used for a number of applications. One A/D channel can read a 4-20mA analog current, two buffered channels
Streszczenie treści zawartej na stronie nr. 5
Terminal Blocks TB 7 Digital Input TB 6 Digital Output Optical Isolation Microprocessor Serial Port DB-25S TD A/D Converter TB 4 A/D 4 TB 5 A/D 5 RD RS-232 Tranceiver TB 0 A/D 0 TB 1 A/D 1 Signal TB 2 A/D 2 Conditioning TB 3 A/D 3 Circuitry Figure 1.2: General Block Diagram Packing List Examine the shipping carton and the contents for physical damage. The following items should be in the shipping carton: 1. 232OPSDA module 2. One 232OPSDA 3.5” disk 3. This instruction manual I
Streszczenie treści zawartej na stronie nr. 6
Software Installation The 232OPSDA comes with several a demonstration program. To install these programs on your hard drive: 1. Place the disk in drive A. 2. Type A: and press the key. 3. Type INSTALL and press the key. 4. Follow the instructions given by the program. The file, READ.ME, contains corrections and additions to the printed user’s manual. The file, FILES.LST, contains a list and description of the files installed on the hard drive. The file, HISTOR
Streszczenie treści zawartej na stronie nr. 7
Digital Input Channels: 1 Voltage Range: -30VDC to +30VDC Low Voltage: -30VDC to 1.0VDC High Voltage: 2.0VDC to 30VDC Leakage Current: 1 µ A maximum Digital Output Channels: 1 Low Voltage: 0.6VDC @ 8.7mA High Voltage: 4.3VDC @ -5.4mA Power Supply Input Voltage: 9-16VDC @ 10mA (Does not include the power consumption of external devices.) Connections: Terminal Blocks Communications Standard: RS-232 (unit is DCE) Baud Rate: 1,200 to 9,600 (automatic detec
Streszczenie treści zawartej na stronie nr. 8
Chapter 2: Connections This chapter will cover the connections required for the 232OPSDA. Four sets of connections are required: A/D converter, digital I/O, serial port, and power supply connections. Do not make any connections until you have read this chapter. If you do not use a particular type of connection, it is still important to read each section. Table 2.1 shows the terminal block assignments. Table 2.1: Terminal Block Assignments Terminal Function Description Block TB 0 A/
Streszczenie treści zawartej na stronie nr. 9
RS-232 Port 232OPSDA Output Input 4-20mA 4-20mA Current 4-20mA Current Loop Loop Current Loop Transmitter Receiver Return Out Figure 2.1: Current Loop Channel Connections (A/D 0) NOTE: When using the 4-20mA Current Loop Input with the setup shown in Figure 2.1, A/D 1-5 cannot be used and should be connected to the terminal block labeled GND. TB 1 A/D 1 0 to 5VDC Input TB 2 A/D 2 0 to 5VDC Input TB 3 A/D 3 0 to 10VDC Input TB 4 A/D 4 0 to 5VDC Input TB 5 A/D 5 0 to 5VDC Input TB 0 A/D
Streszczenie treści zawartej na stronie nr. 10
Digital I/O Connections The digital I/O connections are made on the I/O port, which consists of terminal blocks. Table 2.1 shows the terminal block assignments. Digital Input Terminal block 7 is the digital input line. This input is CMOS/TTL compatible and can handle voltage from -30VDC to 30VDC. If a digital input is from -30VDC to 1.0VDC, the state will be read as a “0” (LOW). If a digital input is from 2.0VDC to 30VDC, the state will be read as a “1” (HIGH). If the digital input i
Streszczenie treści zawartej na stronie nr. 11
Table 2.2 - RS-232 Connector Pinout DB25S 232OPSD Pin # Signal A Function Notes 2 Transmit Data (TD) Input Connection is required. 3 Receive Data (RD) Output Connection is required. 4 Request to Send (RTS) Input Used for power. 5 Clear to Send (CTS) Internally connected to RTS (pin 4). 6 Data Set Ready (DSR) Internally connected to DTR (pin 20). 7 Signal Ground (SG) Connection is required. 8 Data Carrier Detect (DCD) Internally connected to to DTR (pin 20). 12 Signal Ground (S
Streszczenie treści zawartej na stronie nr. 12
Power Supply Connections The 232OPSDA requires an isolated external power supply that is able to produce 9-16VDC @10mA in addition to the port power. The positive(+) lead of the power supply is connected to the terminal block labeled +12VDC and the negative(-) lead is connected to the terminal block labeled GND. The external power supply powers the I/O side of the module. The RS-232 side of the module is port powered using RTS and DTR. These lines may be either LOW or HIGH to provide po
Streszczenie treści zawartej na stronie nr. 13
Chapter 3: Commands Only three commands are required to operate the 232OPSDA: the read A/D command, read digital I/O command, and the set digital output command. The command string consists of four bytes. The read A/D and digital I/O commands require an additional data byte. See Table 3.1. Table 3.1: 232OPSDA Commands Function Command Response Read A/D !0RA{#} {ch#msb}{ch#lsb}{ch(#-1)msb}… Channels {ch0msb}{ch0lsb} Read !0RD {I/O states} Digital I/O Set Digital !0SO{#} no response
Streszczenie treści zawartej na stronie nr. 14
Table 3.2 - Equivalent Values ASCII Decimal Hexadecimal ! 33 21h # 35 23h 0 48 30h A 65 41h D 68 44h O 79 4Fh R 82 52h S 83 53h NUL 0 0h SOH 1 1h STX 2 2h ETX 3 3h EOT 4 4h ENQ 5 5h ACK 6 6h BEL 7 7h Syntax As mentioned earlier, the command string consists of four bytes. The first byte is the start of message byte. The start of message byte is always the “!” character. The second byte is the address byte. This byte allows each unit to have a unique address (useful in RS-
Streszczenie treści zawartej na stronie nr. 15
The command syntax for the extended command set is shown below: Command Syntax: #0____ |||||| ||||| Compliment |||| Data Byte nd |||2 Command Byte st ||1 Command Byte | Address Byte Start of Message Byte Reading A/D Channels Command The Read A/D channels command returns two bytes for each channel read. The two bytes represent the most significant byte (MSB) and least significant byte (LSB) of the reading. The MSB is received first, followed by the LSB. This command requires a data by
Streszczenie treści zawartej na stronie nr. 16
Table 3.3 - Read A/D Response # of Channels Specified Response Channels Returned Bytes decimal Hex ASCII (order of response) Returned 0 0 NUL Channel 0 2 1 1 SOH Channels 1,0 4 2 2 STX Channels 2,1,0 6 3 3 ETX Channels 3,2,..,0 8 4 4 EOT Channels 4,3,..,0 10 5 5 ENQ Channels 5,4,..,0 12 NOTE: There are three test channels that can be read: Ref+, Ref-, and Ref+/2. Specify 13 (0Dh) to read Ref+, 12 (0Ch) to read Ref-, and 11 (0Bh) to read Ref+/2. Reading Digital I/O Command The
Streszczenie treści zawartej na stronie nr. 17
Chapter 4: A/D This chapter will deal with the various A/D channels and manipulating the data obtained from them. Sampling Rate The A/D converter has a conversion time around 10 microseconds, however, the actual sampling rate is limited by the serial communications. The actual sampling rate for a single channel is around 120 samples per second (9600 baud). This rate drops to around 41 samples per second when sampling all of the channels. When reading an A/D input, the 232OPSDA takes
Streszczenie treści zawartej na stronie nr. 18
inverting amplifier, remove R15 and calculate values for R13 and R14 using the equation below. V R13 0 Gain== 1+ Vin R14 NOTE: V is the voltage read by the A/D converter chip, and Vin is 0 the voltage at TB1. R13 and R14 should be chosen so that V does 0 not exceed 5.00VDC. 0 to 10VDC A/D Input The 232OPSDA contains one A/D input than is capable of handling voltages between 0VDC and 10VDC. This channel is A/D 3 and is located on Terminal Block 3. The gain of the signal conditioni
Streszczenie treści zawartej na stronie nr. 19
The signal conditioning circuit for this A/D input channel has been designed to be easily modified. In the original configuration, R5 and R6 are left OPEN (they are not present). These two spaces are provided if you need a different gain. Reducing the gain of this non- inverting amplifier allows you to measure currents up to 100mA, and increasing the gain allows you to read much smaller currents with greater accuracy. See the circuit schematic in Figure B.1 and board layout in Figure B.
Streszczenie treści zawartej na stronie nr. 20
Chapter 5: Software Application Program Interface The application program interface (API) is a set of routines that makes it easy to communicate with the 232OPSDA module from a 16- bit DOS application. Example programs using the API are written in ® Borland C++, Borland Pascal and Microsoft QuickBASIC v4.5. The batch file, MAKEIT.BAT, in the directory for each language shows how to compile and link the demo program with the API routines. B232OPSDA_ReadAnalog Purpose: This function reads