Files
OpenPLC_v3/config.example.ini
2019-11-27 11:31:54 -05:00

209 lines
6.5 KiB
INI

; This configuration file enables configuring OpenPLC capabilities
; when the OpenPLC runtime starts. These capabilities can be configured
; without using the web front end and enable running the OpenPLC runtime
; standalone.
;
; This file must be located in the "etc" folder and must be named
; "config.ini".
; ---------------------------------------------------------
; ---------------------------------------------------------
[logging]
; Level defines the minimum level for a message to appear
; as a log message. Messages are a lower level are not
; output.
;
; Level may be one of the following values, ordered from
; lowest to highest:
; trace, debug, info, warn, error
level = info
; ---------------------------------------------------------
; ---------------------------------------------------------
[interactive]
; The interactive server is what connects the web front end to the runtime
; You need this enabled if you want to be able to enable/disable services
; at runtime, view logs, etc.
;
; If you set this value to false and use the OpenPLC web interface to
; start the runtime, the web interface will not be able to communicate
; with the runtime.
enabled = true
; ---------------------------------------------------------
; ---------------------------------------------------------
[modbusslave]
; Modbus slave enables reading and writing located variables through the
; modbus interface. This starts a Modbus server (also know as a slave)
; running in the OpenPLC runtime.
enabled = false
; TCP Settings
; ------------
port = 502
address = 127.0.0.1
; How we bind located variables to modbus registers.
; This may be one of:
; sized - indicates to use the size of a located variable to determine
; the register type
binding = sized
; ---------------------------------------------------------
; ---------------------------------------------------------
[modbusmaster]
; Modbus master enables reading and writing located variables through the
; modbus interface. This starts capabilities to poll one or more Modbus
; servers and exchange data with the located variables.
enabled = false
; We support multiple Modbus masters. Each master should specify
; a complete set of configuration information within this section.
; Different masters are identified by a postfix which includes the
; index of the master. Indices start at 0 and go up from there.
; A user defined name for the connection. This name appears in log messages.
; name.0 = 1
; How long to wait for a response before indicating an error.
; Measured in microseconds.
; response_timeout.0 = 100000
; The rate at which to poll the server. Measured in microseconds.
; The actual poll rate may be greater than this depending on response times
; from the remote server and availability of resources on the local host.
; poll_interval.0 = 250000
; The protocol to use for connection. This value must be one of:
; tcp
; rtu
; If you set this to any other value, then this configuration item group
; is not created. You might use this to disable connecting to a particular
; Modbus slave.
; protocol.0 = tcp
; When there are communication failures, should we keep trying
; or backoff intelligently. The default behaviour is no backoff
; but you can specify one of the following:
;
; none - Same as default, no strategy.
; linear_bounded - Back off linearly based on the number of
; failed attempts. Bounded to 10x the poll
; interval.
; backoff_strategy.0 = linear_bounded
; slave_id.0 = 1
; ip_address.0 = 127.0.0.1
; ip_port.0 = 1000
; rtu_baud_rate.0 =
; rtu_parity.0 =
; rtu_data_bit.0 =
; rtu_stop_bit.0 =
; discrete_inputs_start.0 = 0
; discrete_inputs_size.0 = 1
; coils_start.0
; coils_size.0
; input_registers_start.0
; input_registers_size.0
; holding_registers_read_start.0
; holding_registers_read_size.0
; holding_registers_start.0
; holding_registers_size.0
; ---------------------------------------------------------
; ---------------------------------------------------------
[pstorage]
; The pstorage service reads and writes persistent storage. It enables
; the runtime to restore important variables to the previous value
; if the runtime is restarted.
enabled = false
; How long should we wait between write cycle. The persistent storage
; checks at this rate for changes and only persists to disk if a
; value has changed within the poll period
; poll_interval = 10
; poll_interval = 10
; ---------------------------------------------------------
; ---------------------------------------------------------
[dnp3s]
; The dnp3s enables a DNP3 outstation.
enabled = false
; Location Bindings
; -----------------
; Bind OpenPLC bit-sized output 0.0 to DNP3 binary input at index 0
; Note that the second hierarchical index must be 0
; bind_location = name:%QX0.0,group:1,index:0,
; Bind OpenPLC word-sized output 2 to DNP3 analog input at index 1
; bind_location = name:%QW2,group:30,index:1,
; Bind OpenPLC word-sized output 2 to DNP3 analog output status at index 1
; bind_location = name:%QW2,group:40,index:1,
; Bind OpenPLC long word-sized output 2 to DNP3 analog input at index 10
; bind_location = name:%QL2,group:30,index:10,
; Bind OpenPLC bit-sized input 0.0 to DNP3 analog input at index 10
; bind_location = name:%IX0.0,group:12,index:0,
; bind_location = name:%IX1.0,group:12,index:1,
; Bind OpenPLC word-sized input 2 to DNP3 analog command at index 0
; bind_location = name:%IW2,group:41,index:0,
; TCP Settings
; ------------
; address = 127.0.0.1
; port = 20000
; Link Settings
; -------------
; The remote and local address
; local_address = 10
; remote_address = 1
; Keep alive timeout. A value in seconds, or the keyword MAX
; keep_alive_timeout = MAX
; Parameters
; ----------
; Enable unsolicited reporting if master allows it
; enable_unsolicited = true
; How long (seconds) the outstation will allow a operate
; to follow a select
; select_timeout = 10
; max control commands for a single APDU
; max_controls_per_request = 16
; maximum fragment size the outstation will receive
; default is the max value
; max_rx_frag_size = 2048
; maximum fragment size the outstation will send if
; it needs to fragment. Default is the max falure
; max_tx_frag_size = 2048
; size of the event buffer
; event_buffer_size = 10
; Timeout for solicited confirms (milliseconds)
; sol_confirm_timeout = 5000
; Timeout for unsolicited confirms (milliseconds)
; unsol_confirm_timeout = 5000
; Timeout for unsolicited retries (milliseconds)
; unsol_retry_timeout = 5000
; The rate as which data is exchanged between DNP3 and the runtime
; (milliseconds)
; poll_interval = 250