Page 3 - Table of Contents
232DRIO-0308 Manual Table of Contents i B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Table of Contents Chapter 1- Introduction ........................................... 3 232DRIO Features .................................................. 3 Packing...
Page 5 - Chapter 1- Introduction; The 232DRIO is a general purpose data acquistion controller that; not; be
232DRIO-0308 Manual 3 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Chapter 1- Introduction 232DRIO Features The 232DRIO is a general purpose data acquistion controller that is connected to your computer’s RS-232 serial port. The 232DRIO offers 1 opto...
Page 6 - Manual; Figure 1.2 – Simplified Block Diagram; Examine the shipping carton and contents for physical damage.; 32DRIO Specifications; REL; POWER; Microcontroller
4 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Figure 1.1 – 232DRIO Module Figure 1.2 – Simplified Block Diagram Packing List Examine the shipping carton and contents for physical damage. The following items should be in the shipp...
Page 8 - Chapter 2 - Connections; Do not make any connections to the 232DRIO until you have; Both relays are de-energized; Connect the ground correspondingly as marked. Do not
6 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Chapter 2 - Connections Do not make any connections to the 232DRIO until you have read this chapter. Remember to power down the unit and any other connected devices before making any ...
Page 9 - Function; Table 2.2 – RS232 Connector Pinout
232DRIO-0308 Manual 7 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Table 2.1 - 232DRIO Terminal Blocks Blue Pin # Function Black Pin # Function 1 - Ground Input Power 1 Opto-Isolated Input 2 +12Vdc Input Power 2 Opto-Isolated Input 3 #2 N/C-Normally ...
Page 10 - Table 2.3 – 232DRIO To DTE Connections; Table 2.4 – 232DRIO To DCE Connections; Ring Indicator; Power Supply Connections; The power requirement is 12VDC at 100mA. Power to the; provide enough power to supply the 232DRIO’s; Chapter 3 - Commands
8 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Table 2.3 – 232DRIO To DTE Connections 232DRIO Pin # Signal DTE DB-25 Connection DTE DB-9 Connection 2 Receive Data (RD) 3 2 3 Transmit Data (TD) 2 3 5 Signal Ground (SG) 7 5 9 Ring I...
Page 12 - Table 3.2 – Equivalent Values; ASCII Decimal Hexadecimal; Syntax
10 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Table 3.1 – 232DRIO Commands Function Command Response Set Output Lines !0S{…} No response Read I/O Lines !0R {…} Set Output Lines #0S{…}{~…} No response Read I/O Lines #0R {…}{~…} S...
Page 13 - Table 3.3 – Bit Assignments for I/O Lines; Input
232DRIO-0308 Manual 11 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 used to specify which command will be executed by the controller,either the “R” or “S” character. The set output command requires one argument field (for normal environments) or two ...
Page 15 - The Set Output Lines command is used to set the states of the
232DRIO-0308 Manual 13 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Read I/O Lines Command The Read I/O Lines command returns one data byte (with the “!”) and two data bytes (data and its complement with the “#”) that reflects the state of the I/O li...
Page 16 - one; two; character delay must follow immediately
14 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Command: !0S Argument: {…} (shown in bold face) Response: none ASCII Example: !0S <ETX> Dec. Example: !0S <3> Hex. Example: !0S <03> Bin. Example: !0S <00000011&...
Page 17 - Figure 4.1 – Board Layout; The isolated input is used to sense a HIGH or a LOW state. This
232DRIO-0308 Manual 15 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 This chapter will explain "HIGH" and "LOW" states and show some general examples of how to interface to the I/O lines. Caution must be taken not to exceed 232DRIO spe...
Page 18 - EXTERNAL CIRCUIT
16 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Figures 4.2 - 4.4 show examples of some typical input interfaces. Figure 4.2 - Switch Input Figure 4.3 - Solid State Input 232DRIO EXTERNAL CIRCUIT 5-30 Vdc/Vac Opto Isolated Input 2...
Page 19 - Relay Outputs; Relay outputs are used to turn external devices on or off. Relay; energized at factory default settings.; The relay circuits are
232DRIO-0308 Manual 17 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Figure 4.4 - Isolated Mechanical Input Relay Outputs Relay outputs are used to turn external devices on or off. Relay outputs are CMOS/TTL compatible and can also operate between 0-2...
Page 20 - Figure 4.5 – Isolated Connection to External Circuit
18 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Figures 4.5 - 4.6 show examples of some typical output interfaces. Figure 4.5 – Isolated Connection to External Circuit Figure 4.6 – Isolated Connection to External Devices EXTERNAL ...
Page 21 - Chapter 5 - Software; Programming Techniques; PortIndex
232DRIO-0308 Manual 19 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Chapter 5 - Software This chapter will be divided into two sections. The first section covers programming techniques for opening/closing a com port, receiving data, and manipulating ...
Page 22 - Read I/O States Command; states; Set Output States Command
20 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 QuickBasic (DEMO232.EXE and DEMO232.BAS) This section shows steps and examples of programming the 232DRIO in QuickBasic. If you are programming in another language, this section can ...
Page 23 - Mode
232DRIO-0308 Manual 21 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 C/C++ (DEMO232.EXE and DEMO232.CPP) DEMO232.CPP is a demonstration program for use with B&B Electronics model 232DRIO module. Much of the work associated with using COM ports in ...
Page 24 - Demonstration Program; Running Demonstration Program
22 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Demonstration Program The Demonstration Programs (IBM PC or Compatible) provide the user with examples of how to receive and transmit commands to the 232DRIO. The DEMO232.EXE is the ...
Page 25 - Appendix A; APPENDIX A; ASCII Character Codes
232DRIO-0308 Manual Appendix A A-1 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 APPENDIX A ASCII Character Codes
Page 27 - APPENDIX B; Hexadecimal/Decimal Conversions; Table 1.; Decimal
232DRIO-0308 Manual Appendix B B-1 B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 The decimal (base 10) numbering system represents each position in successive powers of 10, with each decimal symbol having a value from 0 to 9. The hexadecimal (base 16)...
Page 28 - Decimal to Hexadecimal Conversion:; Convert 4348 decimal to hexadecimal.
B-2 Appendix B 232DRIO-0308 Manual B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350 PH (815) 433-5100 -- FAX (815) 433-5104 Hexadecimal to Decimal Conversion: Decimal = (1st Hex digit x 4096) + (2nd Hex digit x 256) + (3rd Hex digit x 16) + (4th Hex digit) Each "Hex digit" is the decim...