background image

WebRelay-10 Users Manual

Operation

Error Response Frame Example

Field Name

Length

Function 

Example Data 

Transaction Identifier

2 bytes

Synchronization between messages of 
server and client.

0x0001

Protocol Identifier

2 bytes

Zero for Modbus/TCP

0x0000

Message Length

2 bytes

Number of bytes in frame (below)

0x0003

Unit Identifier

1 byte

Slave Address (0xff if not used)

0xFF

Function Code

1 byte

Error code

0x85

Data

1 byte

Exception code (

0x01 - 0x02

)

0x02

RX String: 00 01 00 00 00 03 FF 85 03

Xytronix Research & Design, Inc.

page 73

Содержание WebRelay-10 X-WR-10R12-I

Страница 1: ...WebRelay 10 Title Page Goes Here...

Страница 2: ...Through GET Requests WebRelay 10 Plus only 61 3 4 Modbus Operation 63 3 5 Email Notification 78 Appendix A Restoring Factory Default Settings 80 Appendix B Installing New Firmware 81 Appendix C Acces...

Страница 3: ...e specification from 10 36VDC to 9 28VDC Updated power requirements for 9 28VDC operation Changed relay contact specification from 30amps to 15amps Moved warranty and trademark information to the appe...

Страница 4: ...etworks IP based industrial control networks and the Internet Users can operate WebRelay 10 using a web browser or a custom application Computers PLCs or automation controllers may control and monitor...

Страница 5: ...ors or switches can be connected for local control of relays or for monitoring external devices Logging log relay changes events Modbus requests high low temperatures input changes network traffic and...

Страница 6: ...nitoring humidity monitoring requires optional humidity sensor discrete inputs real time clock event scheduling capacitor power backup and logging 1 3 1 Optional Accessories WebRelay 10 Plus Accessory...

Страница 7: ...s Manual Introduction 1 4 Connectors Indicators Version H Newest version Gnd and Vin pin position moved from version 2 3 Version G Older version Xytronix Research Design Inc page 7 Figure 1 4a Connect...

Страница 8: ...dule Power Indicator The green power LED indicator is located on the main relay board in between relays 1 and 6 Ethernet Indicators The LINK LED is illuminated green when the module is properly connec...

Страница 9: ...WebRelay 10 does not employ a general purpose computer operating system and does not have features such as telnet FTP SSH nor uncontrolled open ports This means it is unlikely for someone to break in...

Страница 10: ...o the DIN Rail by placing the top hooks on the back of WebRelay 10 to the DIN Rail and then snapping the bottom hooks into place Remove from the DIN Rail by depressing the latch release on the mountin...

Страница 11: ...ements Multiple WebRelay 10 units may be connected to a single power supply by connecting the power supply input terminals in parallel The power supply must have a high enough current rating to power...

Страница 12: ...or is used for connecting temperature sensors humidity sensors or discrete inputs The terminals are described in the table below IMPORTANT MAKE SURE WIRES ARE PROPERLY ATTACHED TO THE TERMINALS AND TH...

Страница 13: ...ts can also be used for operator switches and the unit can be configured such that they control the relays Connect one terminal of sensor or switch to the input terminal Input 1 or Input 2 Connect the...

Страница 14: ...or on the one wire bus is assigned a unique serial number when it is manufactured That number is used to address the device during communication The sensors have three wires the wire color is show in...

Страница 15: ...the length Figure 2 2h shows the recommended connection using Cat 5 network cable A linear daisy chain rather than a star direct connection topology will minimize signal reflections Appropriate strai...

Страница 16: ...p page and not the temporary address assigned here Make sure that WebRelay 10 and the configuration computer are connected to the same network This will not work through routers or gateways Microsoft...

Страница 17: ...ompt window Mac OS X Instructions 1 Open a terminal Note The terminal is in the Utilities directory which is in the Applications directory 2 Type sudo arp s new IP address serial number of WebRelay 10...

Страница 18: ...assigned to 192 168 1 50 The following example is for those running the Windows operating system 1 Windows XP Open the control panel by clicking on the start menu and then on Control Panel Windows Vi...

Страница 19: ...the icon labeled Local Area Connection In the menu that follows select the option at the bottom of the menu labeled Properties The Local Area Connection Properties window will appear Figure 2 3c Xytro...

Страница 20: ...d Click OK to accept the new settings Note If Use the following IP address is already selected the computer has been set up with a static IP address Record these values so that the computer can be res...

Страница 21: ...s is the initial page that is displayed when setup html is entered into the address bar of the browser It displays model and serial number information and allows the user to select the desired tempera...

Страница 22: ...this option is set to Yes WebRelay 10 Plus will wait for an IP address from a DHCP server each time it is powered The default setting is No this is recommended for most installations If DHCP is set t...

Страница 23: ...networking many tutorials are available on the Internet The default setting for this field is 255 255 255 0 Gateway This specifies the IP address of the gateway router This must be obtained from the n...

Страница 24: ...ss There is no default setting for this field Email 1 to Email 5 Enter the email addresses of up to five recipients for alarm messages in these fields There are no default settings for these fields Em...

Страница 25: ...bus TCP communications with WebRelay 10 By default this is set to port 502 which is the standard Modbus port It can be set within the range of 0 to 65535 Remote Services Enabled This option enables or...

Страница 26: ...1 minute SNMP Enabled When this option is set to Yes WebRelay 10 will support SNMP The default setting for this option is No See 2 4 3 2 SNMP for more information SNMP Manager IP When SNMP is used thi...

Страница 27: ...IP address dynamically from a DHCP server simplifying the installation Second since the connection from WebRelay 10 is outgoing rather than incoming the local router on the network where WebRelay 10...

Страница 28: ...identically in both fields the password will not be changed Enable Control Password The Control Page can be viewed without entering a password For security purposes a password can be required for acce...

Страница 29: ...bRelay 10 Users Manual Installation and Setup a second time in this field If the password is not entered identically in both fields the password will not be changed Xytronix Research Design Inc page 2...

Страница 30: ...nually or Sync with NTP server The options that follow this field will change based upon how this option is set Manually requires the user to enter the time and date When this option is selected param...

Страница 31: ...ervers are available In addition many desktop computers will function as an NTP server both Mac and PC If a desktop computer is used firewall settings may need to be adjusted to allow for NTP communic...

Страница 32: ...be synchronized with the time server each time it is powered Note If WebRelay 10 Plus will lose power on a frequent basis it may be beneficial to set this option to No some servers are configured to d...

Страница 33: ...to remain on GMT time and do not shift for daylight savings Daylight Savings Start This is the date that daylight savings will start Note that on this date between the hours of 12 00 AM 5 00 PM the c...

Страница 34: ...g the log settings will erase the current log file Logging Enabled When this option is set to Yes WebRelay 10 Plus will record data as configured on this page The default setting for this option is No...

Страница 35: ...Event Trigger logging will occur whenever the temperature humidity changes by a set amount The following Log Event Trigger options are available Input 1 2 Relay 1 10 Sensor 1 8 Events XML Requests MO...

Страница 36: ...status on the Control Page and in email messages when email alerts are enabled This field may be up to 24 characters long The default text is Input On Status Text The text in this field specifies the...

Страница 37: ...cify what input changes if any will cause email messages to be sent Note that email notification will work only if the email settings are correctly set up in the Network setup page The following optio...

Страница 38: ...ribe the function of the selected relay The text appears to the left of the corresponding relay status on the Control Page and in the email message when email alerts are enabled Up to 14 characters ma...

Страница 39: ...relay will be ON when power is applied to WebRelay 10 last state unless overridden by event WebRelay 10 Plus only Upon power up the relay will return to its last state when WebRelay 10 Plus was power...

Страница 40: ...ulse Duration specified The input can remain open and the pulse time will not be affected If the input is tied to ground and re opened before the end of the pulse time the Pulse Duration timer will be...

Страница 41: ...ddresses specified on the Network setup tab will be displayed next to each check box By default no boxes are checked Remote Service SNMP When this box Send State Msg Trap on Input Change is checked SN...

Страница 42: ...o the left of the corresponding temperature humidity reading on the Control Page This text also appears in the email status message when email is enabled This field can be up to 24 characters in lengt...

Страница 43: ...and prevents alarms from triggering excessively when the sensor measurement vacillates quickly around the set point due to normal fluctuations Deadband on high alarms requires the measurement to fall...

Страница 44: ...SNMP This field specifies the action with a remote server due to an alarm condition No Action No action is taken Send State Msg Trap An event string will be sent to the remote server For more informa...

Страница 45: ...ult schedule Start Date Time The start date and time 24 hour of the event Period The time between the start of successive events Count The number of times the event will occur Action What action the r...

