background image

232DRIO-0308 Manual 

 

Cover Page 

B&B Electronics  --  PO Box 1040  --  Ottawa, IL  61350 

PH (815) 433-5100  --  FAX (815) 433-5104

 

 

 

 
 
  
  

RS-232 Digital Relay I/O 

Model 232DRIO 

Documentation  Number  232DRIO1005 

pn#4520-r2

 

 

 
 
 

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-5104 

 
 
 

Internet: 

http://www.bb-elec.com 

[email protected] 

[email protected] 

 
 
 

©

 B&B Electronics – January 2008  

 

 

Содержание RS-232 Digital Relay I/O 232DRIO

Страница 1: ...IO Documentation Number 232DRIO1005 pn 4520 r2 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 O...

Страница 2: ......

Страница 3: ...ections 5 I O Connections 5 Opto isolated Input 5 Relay Outputs 5 Ground 5 Serial Port Connections 6 Power Supply Connections 7 Chapter 3 Commands 9 Syntax 10 I O Data Bytes 11 Read I O Lines Command...

Страница 4: ...ectronics PO Box 1040 Ottawa IL 61350 PH 815 433 5100 FAX 815 433 5104 Demonstration Program 22 Hard Drive Installation 22 Running Demonstration Program 22 APPENDIX A A 1 ASCII Character Codes A 1 APP...

Страница 5: ...patible For maximum flexibility both input and outputs are connected with internal screw type terminal blocks Three LEDs are provided to monitor the status of each of these The 232DRIO connects to you...

Страница 6: ...damage The following items should be in the shipping carton 1 232DRIO unit 2 Software 3 This instruction manual If any of these items are damaged or missing contact B B Electronics immediately 232DRI...

Страница 7: ...andard 10A 120VAC 8A 30VDC resistive Max switching capacity 1200VA 240W Max operating voltage 250VAC 125VDC Max carrying current 10A AC 8A DC standard Min permissible load 100 mA 5 VDC Relay Form Form...

Страница 8: ...ls These should clearly be labeled on the board Refer to Table 2 1 See Chapter 5 for I O interfacing examples Opto isolated Input black terminal blocks The non polarized opto isolated input line is CM...

Страница 9: ...the serial port must be set for this rate A data format of 8 data bits 1 stop bit and no parity is used The 232DRIO is configured as a DCE device See Table 2 2 If your communications equipment is conf...

Страница 10: ...232DRIO To DCE Connections 232DRIO Pin Signal DCE DB 25 Connection DCE DB 9 Connection 2 Receive Data RD 2 3 3 Transmit Data TD 3 2 5 Signal Ground SG 7 5 9 Ring Indicator 22 9 Power Supply Connection...

Страница 11: ...command characters 0X the unit will not execute the command However if the 232DRIO receives a communication error on a data byte I O byte for Read Digital command or state byte for Set Output State c...

Страница 12: ...the ASCII 0 zero does not have a value of zero but has a value of 48 The decimal and hexadecimal equivalents of some ASCII characters are shown in Table 3 2 Some commands require an additional data by...

Страница 13: ...sary to know how to select and interpret the I O data byte The three I O lines are represented by one data byte A byte represents an eight bit binary number 11111111 therefore each byte can represent...

Страница 14: ...d 2 Example 3 2 Read I O Lines Data Byte Returned Status Binary Dec Hex ASCII Input 1 Relay 2 Relay 1 00000000 0 00 NUL low de energ de energ 00000001 1 01 SOH low de energ energ 00000010 2 02 STX low...

Страница 15: ...ays are 0 s or LOW Command 0R Argument none Response data and its complement state of the input and 2 relays shown in bold face ASCII Example 0R NUL blank FF Dec Example 0R 0 255 Hex Example 0R 00 FF...

Страница 16: ...ement is returned immediately following the data byte NOTE If any of these lines are defined as inputs the bit settings are ignored Since Bit 2 is defined as Input 1 the bit setting is ignored Two imp...

Страница 17: ...ated input line is CMOS TTL compatible and can also handle voltages from 0 to 30 Vdc or Vac The isolated input is used to sense a HIGH or a LOW state This can be accomplished via switch closures conta...

Страница 18: ...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 Isolate...

Страница 19: ...tput LOW Both relays are de energized at factory default settings NOTE The relay circuits are not UL approved for 120 Vac 10A or 30 Vdc 8A resistive maximum line service in regards to contact ratings...

Страница 20: ...xamples of some typical output interfaces Figure 4 5 Isolated Connection to External Circuit Figure 4 6 Isolated Connection to External Devices EXTERNAL CIRCUIT 0 30 Vdc 8A max 0 120 Vac 10A max 232DR...

Страница 21: ...all be 0 Programming Techniques 232DRIO LIB Opening a COM Port HComDev initComPort unsigned short addr unsigned char irq unsigned long baud unsigned short PortIndex The last parameter PortIndex will...

Страница 22: ...000 Tell QB to set aside memory for the 232DRIO library to use Read I O States Command states bbDRIOReadIOLines hComDev mode When the line is executed states will contain a byte that can be read by AN...

Страница 23: ...ck on ok include 232DRIO H void main put your program here Read I O States Command states bbDRIO_ReadIOLines hComDev int mode Mode is 1 if harsh environment is enabled or 0 if disabled Returns 1 if an...

Страница 24: ...s the source code in C C The source codes provide an illustration of how to send and receive commands from the 232DRIO NOTE This is a demonstration program only and not intended for system application...

Страница 25: ...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...

Страница 26: ...11 B VT ctrl K 43 2B 75 4B K 107 6B k 12 C FF ctrl L 44 2C 76 4C L 108 6C l 13 D CR ctrl M 45 2D 77 4D M 109 6D m 14 E SO ctrl N 46 2E 78 4E N 110 6E n 15 F SI ctrl O 47 2F 79 4F O 111 6F o 16 10 DLE...

Страница 27: ...h position in successive powers of 16 with each hex symbol having a value of 0 to 15 Since each hex position must have a single symbol the symbols A through F are assigned to values 10 through 15 resp...

Страница 28: ...ch Hex digit is the decimal equivalent value of the hexadecimal symbol Example Convert 10FC hexadecimal to decimal 10FC hex equals 4348 decimal Decimal to Hexadecimal Conversion Example Convert 4348 d...

Отзывы: