Difference between revisions of "TRB142 RS232"
Gytispieze (talk | contribs) |
|||
(17 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
− | {{Template: | + | __TOC__ |
− | + | ==Summary== | |
− | | | + | |
− | | | + | {{Template: webui_services_rs232_summary}} |
− | + | ||
− | | | + | ==RS232 Configuration== |
− | | | + | |
− | | | + | {{Template: webui_services_rs232_rs232_configuration_general}} |
− | | | + | |
− | | | + | [[File:Trb142 webui services rs232 rs232 configuration general v1.png]] |
− | + | ||
+ | {{Template: webui_services_rs232_rs232_configuration_general_table}} | ||
+ | |||
+ | ==Serial types== | ||
+ | |||
+ | {{Template: webui_services_rs232_rs232_configuration_serial_types_summary}} | ||
+ | |||
+ | ===Console=== | ||
+ | ---- | ||
+ | {{Template: webui_services_rs232_rs232_configuration_console}} | ||
+ | |||
+ | ===Over IP=== | ||
+ | ---- | ||
+ | {{Template: webui_services_rs232_rs232_configuration_over_ip}} | ||
+ | |||
+ | [[File:Trb142 webui services rs232 rs232 configuration serial type over ip v4.png]] | ||
+ | |||
+ | {{Template: webui_services_rs232_rs232_configuration_over_ip_table}} | ||
+ | |||
+ | ===Modem=== | ||
+ | ---- | ||
+ | {{Template: webui_services_rs232_rs232_configuration_modem}} | ||
+ | |||
+ | [[File:Trb142 webui services rs232 rs232 configuration serial type modem v1.png]] | ||
+ | |||
+ | {{Template: webui_services_rs232_rs232_configuration_modem_table}} | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |+ | ||
+ | ! style="width: 250px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | FIELD NAME | ||
+ | ! style="width: 250px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | VALUE | ||
+ | ! style="width: 579px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | DESCRIPTION | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | Direct connect | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | ip:port {{!}} host:port; Default: " " | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | Maintains a constant connection to the specified host. Leave empty if you are planning to use an ATD command to initiate the connection | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | TCP port | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | integer [0..65535]; Default: " " | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | The TCP port number used to listen for incoming connections. Leave it empty to disable incoming connections | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | Initiation string<span style="color: #0054A6;">'''*'''</span> | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | string; Default: " " | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | A command string that will be sent to the modem to initiate the connection in some particular special way (optional) | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | No extra CR LF in response | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | yes {{!}} no; Default: '''no''' | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | Removes extra CR LF before and LF after response code | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | <span style="color: #0054A6;">'''*'''</span> This is the AT command set used in Modem mode of the serial interfaces: | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |+ | ||
+ | ! style="width: 250px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | COMMAND | ||
+ | ! style="width: 250px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | DESCRIPTION | ||
+ | ! style="width: 579px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | USAGE | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | A | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | Answers an incoming call | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | To answer incoming connection: '''ATA''' | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | D | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | E | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | H | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | O | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | Z | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | ===Modbus gateway=== | ||
+ | ---- | ||
+ | {{Template: webui_services_rs232_rs232_configuration_modbus_gateway}} | ||
+ | The figure below is an example of available configuration fields for the Modbus gateway serial type and the table below provides information on these fields: | ||
+ | [[File:Trb142 webui services rs232 rs232 configuration serial type modbus gateway v1.png]] | ||
+ | |||
+ | {{Template: webui_services_rs232_rs232_configuration_modbus_gateway_table}} | ||
+ | |||
+ | ===NTRIP client=== | ||
+ | ---- | ||
+ | {{Template: webui_services_rs232_rs232_configuration_ntrip_client}} | ||
+ | The figure below is an example of available configuration fields for the NTRIP client serial type and the table below provides information on these fields: | ||
+ | [[File:Trb142 webui services rs232 rs232 configuration serial type ntrip client v1.png]] | ||
+ | |||
+ | {{Template: webui_services_rs232_rs232_configuration_ntrip_client_table}} | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |+ | ||
+ | ! style="width: 250px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | FIELD NAME | ||
+ | ! style="width: 250px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | VALUE | ||
+ | ! style="width: 579px; border: 1px solid white; border-bottom: 2px solid #0054A6; background: white; color: #0054A6; text-align: left;" | DESCRIPTION | ||
+ | |- | ||
+ | ! style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | | style="border: 1px solid white; border-bottom: 2px solid #E8E8E8; text-align: left; vertical-align: top; background: white;" | | ||
+ | |- | ||
+ | |} |
Revision as of 16:43, 18 October 2018
Main Page > TRB Gateways > TRB142 > TRB142 Manual > TRB142 WebUI > TRB142 Services section > TRB142 RS232Summary
The RS232 function is designed to utilize the serial interface of the device. Serial interfaces provide a possibility for legacy devices to gain access to IP networks. This chapter is an overview of the RS232 section.
RS232 Configuration
The RS232 Configuration section is used to configure the parameters of the RS232 serial connection. Parameters used should be selected in accordance with the needs of the user and the type of device connected via the RS232 port.
The figure below is an example of the RS232 Configuration section and the table below provides information on the fields contained in that section:
field name | value | description |
---|---|---|
Enabled | yes | no; Default: no | Enables the RS232 service |
Baud rate | 300 | 1200 | 2400 | 4800 | 9600 | 19200 | 38400 | 57600 | 115200; Default: 115200 | Data rate for serial data transmission (in bits per second) |
Data bits | 5 | 6 | 7 | 8; Default: 8 | Number of data bits for each character |
Parity | None | Odd | Even; Default: None | In serial transmission, parity is a method of detecting errors. An extra data bit is sent with each data character, arranged so that the number of 1 bits in each character, including the parity bit, is always odd or always even. If a byte is received with the wrong number of 1s, then it must have been corrupted. However, an even number of errors can pass the parity check.
|
Stop bits | 1 | 2; Default: 1 | Stop bits sent at the end of every character allow the receiving signal hardware to detect the end of a character and to resynchronise with the character stream. Electronic devices usually use one stop bit. Two stop bits are required if slow electromechanical devices are used |
Flow control | None | RTS/CTS | Xon/Xoff; Default: None | In many circumstances a transmitter might be able to send data faster than the receiver is able to process it. To cope with this, serial lines often incorporate a "handshaking" method, usually distinguished between hardware and software handshaking.
|
Serial type | Console | Over IP | Modem | Modbus gateway | NTRIP client; Default: Console | Serial connection type. More information on each serial type can be seen below or by clicking on a link in the value section |
Echo | yes | no; Default: no | Toggles RS232 echo ON or OFF. RS232 echo is a loopback test usually used to check whether the RS232 cable is working properly |
Serial types
An RS232 serial connection can function in different ways depending on user needs and what devices are connected to the RS232 port. This section of the chapter is an overview of all different RS232 serial types.
Console
In Console mode the serial interface is set up as a Linux console that can be used to control the device (much like a regular SSH connection, except established via RS232). It can be used for debugging purposes, to get the status of the device or to control it. Click here to find a guide on how to set up RS232 in console mode.
Over IP
In Over IP serial type the device provides a connection to a TCP/IP network for the devices connected via the serial interface. The figure below is an example of available configuration fields for the Over IP serial type and the table below provides information on these fields:
field name | value | description |
---|---|---|
Protocol | TCP; Default: TCP | Protocol used in the communication process |
Mode | Server | Client | Bidirect; Default: Server | Device's role in the connection:
|
No leading zeros | yes | no; Default: no | When checked, indicates that the first hex zeros should be skipped |
Client settings: Server address | ip | host; Default: none | IP address or hostname of the server that the client will connect to |
Client settings: TCP port | integer [0..65535]; Default: none | Server's port number |
Client settings: Reconnect interval (s) | integer; Default: none | Time period (in seconds) between reconnection attempts in case a connection fails |
Server settings: TCP port | integer [0..65535]; Default: none | Internal TCP port number used to listen for incoming connections |
Server settings: Timeout (s) | integer; Default: none | Disconnects clients after they remain inactive for an amount time (in seconds) specified in this field |
Output | OC Output | Relay Output; Default: OC Output | Output to indicate that the application switched from client (default) to server state (this field becomes visible only in Bidirect mode) |
Output state | 1 | 0; Default: 0 | Output state value during which the application reverts to server mode (this field becomes visible only in Bidirect mode) |
Modem
In Modem serial type, the device imitates a dial-up modem. Connections to TCP/IP networks can be established using AT commands. The connection can be initiated by a device connected via the RS232 serial interface with an ATD command: ATD <HOST>:<PORT>. If Direct connect settings are specified, the connection to the server is always active. Data mode can be entered by issuing the ATD command. Incoming connections are indicated by sending a RING to the serial interface.
The figure below is an example of available configuration fields for the Modem serial type and the table below provides information on these fields:
field name | value | description |
---|---|---|
Direct connect | ip:port | host:port; Default: none | Maintains a constant connection to the specified host. Leave empty if you are planning to use an ATD command to initiate the connection |
TCP port | integer [0..65535]; Default: none | Internal TCP port number used to listen for incoming connections. Leave it empty to disable incoming connections |
Initiation string* | string; Default: none | A command string that will be sent to the modem to initiate the connection in some particular way (optional) |
No extra CR LF in response | yes | no; Default: no | Removes extra CR LF before response code; removes LF after response code |
* This is the AT command set used in Modem mode of the serial interfaces:
command | description | usage |
---|---|---|
A | Answers an incoming call | To answer incoming connection: ATA |
D | Dials a number | To initiate data connection: ATD <HOST>:<PORT> To enter data mode with Direct connect settings: ATD |
E | Local echo | Turn local echo ON: ATE1 Turn local echo OFF: ATE0 |
H | Hang up current call | To end data connection: ATH |
O | Return to data mode | To return to data mode from command mode: ATO |
Z | Reset to default configuration | To reset the modem to default configuration: ATZ |
FIELD NAME | VALUE | DESCRIPTION |
---|---|---|
Direct connect | ip:port | host:port; Default: " " | Maintains a constant connection to the specified host. Leave empty if you are planning to use an ATD command to initiate the connection |
TCP port | integer [0..65535]; Default: " " | The TCP port number used to listen for incoming connections. Leave it empty to disable incoming connections |
Initiation string* | string; Default: " " | A command string that will be sent to the modem to initiate the connection in some particular special way (optional) |
No extra CR LF in response | yes | no; Default: no | Removes extra CR LF before and LF after response code |
* This is the AT command set used in Modem mode of the serial interfaces:
COMMAND | DESCRIPTION | USAGE |
---|---|---|
A | Answers an incoming call | To answer incoming connection: ATA |
D | ||
E | ||
H | ||
O | ||
Z |
Modbus gateway
The Modbus gateway serial type allows redirecting TCP data coming to a specified port to the RTU specified by the Slave ID. The Slave ID can be specified by the user or be obtained directly from the Modbus header.
The figure below is an example of available configuration fields for the Modbus gateway serial type and the table below provides information on these fields:
The figure below is an example of available configuration fields for the Modbus gateway serial type and the table below provides information on these fields:
field name | value | description |
---|---|---|
Listening IP | ip; Default: 0.0.0.0 | IP address on which the Modbus gateway will wait for incoming connections |
Port | integer [0..65535]; Default: 502 | Port number used to listen for incoming connections |
Slave ID configuration | User defined | Obtained from TCP; Default: User defined | Specifies whether slave IDs should be user defined or automatically obtained from TCP |
Slave ID/Permitted slave IDs | integer | range of integers | multiple integers; Default: 1/1-247 | Slave ID or range of permitted slave IDs. The way this field is named and its function depends on the value of the "Slave ID configuration" field. A range of IDs can be specified by placing a hyphen (-) between two integer numbers. For example, if you permit slave IDs in the range of 10 to 20, you would specify it as: 10-20 You can also specify multiple values that are not connected in a range using commas (,). For example, to specify 6, 50 and 100 as permitted slave IDs, you would have to use: 6,50,100 |
NTRIP client
Networked Transport of RTCM via Internet Protocol (NTRIP) is a protocol for streaming differential GPS (DGPS) data over the Internet in accordance with specifications published by RTCM.
The figure below is an example of available configuration fields for the NTRIP client serial type and the table below provides information on these fields:
The figure below is an example of available configuration fields for the NTRIP client serial type and the table below provides information on these fields:
field name | value | description |
---|---|---|
IP address | ip; Default: 0.0.0.0 | IP address of the NTRIP server |
Port | integer; Default: none | TCP/UDP port used for communication with NTRIP server |
Mount point | path to a file; Default: none | NTRIP mount point |
Data format | NTRIP v2.0 TCP/IP | NTRIP v2.0 RSTP/RTP | NTRIP v1.0 | Automatic detection | NTRIP v2.0 UDP; Default: NTRIP v1.0 | NTRIP version |
User name | string; Default: none | User name used for NTRIP authentication |
Password | string; Default: none | Password used for NTRIP authentication |
Default NMEA string | string; Default: none | Optional NMEA string that will be used as the default value when initiating the connection to the NTRIP server (this value is only sent to the server if there is no NMEA from router's GPS device) |
FIELD NAME | VALUE | DESCRIPTION |
---|---|---|