Страница 46: ...the calender The single arrows and change the month and the double arrows and change the year Once the current month and year are displayed the date should be entered by selecting the day Start Time...

Страница 47: ...s written in BASIC to interact with users and for scripts to execute as a result of event occurrences This option sets the variable extvar0 to 1 when the event occurs If a running script uses this var...

Страница 48: ...vent 8 Schedule 1 1 1 2 2 2 Description Summer AM Bell Summer AM Bell End Summer Winter AM Bell Winter AM Bell End Winter Start Date 30 May 30 May 01 Sep 01 Sep 1 Sep 30 May Start Time 08 00 00 17 00...

Страница 49: ...t rtf used by Microsoft WordPad is NOT compatible BASIC Script This field displays the txt file that is uploaded to WebRelay 10 Text displayed in this screen cannot be edited In order to edit any scri...

Страница 50: ...External Variable on the Control Page Display Button 1 Checking this box will display a button on the Control Page Clicking this button on the Control Page will set the extVar to value 1 Display Butto...

Страница 51: ...extVar is value 1 with a gray background The text also appears in the status column on the Control Page Up to 14 characters may be entered here By default the text is ON Status 2 Text The text in this...

Страница 52: ...ge will be refreshed at the time interval specified in the Refresh Rate setting When set to NO the web page will need to be manually refreshed to show the current status of the unit in the control pag...

Страница 53: ...cked an ON and OFF button is displayed for direct user control Display Pulse Button When checked a button allowing a user to manually pulse a specified relay is displayed Note Inputs Counters and Sens...

Страница 54: ...tion Once WebRelay 10 is set up users can access the Control Page using a web browser by typing the IP address of WebRelay 10 into the web browser address bar For example using the default IP address...

Страница 55: ...r OFF however the status text can be changed in the Relays tab To the right of the relay status buttons are provided to control the relays The buttons can be removed when needed in the Control Page Se...

Страница 56: ...e 0 relay2state relay3state 0 relay3state relay4state 0 relay4state relay5state 0 relay5state relay6state 0 relay6state relay7state 0 relay7state relay8state 0 relay8state relay9state 0 relay9state re...

Страница 57: ...10 to control the relays X is replaced by 1 for Relay 1 2 for Relay 2 and so forth The following are a few examples Command Description state xml relay1State 0 Turn Relay 1 OFF state xml relay1State 1...

Страница 58: ...Reply 1 Turn Relay 1 OFF without returning state Password If the Control Password is enabled on WebRelay 10 and the state xml page is requested through a browser the user will be prompted for a passwo...

Страница 59: ...the next event time The text no indicates that the event is inactive and the event will no longer take place currentTime This field indicates the current date and time as MM DD YYYY HH MM SS in 24 hou...

Страница 60: ...cribed below devicePowerUpFlag Loss of power to the device is indicated by 1 A value of 1 means WebRelay 10 has lost power at least one time since the flag was set to 0 By default the flag value is 1...

Страница 61: ...event will occur 0 continuous 0 Schedule The schedule where the event will occur 0 4 0 schedule 0 1 schedule 1 and so forth 1 Action 0 No Action 1 Turn relay on 2 Turn relay off 3 Pulse relay 4 Toggl...

Страница 62: ...mon Base Ten Values for Event Days Sun Mon Tues Wed Thurs Fri Sat Base 10 Value Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 1 1 1 1 1 1 1 127 0 1 1 1 1 1 0 62 0 1 0 1 0 1 0 42 0 0 1 0 1 0 0 20 0 0 0 0 0...

Страница 63: ...Coils 15 Relays 1 10 0 9 Discrete 3 4 8 Pulse Coils 16 Relays 1 10 0 9 32 bit 3 4 9 Multiple commands may be sent without closing and re opening the connection but if no data is transferred for 50 se...

Страница 64: ...the PLC address mode column input address PLC address range PLC address For example to read discrete Input 2 the Modbus function code 02 is used Adding the address of Input 2 1 to the address range 1...

Страница 65: ...lay 1 05 0 Discrete 1 1 Write Relay 2 05 1 Discrete 2 2 Write Relay 3 05 2 Discrete 3 3 Write Relay 4 05 3 Discrete 4 4 Write Relay 5 05 4 Discrete 5 5 Write Relay 6 05 5 Discrete 6 6 Write Relay 7 05...

Страница 66: ...Identifier 1 byte Slave Address 0xff if not used 0xFF Function Code 1 byte Read Coils 0x01 Data 4 bytes Start Address 0x0000 0x0009 Quantity of coils to read 0x0001 0x000A 0x0001 0x0009 Tx String 00...

Страница 67: ...04 FF 01 02 55 01 Errors The following are possible error responses for function code 0x01 Coil Read Error Function Code 1 byte 0x81 Exception Codes 1 byte 0x01 Function code not supported 0x02 Incor...

Страница 68: ...lave Address 0xff if not used 0xFF Function Code 1 byte Read Inputs 0x02 Data 4 bytes Start Address 0x0000 0x0001 Quantity 0x0001 0x0002 0x0000 0x0002 TX String 00 01 00 00 00 06 FF 02 00 00 00 02 Res...

Страница 69: ...h Function Example Data Transaction Identifier 2 bytes Synchronization between messages of server and client 0x0001 Protocol Identifier 2 bytes Zero for Modbus TCP 0x0000 Message Length 2 bytes Number...

Страница 70: ...s with the least significant word being sent first In other words the 32 bit floating point number represented as 1234 ABCD is sent as ABCD 1234 For example if we were to read two registers starting a...

Страница 71: ...ransaction Identifier 2 bytes Synchronization between messages of server and client 0x0001 Protocol Identifier 2 bytes Zero for Modbus TCP 0x0000 Message Length 2 bytes Number of bytes in frame below...

Страница 72: ...ddress 0x0000 0x0009 Relay value 0x00 0xFF Padding 0x00 0x0002 0xFF 0x00 Tx String 00 01 00 00 00 06 FF 05 00 02 FF 00 Response WebRelay 10 Response Frame Example Write Coil 3 ON Field Name Length Fun...

Страница 73: ...sages of server and client 0x0001 Protocol Identifier 2 bytes Zero for Modbus TCP 0x0000 Message Length 2 bytes Number of bytes in frame below 0x0003 Unit Identifier 1 byte Slave Address 0xff if not u...

Страница 74: ...8 are changed Both bytes must be specified if relays 9 or 10 are affected Modbus TCP Request Frame Example Write Coils 7 ON 8 OFF and 9 ON Field Name Length Function Example Data Transaction Identifie...

Страница 75: ...0 00 00 06 FF 0F 00 06 00 03 Errors Multiple Coil Write Error Function Code 1 Byte 0x8F Exception codes 1 Byte 0x01 Function not supported 0x02 Incorrect combination of start address and relay quantit...

Страница 76: ...g point number represented as 1234 ABCD is sent ABCD 1234 In the example shown below the relay will pulse for 10 seconds Ten seconds is represented using a floating point number of 41200000 It is tran...

Страница 77: ...00 00 00 06 FF 10 00 16 00 04 Errors Pulse Function code Error 1 Byte 0x90 Exception codes 1 Byte 0x01 Feature not supported 0x02 Address quantity not an even number Incorrect combination of start add...

Страница 78: ...e Control Page Note Inputs and Sensors are only available on WebRelay 10 Plus Subject Line The top line that reads WebRelay 10 appears in the subject line of the email message This is the same text th...

Страница 79: ...l triggers can be generated within a BASIC script See Appendix G BASIC Scripts or can be explicitly defined for each relay input and sensor under Relays Inputs and Sensors tabs The email options and r...

Страница 80: ...a toothpick to press and hold the small button located next to the RJ 45 connector A tactile feel can be detected as the button is pressed CAUTION DO NOT USE METAL OBJECTS FOR THIS FUNCTION 3 While d...

Страница 81: ...to install the framework Setup 1 Download the bootloader exe and the new firmware image from the ControlByWeb website under the WebRelay 10 downloads section Only a WebRelay 10 image can be installed...

Страница 82: ...tep 4 While holding the reset button press the Upload Firmware button at the bottom of the ControlByWeb Programmer window After the programming process begins the reset button can be released 5 Progra...

Страница 83: ...le 192 168 200 167 is an IP address Every device that is directly connected to the Internet uses a public IP address WebRelay 10 can be assigned a public IP address for direct connection to the Intern...

Страница 84: ...s on the WAN side of the router has an IP address that has been assigned by the Internet Service Provider such as 266 70 164 97 This is not a valid IP address because each number cannot be larger than...

Страница 85: ...l device with an assigned port In this example the address 192 168 1 25 for WebRelay 10 would be associated with port 8000 The address 192 168 1 26 for WebRelay would be associated with port 8001 WebR...

Страница 86: ...owing command would be used http 192 168 1 25 8000 setup html To access the ControlByWeb units from the Internet enter the public IP address of the router plus the port number of the desired device in...

Страница 87: ...o request the log file http 192 168 1 2 log txt File Format MM DD YYYY HH MM SS Input 1 Input 2 Relay 1 Relay 2 Relay 10 Sensor 1 Sensor 2 Sensor 8 Source State Date and Time Format MM Month 1 12 DD D...

Страница 88: ...ame Bad Password Email was not sent due to an incorrect password Authentication Required A user name and password are required by the mail server No Response No response from SMTP server CLOCK RTC Res...

Страница 89: ...192 168 1 2 syslog txt Note The setup user name and password are required to access this file If the TCP port has been changed not port 80 the port will be required to read the file For example using...

Страница 90: ...ices Direct Server Control and Remote Services Direct Server Control The first approach is for the external server to create a TCP connection whenever it needs to access WebRelay 10 In this case the e...

Страница 91: ...Advanced Network setup tab The Connection String is a user defined character string configured in the Advanced Network tab The connection string is also sent at the same interval once the connection...

Страница 92: ...section 2 3 3 Advanced Network Tab for more information WebRelay 10 supports the following Packet Data Units PDU GetRequest GetNextRequest SetRequest Trap Standard Objects WebRelay 10 supports severa...

Страница 93: ...tTwo 0 Value 0 or 1 WebRelay 10 Plus Sensors Object Response web10 webrelay_ten_sensorOne 0 Value x x Decimal temperature or humidity web10 webrelay_ten_sensorTwo 0 Value x x Decimal temperature or hu...

Страница 94: ...dity Web10 68 Sensor four alarm x x Decimal temperature or humidity Web10 69 Sensor five alarm x x Decimal temperature or humidity Web10 70 Sensor six alarm x x Decimal temperature or humidity Web10 7...

Страница 95: ...e nested up to 5 times per command For those not familiar with nesting the following is an example of nested FOR loops FOR a 0 to 100 FOR b 0 to 100 NEXT b NEXT a Every program must end with an END st...

Страница 96: ...NEXT The FOR TO statement loops a section of code a predefined number of times The NEXT statement always follows the section of code to be looped The format is FOR variable expression TO expression c...

Страница 97: ...END statement The format is END Subroutines Go Here SUB name of subroutine contents of subroutine END SUB SUB name of subroutine contents of subroutine END SUB REM or The REM or apostrophe statement d...

Страница 98: ...relays can be turned ON turned OFF pulsed toggled or read in BASIC scripts The LET statement is used to set the relay state The state options available are 0 turn relay off 1 turn relay on 2 pulse re...

Страница 99: ...ime The event time variables store the number of seconds from the beginning of the day If the event time variable is incremented more than the number of seconds in a day 86400 seconds the variable is...

Страница 100: ...er for Windows is also available on our website for the use of testing and debugging The WebRelay 10 will only acknowledge errors as it runs This means that if a path of the script is not encountered...

Страница 101: ...tage 277 VAC general purpose 30 VDC NC contact resistive Recommended Max Current 15A Absolute Max Current 40A Contact Resistance 30 milliohms initial Electrical Life 100K cycles typical full rated loa...

Страница 102: ...F Accuracy 0 5 from 10 C to 85 C Maximum number of sensors 8 Maximum Distance from WebRelay 10 to sensors Combined cable length of 600 ft using Cat 5e Additional Sensors WebRelay 10 Plus only Tempera...

Страница 103: ...s Monitor Control Web Browser XML Modbus TCP SNMP Logging WebRelay 10 Plus only Storage Nonvolatile Flash Buffer Architecture Circular Buffer Log File Size 512K max 17900 logs Unlimited data storage f...

Страница 104: ...ping charges to return the product to the purchaser as long as the product is shipped within the continental United States If the product is shipped outside of the continental United States or the pro...

Страница 105: ...the instructions may cause interference to radio communications There is no guarantee however that interference will not occur in a particular installation If this equipment does cause harmful interf...

Страница 106: ...ng or scanning for any purpose other than the personal use by the purchaser of this product Xytronix Research Design Inc assumes no responsibility for any errors that may appear in this document Where...

Страница 107: ...WebRelay 10 Users Manual Appendix L Mechanical Information Appendix L Mechanical Information Xytronix Research Design Inc page 107...

Отзывы: