280 friend class CppDecodeLevelFriend;
333 friend class CppRuntimeConfigFriend;
360 friend class CppRuntimeFriend;
364 Runtime(
void* self): self(self) {}
404 friend class CppControlFieldFriend;
471 friend class CppControlCodeFriend;
539 friend class CppGroup12Var1Friend;
580 friend class CppFlagsFriend;
613 friend class CppTimestampFriend;
684 friend class CppBinaryInputFriend;
722 friend class CppBinaryInputIteratorFriend;
756 friend class CppDoubleBitBinaryInputFriend;
794 friend class CppDoubleBitBinaryInputIteratorFriend;
828 friend class CppBinaryOutputStatusFriend;
866 friend class CppBinaryOutputStatusIteratorFriend;
900 friend class CppCounterFriend;
938 friend class CppCounterIteratorFriend;
972 friend class CppFrozenCounterFriend;
1010 friend class CppFrozenCounterIteratorFriend;
1044 friend class CppAnalogInputFriend;
1082 friend class CppAnalogInputIteratorFriend;
1116 friend class CppFrozenAnalogInputFriend;
1154 friend class CppFrozenAnalogInputIteratorFriend;
1188 friend class CppAnalogOutputStatusFriend;
1226 friend class CppAnalogOutputStatusIteratorFriend;
1264 friend class CppBinaryOutputCommandEventFriend;
1304 friend class CppBinaryOutputCommandEventIteratorFriend;
1359 friend class CppAnalogOutputCommandEventFriend;
1402 friend class CppAnalogOutputCommandEventIteratorFriend;
1438 friend class CppUnsignedIntegerFriend;
1470 friend class CppUnsignedIntegerIteratorFriend;
1515 friend class CppByteIteratorFriend;
1523 ByteIterator(
void* iter) : iter(iter), current(
nullptr) {}
1549 friend class CppOctetStringFriend;
1582 friend class CppOctetStringIteratorFriend;
1616 friend class CppConnectOptionsFriend;
1660 friend class CppEndpointListFriend;
1692 void add(
const std::string& endpoint);
1699 friend class CppConnectStrategyFriend;
1768 friend class CppTlsClientConfigFriend;
1827namespace attribute_variations {
2169 friend class CppAttrPropFriend;
2188 friend class CppAttrItemFriend;
2221 friend class CppAttrItemIterFriend;
2229 AttrItemIter(
void* iter) : iter(iter), current(
nullptr) {}
2294namespace functional {
2301 static_assert(std::is_copy_constructible<T>::value,
"Lambda expression must be copy constructible. Does it contain something that is move-only?");
2324 return std::make_unique<PortStateListenerLambda<T>>(lambda); ;
2366namespace functional {
2373 static_assert(std::is_copy_constructible<T>::value,
"Lambda expression must be copy constructible. Does it contain something that is move-only?");
2396 return std::make_unique<ClientStateListenerLambda<T>>(lambda); ;
2686 friend class CppRetryStrategyFriend;
2777 friend class CppSerialSettingsFriend;
2923 friend class CppPermissionSetFriend;
2957 friend class CppPermissionsFriend;
2992 friend class CppOpenFileFriend;
3073 friend class CppFileInfoFriend;
3259 friend class CppLoggingConfigFriend;
3313namespace functional {
3320 static_assert(std::is_copy_constructible<T>::value,
"Lambda expression must be copy constructible. Does it contain something that is move-only?");
3332 lambda(level, message);
3341std::unique_ptr<Logger>
logger(
const T& lambda)
3343 return std::make_unique<LoggerLambda<T>>(lambda); ;
3381 friend class CppIin1Friend;
3421 friend class CppIin2Friend;
3461 friend class CppIinFriend;
3483 friend class CppResponseHeaderFriend;
3533 friend class CppHeaderInfoFriend;
3800struct MasterChannelConfig;
3804 friend class CppMasterChannelConfigFriend;
3850 friend class CppWriteDeadBandRequestFriend;
3992 friend class CppAssociationIdFriend;
4011 friend class CppPollIdFriend;
4019 PollId(uint16_t association_id, uint64_t
id);
4024 uint16_t association_id;
4033 friend class CppEventClassesFriend;
4079 friend class CppClassesFriend;
4145 friend class CppAssociationConfigFriend;
4215 friend class CppUtcTimestampFriend;
4273namespace functional {
4280 static_assert(std::is_copy_constructible<T>::value,
"Lambda expression must be copy constructible. Does it contain something that is move-only?");
4303 return std::make_unique<AssociationHandlerLambda<T>>(lambda); ;
4421 friend class CppRequestFriend;
4425 Request(
void* self): self(self) {}
4623 friend class CppCommandSetFriend;
4916 virtual void on_complete(std::chrono::steady_clock::duration result) = 0;
4983 friend class CppFileReadConfigFriend;
5015 friend class CppDirReadConfigFriend;
5058 friend class CppFileInfoIteratorFriend;
5172 friend class CppMasterChannelFriend;
5211 AssociationId add_association(uint16_t address,
const AssociationConfig& config, std::unique_ptr<ReadHandler> read_handler, std::unique_ptr<AssociationHandler> association_handler, std::unique_ptr<AssociationInformation> association_information);
5223 AssociationId add_udp_association(uint16_t address,
const std::string& destination,
const AssociationConfig& config, std::unique_ptr<ReadHandler> read_handler, std::unique_ptr<AssociationHandler> association_handler, std::unique_ptr<AssociationInformation> association_information);
5488 void open_file(
const AssociationId& association,
const std::string& file_name, uint32_t auth_key,
const Permissions& permissions, uint32_t file_size,
FileMode file_mode, uint16_t max_block_size, std::unique_ptr<FileOpenCallback> callback);
5500 void write_file_block(
const AssociationId& association, uint32_t handle, uint32_t block_number,
bool final_block,
const std::vector<uint8_t>& block_data, std::unique_ptr<FileOperationCallback> callback);
5547 friend class CppAcceptHandlerFriend;
5583 friend class CppIdentifiedLinkHandlerFriend;
5655 friend class CppLinkIdConfigFriend;
5688 friend class CppMasterServerFriend;
5761 friend class CppUpdateInfoFriend;
5805 friend class CppUpdateOptionsFriend;
5898 friend class CppBinaryInputConfigFriend;
5956 friend class CppDoubleBitBinaryInputConfigFriend;
6012 friend class CppBinaryOutputStatusConfigFriend;
6076 friend class CppCounterConfigFriend;
6148 friend class CppFrozenCounterConfigFriend;
6228 friend class CppAnalogInputConfigFriend;
6304 friend class CppAnalogOutputStatusConfigFriend;
6357 friend class CppDatabaseFriend;
6361 Database(
void* self): self(self) {}
6738namespace functional {
6745 static_assert(std::is_copy_constructible<T>::value,
"Lambda expression must be copy constructible. Does it contain something that is move-only?");
6773class DatabaseHandle;
6779 friend class CppDatabaseHandleFriend;
6808 friend class CppEventBufferConfigFriend;
6863 friend class CppClassZeroConfigFriend;
6920 friend class CppOutstationFeaturesFriend;
6961 friend class CppOutstationConfigFriend;
6982 OutstationConfig(uint16_t
outstation_address, uint16_t
master_address,
const EventBufferConfig&
event_buffer_config, uint16_t
solicited_buffer_size, uint16_t
unsolicited_buffer_size, uint16_t
rx_buffer_size,
const DecodeLevel&
decode_level, std::chrono::steady_clock::duration
confirm_timeout, std::chrono::steady_clock::duration
select_timeout,
const OutstationFeatures&
features, uint32_t
max_unsolicited_retries, std::chrono::steady_clock::duration
unsolicited_retry_delay, std::chrono::steady_clock::duration
keep_alive_timeout, uint16_t
max_read_request_headers, uint16_t
max_controls_per_request,
const ClassZeroConfig&
class_zero);
7076 friend class CppRestartDelayFriend;
7171 friend class CppApplicationIinFriend;
7210 friend class CppClassCountFriend;
7235 friend class CppTypeCountFriend;
7275 friend class CppBufferStateFriend;
7561struct RequestHeader;
7565 friend class CppRequestHeaderFriend;
7838namespace functional {
7845 static_assert(std::is_copy_constructible<T>::value,
"Lambda expression must be copy constructible. Does it contain something that is move-only?");
7868 return std::make_unique<ConnectionStateListenerLambda<T>>(lambda); ;
7875struct OutstationUdpConfig;
7879 friend class CppOutstationUdpConfigFriend;
7923 friend class CppOutstationFriend;
8010 static Outstation create_serial_session_2(
Runtime& runtime,
const std::string& serial_path,
const SerialSettings& settings, std::chrono::steady_clock::duration open_retry_delay,
const OutstationConfig& config, std::unique_ptr<OutstationApplication> application, std::unique_ptr<OutstationInformation> information, std::unique_ptr<ControlHandler> control_handler, std::unique_ptr<PortStateListener> port_listener);
8043 static Outstation create_tls_client(
Runtime& runtime,
LinkErrorMode link_error_mode,
EndpointList& endpoints,
const ConnectStrategy& connect_strategy,
ConnectOptions& connect_options,
const OutstationConfig& config, std::unique_ptr<OutstationApplication> application, std::unique_ptr<OutstationInformation> information, std::unique_ptr<ControlHandler> control_handler, std::unique_ptr<ClientStateListener> listener,
const TlsClientConfig& tls_config);
8064 friend class CppAddressFilterFriend;
8098 void add(
const std::string& address);
8110 friend class CppTlsServerConfigFriend;
8176 friend class CppOutstationServerFriend;
8210 Outstation add_outstation(
const OutstationConfig& config, std::unique_ptr<OutstationApplication> application, std::unique_ptr<OutstationInformation> information, std::unique_ptr<ControlHandler> control_handler, std::unique_ptr<ConnectionStateListener> listener,
AddressFilter& filter);
Class used to accept a connection, reject it, or defer it to link identification.
Definition: dnp3.hpp:5546
AcceptHandler(AcceptHandler &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:5562
ParamError accept(LinkErrorMode error_mode, const MasterChannelConfig &config)
Accept the connection and create a master channel.
ParamError get_link_identity()
Request that server attempt to identify the outstation by reading a link-layer header from the physic...
Filters connecting client by their IP address to associate a connecting master with an outstation on ...
Definition: dnp3.hpp:8063
static AddressFilter any()
Create an address filter that accepts any IP address.
AddressFilter(const std::string &address)
Create an address filter that matches a specific address or wildcards.
AddressFilter(AddressFilter &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:8079
~AddressFilter()
Destroy an address filter.
void add(const std::string &address)
Add an accepted IP address to the filter.
Iterator over AnalogOutputCommandEvent instances.
Definition: dnp3.hpp:1400
AnalogOutputCommandEventIterator(AnalogOutputCommandEventIterator &&)=default
move constructor for the iterator
AnalogOutputCommandEvent get()
retrieve the current value
bool next()
move the iterator to the next value
Iterator over AnalogOutputStatus instances.
Definition: dnp3.hpp:1224
AnalogOutputStatus get()
retrieve the current value
bool next()
move the iterator to the next value
AnalogOutputStatusIterator(AnalogOutputStatusIterator &&)=default
move constructor for the iterator
Callbacks for a particular outstation association.
Definition: dnp3.hpp:4258
virtual UtcTimestamp get_current_time()=0
Returns the current time or an invalid time if none is available.
Iterator over AttrItem instances.
Definition: dnp3.hpp:2219
AttrItem get()
retrieve the current value
AttrItemIter(AttrItemIter &&)=default
move constructor for the iterator
bool next()
move the iterator to the next value
Iterator over BinaryOutputCommandEvent instances.
Definition: dnp3.hpp:1302
bool next()
move the iterator to the next value
BinaryOutputCommandEvent get()
retrieve the current value
BinaryOutputCommandEventIterator(BinaryOutputCommandEventIterator &&)=default
move constructor for the iterator
Iterator over BinaryOutputStatus instances.
Definition: dnp3.hpp:864
bool next()
move the iterator to the next value
BinaryOutputStatus get()
retrieve the current value
BinaryOutputStatusIterator(BinaryOutputStatusIterator &&)=default
move constructor for the iterator
Iterator over uint8_t instances.
Definition: dnp3.hpp:1513
ByteIterator(ByteIterator &&)=default
move constructor for the iterator
uint8_t get()
retrieve the current value
bool next()
move the iterator to the next value
Callback for monitoring the client TCP connection state.
Definition: dnp3.hpp:2355
virtual void on_change(ClientState state)=0
Called when the client state changed.
Exception type corresponding to the underlying error enum CommandError.
Definition: dnp3.hpp:4759
CommandException(CommandError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:4764
CommandError error
underlying error enum
Definition: dnp3.hpp:4762
Builder type used to construct command requests.
Definition: dnp3.hpp:4622
~CommandSet()
Destroy a set of commands.
void add_g41_v1_u16(uint16_t idx, int32_t value)
Add a Analog Output command (signed 32-bit integer) with 2-byte prefix index.
void add_g12_v1_u16(uint16_t idx, const Group12Var1 &header)
Add a CROB with 2-byte prefix index.
void add_g41_v3_u8(uint8_t idx, float value)
Add a Analog Output command (single-precision float) with 1-byte prefix index.
CommandSet(CommandSet &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:4638
void add_g41_v4_u16(uint16_t idx, double value)
Add a Analog Output command (double-precision float) with 2-byte prefix index.
void add_g12_v1_u8(uint8_t idx, const Group12Var1 &header)
Add a CROB with 1-byte prefix index.
CommandSet()
Create a new set of commands.
void add_g41_v1_u8(uint8_t idx, int32_t value)
Add a Analog Output command (signed 32-bit integer) with 1-byte prefix index.
void add_g41_v3_u16(uint16_t idx, float value)
Add a Analog Output command (single-precision float) with 2-byte prefix index.
void add_g41_v2_u8(uint8_t idx, int16_t value)
Add a Analog Output command (signed 16-bit integer) with 1-byte prefix index.
void finish_header()
Finish any partially completed header. This allows for the construction of two headers with the same ...
void add_g41_v4_u8(uint8_t idx, double value)
Add a Analog Output command (double-precision float) with 1-byte prefix index.
void add_g41_v2_u16(uint16_t idx, int16_t value)
Add a Analog Output command (signed 16-bit integer) with 2-byte prefix index.
Handler for command tasks.
Definition: dnp3.hpp:4770
virtual void on_failure(CommandError error)=0
Invoked when the asynchronous operation fails.
virtual void on_complete(Nothing result)=0
Invoked when the asynchronous operation completes successfully.
Options that control how TCP connections are established.
Definition: dnp3.hpp:1615
void set_timeout(std::chrono::steady_clock::duration timeout)
Set a timeout for the TCP connection that might be less than the default for the OS.
void set_local_endpoint(const std::string &endpoint)
Set the local address to which the socket is bound.
ConnectOptions(ConnectOptions &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:1631
~ConnectOptions()
Destroy an instance.
ConnectOptions()
Initialize to the defaults.
Callbacks to user code that determine how the server processes connections.
Definition: dnp3.hpp:5611
virtual void start(const char *remote_addr, MasterChannel &channel)=0
Start a communication session that was previously accepted using only the socket address.
virtual void accept(const char *remote_addr, AcceptHandler &acceptor)=0
Filter the connection solely based on the remote address.
virtual void accept_with_link_id(const char *remote_addr, uint16_t source, uint16_t destination, IdentifiedLinkHandler &acceptor)=0
Filter the connection based on the source and destination of the first link-layer frame.
virtual void start_with_link_id(const char *remote_addr, uint16_t source, uint16_t destination, MasterChannel &channel)=0
Start a communication session that was previously accepted using link identity information.
Callback interface for connection state events.
Definition: dnp3.hpp:7827
virtual void on_change(ConnectionState state)=0
Called when the connection state changes.
Callbacks for handling controls.
Definition: dnp3.hpp:7691
virtual CommandStatus select_g41v4(double value, uint16_t index, DatabaseHandle &database_handle)=0
Select an analog output, but do not operate.
virtual void end_fragment(DatabaseHandle &database)=0
Notifies the end of a command fragment.
virtual CommandStatus operate_g41v1(int32_t value, uint16_t index, OperateType op_type, DatabaseHandle &database_handle)=0
Operate a control point.
virtual CommandStatus operate_g12v1(const Group12Var1 &value, uint16_t index, OperateType op_type, DatabaseHandle &database_handle)=0
Operate a control point.
virtual CommandStatus operate_g41v2(int16_t value, uint16_t index, OperateType op_type, DatabaseHandle &database_handle)=0
Operate a control point.
virtual CommandStatus select_g41v2(int16_t value, uint16_t index, DatabaseHandle &database_handle)=0
Select an analog output, but do not operate.
virtual CommandStatus select_g41v3(float value, uint16_t index, DatabaseHandle &database_handle)=0
Select an analog output, but do not operate.
virtual CommandStatus operate_g41v3(float value, uint16_t index, OperateType op_type, DatabaseHandle &database_handle)=0
Operate a control point.
virtual CommandStatus operate_g41v4(double value, uint16_t index, OperateType op_type, DatabaseHandle &database_handle)=0
Operate a control point.
virtual CommandStatus select_g12v1(const Group12Var1 &value, uint16_t index, DatabaseHandle &database_handle)=0
Select a CROB, but do not operate.
virtual void begin_fragment()=0
Notifies the start of a command fragment.
virtual CommandStatus select_g41v1(int32_t value, uint16_t index, DatabaseHandle &database_handle)=0
Select an analog output, but do not operate.
Iterator over Counter instances.
Definition: dnp3.hpp:936
CounterIterator(CounterIterator &&)=default
move constructor for the iterator
Counter get()
retrieve the current value
bool next()
move the iterator to the next value
Handle typed used to perform transactions on the database inside of control and freeze callbacks.
Definition: dnp3.hpp:6778
void transaction(DatabaseTransaction &callback)
Acquire a mutex on the underlying database and apply a set of changes as a transaction.
DatabaseHandle(DatabaseHandle &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:6794
Database transaction interface.
Definition: dnp3.hpp:6727
virtual void execute(Database &database)=0
Execute a transaction on the provided database.
Internal database access.
Definition: dnp3.hpp:6356
bool remove_frozen_counter(uint16_t index)
Remove a Frozen Counter point.
bool add_analog_output_status(uint16_t index, EventClass point_class, const AnalogOutputStatusConfig &config)
Add a new Analog Output Status point.
Counter get_counter(uint16_t index)
Get a Counter point.
UpdateInfo update_binary_input_2(const BinaryInput &value, const UpdateOptions &options)
Update a BinaryInput point.
bool remove_binary_output_status(uint16_t index)
Remove a Binary Output Status point.
AttrDefError define_time_attr(uint8_t set, bool writable, uint8_t variation, uint64_t value)
Define a DNP3 time attribute.
UpdateInfo update_frozen_counter_2(const FrozenCounter &value, const UpdateOptions &options)
Update an Frozen Counter point.
BinaryOutputStatus get_binary_output_status(uint16_t index)
Get a Binary Output Status point.
DoubleBitBinaryInput get_double_bit_binary_input(uint16_t index)
Get a Double-Bit Binary Input point.
UpdateInfo update_analog_output_status_2(const AnalogOutputStatus &value, const UpdateOptions &options)
Update a Analog Output Status point.
bool update_binary_output_status(const BinaryOutputStatus &value, const UpdateOptions &options)
Update a Binary Output Status point.
AttrDefError define_bool_attr(uint8_t set, bool writable, uint8_t variation, bool value)
Define a boolean attribute which is mapped to an unsigned integer internally.
bool remove_octet_string(uint16_t index)
Remove an Octet String point.
bool update_double_bit_binary_input(const DoubleBitBinaryInput &value, const UpdateOptions &options)
Update a Double-Bit Binary Input point.
bool update_frozen_counter(const FrozenCounter &value, const UpdateOptions &options)
Update an Frozen Counter point.
bool add_double_bit_binary_input(uint16_t index, EventClass point_class, const DoubleBitBinaryInputConfig &config)
Add a new Double-Bit Binary Input point.
UpdateInfo update_counter_2(const Counter &value, const UpdateOptions &options)
Update a Counter point.
AttrDefError define_int_attr(uint8_t set, bool writable, uint8_t variation, int32_t value)
Define a signed integer attribute.
AttrDefError define_string_attr(uint8_t set, bool writable, uint8_t variation, const std::string &value)
Define a string attribute.
bool update_analog_input(const AnalogInput &value, const UpdateOptions &options)
Update a AnalogInput point.
bool add_analog_input(uint16_t index, EventClass point_class, const AnalogInputConfig &config)
Add a new AnalogInput point.
bool add_binary_input(uint16_t index, EventClass point_class, const BinaryInputConfig &config)
Add a new BinaryInput point.
bool add_counter(uint16_t index, EventClass point_class, const CounterConfig &config)
Add a new Counter point.
UpdateInfo update_analog_input_2(const AnalogInput &value, const UpdateOptions &options)
Update a AnalogInput point.
bool add_binary_output_status(uint16_t index, EventClass point_class, const BinaryOutputStatusConfig &config)
Add a new Binary Output Status point.
bool update_binary_input(const BinaryInput &value, const UpdateOptions &options)
Update a BinaryInput point.
bool remove_analog_input(uint16_t index)
Remove an AnalogInput point.
AttrDefError define_double_attr(uint8_t set, bool writable, uint8_t variation, double value)
Define a 64-bit floating point attribute.
AttrDefError define_float_attr(uint8_t set, bool writable, uint8_t variation, float value)
Define a 32-bit floating point attribute.
UpdateInfo update_flags(uint16_t index, UpdateFlagsType flags_type, const Flags &flags, const Timestamp &time, const UpdateOptions &options)
Update the flags for the specified point without changing the value.
UpdateInfo update_binary_output_status_2(const BinaryOutputStatus &value, const UpdateOptions &options)
Update a Binary Output Status point.
bool add_octet_string(uint16_t index, EventClass point_class)
Add a new Octet String point.
UpdateInfo update_octet_string_2(uint16_t index, const std::vector< uint8_t > &value, const UpdateOptions &options)
Update an Octet String point.
AnalogOutputStatus get_analog_output_status(uint16_t index)
Get a Analog Output Status point.
FrozenCounter get_frozen_counter(uint16_t index)
Get a Frozen Counter point.
bool update_counter(const Counter &value, const UpdateOptions &options)
Update a Counter point.
bool remove_counter(uint16_t index)
Remove a Counter point.
Database(Database &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:6372
bool update_octet_string(uint16_t index, const std::vector< uint8_t > &value, const UpdateOptions &options)
Update an Octet String point.
bool remove_double_bit_binary_input(uint16_t index)
Remove a Double-Bit Binary Input point.
UpdateInfo update_double_bit_binary_input_2(const DoubleBitBinaryInput &value, const UpdateOptions &options)
Update a Double-Bit Binary Input point.
AttrDefError define_uint_attr(uint8_t set, bool writable, uint8_t variation, uint32_t value)
Define an unsigned integer attribute.
BinaryInput get_binary_input(uint16_t index)
Get a BinaryInput point.
AnalogInput get_analog_input(uint16_t index)
Get a AnalogInput point.
bool update_analog_output_status(const AnalogOutputStatus &value, const UpdateOptions &options)
Update a Analog Output Status point.
bool remove_analog_output_status(uint16_t index)
Remove an Analog Output Status point.
bool remove_binary_input(uint16_t index)
Remove a BinaryInput point.
bool add_frozen_counter(uint16_t index, EventClass point_class, const FrozenCounterConfig &config)
Add a new Frozen Counter point.
Callback interface for any task that expects an empty response.
Definition: dnp3.hpp:3972
virtual void on_failure(EmptyResponseError error)=0
Invoked when the asynchronous operation fails.
virtual void on_complete(Nothing result)=0
Invoked when the asynchronous operation completes successfully.
Exception type corresponding to the underlying error enum EmptyResponseError.
Definition: dnp3.hpp:3961
EmptyResponseException(EmptyResponseError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:3966
EmptyResponseError error
underlying error enum
Definition: dnp3.hpp:3964
List of IP endpoints.
Definition: dnp3.hpp:1659
EndpointList(EndpointList &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:1675
~EndpointList()
Destroy a previously allocated endpoint list.
void add(const std::string &endpoint)
Add an IP endpoint to the list.
EndpointList(const std::string &main_endpoint)
Create a new list of IP endpoints.
Callback interface used when obtaining an authentication key.
Definition: dnp3.hpp:3145
virtual void on_complete(uint32_t result)=0
Invoked when the asynchronous operation completes successfully.
virtual void on_failure(FileError error)=0
Invoked when the asynchronous operation fails.
Exception type corresponding to the underlying error enum FileError.
Definition: dnp3.hpp:3059
FileException(FileError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:3064
FileError error
underlying error enum
Definition: dnp3.hpp:3062
Callback interface for retrieving file info asynchronously.
Definition: dnp3.hpp:4928
virtual void on_failure(FileError error)=0
Invoked when the asynchronous operation fails.
virtual void on_complete(const FileInfo &result)=0
Invoked when the asynchronous operation completes successfully.
Iterator over FileInfo instances.
Definition: dnp3.hpp:5056
FileInfo get()
retrieve the current value
FileInfoIterator(FileInfoIterator &&)=default
move constructor for the iterator
bool next()
move the iterator to the next value
Callback interface used when opening a file.
Definition: dnp3.hpp:3107
virtual void on_complete(const OpenFile &result)=0
Invoked when the asynchronous operation completes successfully.
virtual void on_failure(FileError error)=0
Invoked when the asynchronous operation fails.
Callback interface used when closing a file or writing a block of file data.
Definition: dnp3.hpp:3126
virtual void on_complete(Nothing result)=0
Invoked when the asynchronous operation completes successfully.
virtual void on_failure(FileError error)=0
Invoked when the asynchronous operation fails.
Callbacks for reading a file from the outstation asynchronously.
Definition: dnp3.hpp:4947
virtual bool opened(uint32_t size)=0
Called when the file is successfully opened.
virtual bool block_received(uint32_t block_num, ByteIterator &data)=0
Called when the next block is received.
virtual void completed()=0
Called when the transfer completes successfully.
virtual void aborted(FileError error)=0
Called when the transfer is aborted before completion due to an error or user request.
Iterator over FrozenCounter instances.
Definition: dnp3.hpp:1008
FrozenCounter get()
retrieve the current value
bool next()
move the iterator to the next value
FrozenCounterIterator(FrozenCounterIterator &&)=default
move constructor for the iterator
Class used to accept a connection, reject it, or defer it to link identification.
Definition: dnp3.hpp:5582
ParamError accept(LinkErrorMode error_mode, const MasterChannelConfig &config)
Accept the connection and create a master channel.
IdentifiedLinkHandler(IdentifiedLinkHandler &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:5598
Handler for link status check.
Definition: dnp3.hpp:5150
virtual void on_complete(Nothing result)=0
Invoked when the asynchronous operation completes successfully.
virtual void on_failure(LinkStatusError error)=0
Invoked when the asynchronous operation fails.
Exception type corresponding to the underlying error enum LinkStatusError.
Definition: dnp3.hpp:5139
LinkStatusError error
underlying error enum
Definition: dnp3.hpp:5142
LinkStatusException(LinkStatusError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:5144
Logging interface that receives the log messages and writes them somewhere.
Definition: dnp3.hpp:3301
virtual void on_message(LogLevel level, const char *message)=0
Called when a log message was received and should be logged.
Provides a static method for configuring logging.
Definition: dnp3.hpp:3349
static void configure(const LoggingConfig &config, std::unique_ptr< Logger > logger)
Set the callback that will receive all the log messages.
Represents a communication channel for a master station.
Definition: dnp3.hpp:5171
void get_file_info(const AssociationId &association, const std::string &file_name, std::unique_ptr< FileInfoCallback > callback)
Asynchronously retrieve information on a particular file.
void read_file_with_auth(const AssociationId &association, const std::string &remote_file_path, const FileReadConfig &config, std::unique_ptr< FileReader > reader, const std::string &user_name, const std::string &password)
Start an operation to READ a file from the outstation using a FileReader to receive data.
void read_file(const AssociationId &association, const std::string &remote_file_path, const FileReadConfig &config, std::unique_ptr< FileReader > reader)
Start an operation to READ a file from the outstation using a FileReader to receive data.
void read(const AssociationId &association, Request &request, std::unique_ptr< ReadTaskCallback > callback)
Perform a read on the association.
void warm_restart(const AssociationId &association, std::unique_ptr< RestartTaskCallback > callback)
Asynchronously perform a warm restart operation to the association.
void cold_restart(const AssociationId &association, std::unique_ptr< RestartTaskCallback > callback)
Asynchronously perform a cold restart operation to the association.
void send_and_expect_empty_response(const AssociationId &association, FunctionCode function, Request &headers, std::unique_ptr< EmptyResponseCallback > callback)
Send the specified request to the association using the supplied function and collection of request h...
void get_file_auth_key(const AssociationId &association, const std::string &username, const std::string &password, std::unique_ptr< FileAuthCallback > callback)
Obtain a file authentication key.
void remove_poll(const PollId &poll_id)
Add a periodic poll to an association.
void enable()
start communications
void demand_poll(const PollId &poll_id)
Demand the immediate execution of a poll previously created with MasterChannel::add_poll().
void synchronize_time(const AssociationId &association, TimeSyncMode mode, std::unique_ptr< TimeSyncTaskCallback > callback)
Asynchronously perform a time sync operation to the association.
void open_file(const AssociationId &association, const std::string &file_name, uint32_t auth_key, const Permissions &permissions, uint32_t file_size, FileMode file_mode, uint16_t max_block_size, std::unique_ptr< FileOpenCallback > callback)
Asynchronously open a file.
void disable()
stop communications
PollId add_poll(const AssociationId &id, Request &request, std::chrono::steady_clock::duration period)
Add a periodic poll to an association.
void write_dead_bands(const AssociationId &association, WriteDeadBandRequest &request, std::unique_ptr< EmptyResponseCallback > callback)
Perform a WRITE on the association using the supplied collection of dead-band headers.
DecodeLevel get_decode_level()
Get the decoding level for the channel.
static MasterChannel create_tls_channel(Runtime &runtime, LinkErrorMode link_error_mode, const MasterChannelConfig &config, EndpointList &endpoints, const ConnectStrategy &connect_strategy, std::unique_ptr< ClientStateListener > listener, const TlsClientConfig &tls_config)
Create a master channel that connects to the specified TCP endpoint(s) and establish a TLS session wi...
void write_file_block(const AssociationId &association, uint32_t handle, uint32_t block_number, bool final_block, const std::vector< uint8_t > &block_data, std::unique_ptr< FileOperationCallback > callback)
Asynchronously write a block of file data to the outstation.
void read_with_handler(const AssociationId &association, Request &request, std::unique_ptr< ReadHandler > handler, std::unique_ptr< ReadTaskCallback > callback)
Perform a read on the association.
static MasterChannel create_tcp_channel_2(Runtime &runtime, LinkErrorMode link_error_mode, const MasterChannelConfig &config, EndpointList &endpoints, const ConnectStrategy &connect_strategy, ConnectOptions &connect_options, std::unique_ptr< ClientStateListener > listener)
Create a master channel that connects to the specified TCP endpoint(s)
AssociationId add_association(uint16_t address, const AssociationConfig &config, std::unique_ptr< ReadHandler > read_handler, std::unique_ptr< AssociationHandler > association_handler, std::unique_ptr< AssociationInformation > association_information)
Add an association to the channel.
void read_directory_with_auth(const AssociationId &association, const std::string &dir_path, const DirReadConfig &config, const std::string &user_name, const std::string &password, std::unique_ptr< ReadDirectoryCallback > callback)
Asynchronously retrieve a directory listing by first obtaining an authentication key.
void close_file(const AssociationId &association, uint32_t handle, std::unique_ptr< FileOperationCallback > callback)
Asynchronously close a file.
void operate(const AssociationId &association, CommandMode mode, CommandSet &command, std::unique_ptr< CommandTaskCallback > callback)
Asynchronously perform a command operation on the association.
~MasterChannel()
Shutdown a MasterChannel and release all resources.
static MasterChannel create_tcp_channel(Runtime &runtime, LinkErrorMode link_error_mode, const MasterChannelConfig &config, EndpointList &endpoints, const ConnectStrategy &connect_strategy, std::unique_ptr< ClientStateListener > listener)
Create a master channel that connects to the specified TCP endpoint(s)
void remove_association(const AssociationId &id)
Remove an association from the channel.
MasterChannel(MasterChannel &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:5187
static MasterChannel create_udp_channel(Runtime &runtime, const MasterChannelConfig &config, const std::string &local_endpoint, LinkReadMode link_read_mode, std::chrono::steady_clock::duration retry_delay)
Create a UDP master channel on the local endpoint.
static MasterChannel create_tls_channel_2(Runtime &runtime, LinkErrorMode link_error_mode, const MasterChannelConfig &config, EndpointList &endpoints, const ConnectStrategy &connect_strategy, ConnectOptions &connect_options, std::unique_ptr< ClientStateListener > listener, const TlsClientConfig &tls_config)
Create a master channel that connects to the specified TCP endpoint(s) and establish a TLS session wi...
void check_link_status(const AssociationId &association, std::unique_ptr< LinkStatusCallback > callback)
Asynchronously perform a link status check.
void set_decode_level(const DecodeLevel &decode_level)
Set the decoding level for the channel.
AssociationId add_udp_association(uint16_t address, const std::string &destination, const AssociationConfig &config, std::unique_ptr< ReadHandler > read_handler, std::unique_ptr< AssociationHandler > association_handler, std::unique_ptr< AssociationInformation > association_information)
Add a UDP association to the channel.
void read_directory(const AssociationId &association, const std::string &dir_path, const DirReadConfig &config, std::unique_ptr< ReadDirectoryCallback > callback)
Asynchronously retrieve a directory listing.
static MasterChannel create_serial_channel(Runtime &runtime, const MasterChannelConfig &config, const std::string &path, const SerialSettings &serial_params, std::chrono::steady_clock::duration open_retry_delay, std::unique_ptr< PortStateListener > listener)
Create a master channel on the specified serial port.
Class with methods used to spawn servers.
Definition: dnp3.hpp:5687
MasterServer(MasterServer &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:5703
static MasterServer create_tcp_server(Runtime &runtime, const std::string &local_addr, const LinkIdConfig &link_id_config, std::unique_ptr< ConnectionHandler > connection_handler)
Spawn a TCP server that accepts connections from outstations.
~MasterServer()
Shutdown down the server.
Iterator over OctetString instances.
Definition: dnp3.hpp:1580
OctetString get()
retrieve the current value
OctetStringIterator(OctetStringIterator &&)=default
move constructor for the iterator
bool next()
move the iterator to the next value
Dynamic information required by the outstation from the user application.
Definition: dnp3.hpp:7296
virtual FreezeResult freeze_counters_range(uint16_t start, uint16_t stop, FreezeType freeze_type, DatabaseHandle &database_handle)
Freeze a range of counters.
Definition: dnp3.hpp:7370
virtual RestartDelay warm_restart()=0
Request that the outstation perform a warm restart (IEEE-1815 2012, p. 58)
virtual void event_cleared(uint64_t id)
Called when an event is cleared from the buffer due to master acknowledgement.
Definition: dnp3.hpp:7550
virtual void end_confirm(const BufferState &state)
Called when all relevant events have been cleared.
Definition: dnp3.hpp:7557
virtual bool write_octet_string_attr(uint8_t set, uint8_t variation, OctetStringAttr attr_type, ByteIterator &value)
Write an octet-string attribute. This method is only called if the corresponding attribute has been c...
Definition: dnp3.hpp:7509
virtual bool write_uint_attr(uint8_t set, uint8_t variation, UintAttr attr_type, uint32_t value)
Write an unsigned integer attribute. This method is only called if the corresponding attribute has be...
Definition: dnp3.hpp:7483
virtual bool write_string_attr(uint8_t set, uint8_t variation, StringAttr attr_type, const char *value)
Write a string attribute. This method is only called if the corresponding attribute has been configur...
Definition: dnp3.hpp:7444
virtual FreezeResult freeze_counters_all(FreezeType freeze_type, DatabaseHandle &database_handle)
Freeze all the counters.
Definition: dnp3.hpp:7343
virtual void write_analog_dead_band(uint16_t index, double dead_band)
Called when the outstation begins processing a header to write analog dead-bands.
Definition: dnp3.hpp:7425
virtual FreezeResult freeze_counters_all_at_time(DatabaseHandle &database_handle, uint64_t time, uint32_t interval)
Freeze all the counters at a requested time and interval.
Definition: dnp3.hpp:7357
virtual bool write_float_attr(uint8_t set, uint8_t variation, FloatAttr attr_type, float value)
Write a 32-bit floating point attribute. This method is only called if the corresponding attribute ha...
Definition: dnp3.hpp:7457
virtual RestartDelay cold_restart()=0
Request that the outstation perform a cold restart (IEEE-1815 2012, p. 58)
virtual ApplicationIin get_application_iin()=0
Returns the application-controlled IIN bits.
virtual uint16_t get_processing_delay_ms()=0
Returns the DELAY_MEASUREMENT delay.
virtual bool write_int_attr(uint8_t set, uint8_t variation, IntAttr attr_type, int32_t value)
Write a signed integer attribute. This method is only called if the corresponding attribute has been ...
Definition: dnp3.hpp:7496
virtual FreezeResult freeze_counters_range_at_time(uint16_t start, uint16_t stop, DatabaseHandle &database_handle, uint64_t time, uint32_t interval)
Freeze a range of counters at a requested time and interval.
Definition: dnp3.hpp:7386
virtual void end_write_analog_dead_bands()
Called when the outstation completes processing a header to write analog dead-bands.
Definition: dnp3.hpp:7433
virtual bool support_write_analog_dead_bands()
Controls outstation support for writing group 34, analog input dead-bands.
Definition: dnp3.hpp:7405
virtual void begin_confirm()
Called when a CONFIRM is received to a response or unsolicited response, but before any previously tr...
Definition: dnp3.hpp:7543
virtual void begin_write_analog_dead_bands()
Called when the outstation begins processing a header to write analog dead-bands.
Definition: dnp3.hpp:7413
virtual WriteTimeResult write_absolute_time(uint64_t time)=0
Handle a write of the absolute time during time synchronization procedures.
virtual bool write_double_attr(uint8_t set, uint8_t variation, FloatAttr attr_type, double value)
Write a 64-bit floating point attribute. This method is only called if the corresponding attribute ha...
Definition: dnp3.hpp:7470
virtual bool write_time_attr(uint8_t set, uint8_t variation, TimeAttr attr_type, uint64_t value)
Write a DNP3 time attribute. This method is only called if the corresponding attribute has been confi...
Definition: dnp3.hpp:7535
virtual bool write_bit_string_attr(uint8_t set, uint8_t variation, BitStringAttr attr_type, ByteIterator &value)
Write a bit-string attribute. This method is only called if the corresponding attribute has been conf...
Definition: dnp3.hpp:7522
TCP server that listens for connections and routes the messages to outstations.
Definition: dnp3.hpp:8175
Outstation add_outstation(const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler, std::unique_ptr< ConnectionStateListener > listener, AddressFilter &filter)
Add an outstation to the server.
~OutstationServer()
Gracefully shutdown all the outstations associated to this server, stops the server and release resou...
void bind()
Bind the server to the port and starts listening. Also starts all the outstations associated to it.
OutstationServer(OutstationServer &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:8191
static OutstationServer create_tls_server(Runtime &runtime, LinkErrorMode link_error_mode, const std::string &address, const TlsServerConfig &tls_config)
Create a new TLS server.
static OutstationServer create_tcp_server(Runtime &runtime, LinkErrorMode link_error_mode, const std::string &address)
Create a new TCP server.
Outstation handle.
Definition: dnp3.hpp:7922
void set_decode_level(const DecodeLevel &level)
Set decoding log level.
static Outstation create_tcp_client(Runtime &runtime, LinkErrorMode link_error_mode, EndpointList &endpoints, const ConnectStrategy &connect_strategy, ConnectOptions &connect_options, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler, std::unique_ptr< ClientStateListener > listener)
Create an outstation instance running as a TCP client.
static Outstation create_serial_session_2(Runtime &runtime, const std::string &serial_path, const SerialSettings &settings, std::chrono::steady_clock::duration open_retry_delay, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler, std::unique_ptr< PortStateListener > port_listener)
Create an outstation instance running on a serial port which is tolerant to the serial port being add...
~Outstation()
Free resources of the outstation.
static Outstation create_serial_session(Runtime &runtime, const std::string &serial_path, const SerialSettings &settings, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler)
Create an outstation instance running on a serial port.
static Outstation create_serial_session_fault_tolerant(Runtime &runtime, const std::string &serial_path, const SerialSettings &settings, std::chrono::steady_clock::duration open_retry_delay, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler)
This method is implemented in terms of Outstation::create_serial_session_2() but without a port liste...
void disable()
disable communications
static Outstation create_udp(Runtime &runtime, const OutstationUdpConfig &udp_config, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler)
Create an outstation instance running on a serial port which is tolerant to the serial port being add...
void enable()
enable communications
void transaction(DatabaseTransaction &callback)
Acquire a mutex on the underlying database and apply a set of changes as a transaction.
Outstation(Outstation &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:7938
static Outstation create_tls_client(Runtime &runtime, LinkErrorMode link_error_mode, EndpointList &endpoints, const ConnectStrategy &connect_strategy, ConnectOptions &connect_options, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler, std::unique_ptr< ClientStateListener > listener, const TlsClientConfig &tls_config)
Create an outstation instance running as a TLS client.
Exception type corresponding to the underlying error enum ParamError.
Definition: dnp3.hpp:133
ParamError error
underlying error enum
Definition: dnp3.hpp:136
ParamException(ParamError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:138
Callback interface for receiving updates about the state of a serial port.
Definition: dnp3.hpp:2282
virtual void on_change(PortState state)=0
Invoked when the serial port changes state.
Callback interface for retrieving a directory list.
Definition: dnp3.hpp:5091
virtual void on_failure(FileError error)=0
Invoked when the asynchronous operation fails.
virtual void on_complete(FileInfoIterator &result)=0
Invoked when the asynchronous operation completes successfully.
Exception type corresponding to the underlying error enum ReadError.
Definition: dnp3.hpp:4592
ReadException(ReadError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:4597
ReadError error
underlying error enum
Definition: dnp3.hpp:4595
Callback interface used to received measurement values received from the outstation.
Definition: dnp3.hpp:3579
virtual void handle_binary_input(const HeaderInfo &info, BinaryInputIterator &values)
Handle binary input data.
Definition: dnp3.hpp:3605
virtual void handle_bool_attr(const HeaderInfo &info, BoolAttr attr, uint8_t set, uint8_t variation, bool value)
Handle a boolean device attribute.
Definition: dnp3.hpp:3739
virtual void handle_analog_output_status(const HeaderInfo &info, AnalogOutputStatusIterator &values)
Handle analog output status data.
Definition: dnp3.hpp:3661
virtual void handle_octet_string_attr(const HeaderInfo &info, OctetStringAttr attr, uint8_t set, uint8_t variation, ByteIterator &value)
Handle an octet string device attribute.
Definition: dnp3.hpp:3785
virtual void handle_binary_output_command_event(const HeaderInfo &info, BinaryOutputCommandEventIterator &values)
Handle binary output command events.
Definition: dnp3.hpp:3669
virtual void handle_double_bit_binary_input(const HeaderInfo &info, DoubleBitBinaryInputIterator &values)
Handle double-bit binary input data.
Definition: dnp3.hpp:3613
virtual void handle_frozen_counter(const HeaderInfo &info, FrozenCounterIterator &values)
Handle frozen counter input data.
Definition: dnp3.hpp:3637
virtual void handle_int_attr(const HeaderInfo &info, IntAttr attr, uint8_t set, uint8_t variation, int32_t value)
Handle a signed integer device attribute.
Definition: dnp3.hpp:3752
virtual void end_fragment(ReadType read_type, const ResponseHeader &header)
Called when all the data from a response fragment has been processed.
Definition: dnp3.hpp:3597
virtual void handle_analog_output_command_event(const HeaderInfo &info, AnalogOutputCommandEventIterator &values)
Handle analog output command events.
Definition: dnp3.hpp:3677
virtual void handle_octet_string(const HeaderInfo &info, OctetStringIterator &values)
Handle octet string data.
Definition: dnp3.hpp:3693
virtual void handle_float_attr(const HeaderInfo &info, FloatAttr attr, uint8_t set, uint8_t variation, double value)
Handle a floating point device attribute.
Definition: dnp3.hpp:3774
virtual void begin_fragment(ReadType read_type, const ResponseHeader &header)
Called when a valid response fragment is received, but before any measurements are processed.
Definition: dnp3.hpp:3589
virtual void handle_binary_output_status(const HeaderInfo &info, BinaryOutputStatusIterator &values)
Handle binary output status data.
Definition: dnp3.hpp:3621
virtual void handle_uint_attr(const HeaderInfo &info, UintAttr attr, uint8_t set, uint8_t variation, uint32_t value)
Handle an unsigned integer device attribute.
Definition: dnp3.hpp:3726
virtual void handle_variation_list_attr(const HeaderInfo &info, VariationListAttr attr, uint8_t set, uint8_t variation, AttrItemIter &value)
Handle a known or unknown list of attribute variations.
Definition: dnp3.hpp:3715
virtual void handle_string_attr(const HeaderInfo &info, StringAttr attr, uint8_t set, uint8_t variation, const char *value)
Handle a known or unknown visible string device attribute.
Definition: dnp3.hpp:3704
virtual void handle_counter(const HeaderInfo &info, CounterIterator &values)
Handle counter data.
Definition: dnp3.hpp:3629
virtual void handle_analog_input(const HeaderInfo &info, AnalogInputIterator &values)
Handle analog input data.
Definition: dnp3.hpp:3645
virtual void handle_time_attr(const HeaderInfo &info, TimeAttr attr, uint8_t set, uint8_t variation, uint64_t value)
Handle a DNP3 time device attribute.
Definition: dnp3.hpp:3763
virtual void handle_frozen_analog_input(const HeaderInfo &info, FrozenAnalogInputIterator &values)
Handle frozen analog input data.
Definition: dnp3.hpp:3653
virtual void handle_bit_string_attr(const HeaderInfo &info, BitStringAttr attr, uint8_t set, uint8_t variation, ByteIterator &value)
Handle a bit string device attribute.
Definition: dnp3.hpp:3796
virtual void handle_unsigned_integer(const HeaderInfo &info, UnsignedIntegerIterator &values)
Handle unsigned integer values (g102)
Definition: dnp3.hpp:3685
Handler for read tasks.
Definition: dnp3.hpp:4603
virtual void on_complete(Nothing result)=0
Invoked when the asynchronous operation completes successfully.
virtual void on_failure(ReadError error)=0
Invoked when the asynchronous operation fails.
Custom request.
Definition: dnp3.hpp:4420
void add_two_byte_range_header(Variation variation, uint16_t start, uint16_t stop)
Add a two-byte start/stop header for use with a READ request.
static Request one_byte_range(Variation variation, uint8_t start, uint8_t stop)
Create a new request asking for range of objects (using 8-bit start/stop).
~Request()
Destroy a request created with Request::Request() or Request::class_request().
Request(Request &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:4436
static Request two_byte_range(Variation variation, uint16_t start, uint16_t stop)
Create a new request asking for range of objects (using 16-bit start/stop).
static Request two_byte_limited_count(Variation variation, uint16_t count)
Create a new request asking for a limited count of objects (using 16-bit start/stop).
void add_one_byte_limited_count_header(Variation variation, uint8_t count)
Add a one-byte limited count variation header for use with a READ request.
void add_time_and_interval(uint64_t time, uint32_t interval_ms)
Add a single g51v1 time-and-interval.
static Request class_request(bool class0, bool class1, bool class2, bool class3)
Create a new request asking for classes.
static Request one_byte_limited_count(Variation variation, uint8_t count)
Create a new request asking for a limited count of objects (using 8-bit start/stop).
void add_specific_attribute(uint8_t variation, uint8_t set)
Add a one-byte start/stop header for use with a READ request.
Request()
Create a new request.
void add_uint_attribute(uint8_t variation, uint8_t set, uint32_t value)
Add a one-byte start/stop header containing for use with a WRITE request.
void add_all_objects_header(Variation variation)
Add an all objects variation request.
static Request all_objects(Variation variation)
Create a new request asking for all objects of a particular variation.
void add_two_byte_limited_count_header(Variation variation, uint16_t count)
Add a two-byte limited count variation header for use with a READ request.
void add_string_attribute(uint8_t variation, uint8_t set, const std::string &value)
Add a one-byte start/stop header containing for use with a WRITE request.
void add_one_byte_range_header(Variation variation, uint8_t start, uint8_t stop)
Add a one-byte start/stop header for use with a READ request.
Exception type corresponding to the underlying error enum RestartError.
Definition: dnp3.hpp:4898
RestartException(RestartError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:4903
RestartError error
underlying error enum
Definition: dnp3.hpp:4901
Handler for restart tasks.
Definition: dnp3.hpp:4909
virtual void on_complete(std::chrono::steady_clock::duration result)=0
Invoked when the asynchronous operation completes successfully.
virtual void on_failure(RestartError error)=0
Invoked when the asynchronous operation fails.
Handle to the underlying runtime.
Definition: dnp3.hpp:359
void set_shutdown_timeout(std::chrono::steady_clock::duration timeout)
By default, when the runtime shuts down, it does so without a timeout and waits indefinitely for all ...
Runtime(const RuntimeConfig &config)
Creates a new runtime for running the protocol stack.
~Runtime()
Destroy a runtime.
Runtime(Runtime &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:375
Global TCP/TLS configuration settings.
Definition: dnp3.hpp:52
static void disable_server_tcp_no_delay()
By default, TCP_NODELAY is set to true for all server TCP/TLS connections. This disables Nagle's algo...
static void disable_client_tcp_no_delay()
By default, TCP_NODELAY is set to true for all client TCP/TLS connections. This disables Nagle's algo...
Exception type corresponding to the underlying error enum TimeSyncError.
Definition: dnp3.hpp:4841
TimeSyncError error
underlying error enum
Definition: dnp3.hpp:4844
TimeSyncException(TimeSyncError error)
construct the exception with an instance of the enum
Definition: dnp3.hpp:4846
Handler for time synchronization tasks.
Definition: dnp3.hpp:4852
virtual void on_failure(TimeSyncError error)=0
Invoked when the asynchronous operation fails.
virtual void on_complete(Nothing result)=0
Invoked when the asynchronous operation completes successfully.
Iterator over UnsignedInteger instances.
Definition: dnp3.hpp:1468
UnsignedIntegerIterator(UnsignedIntegerIterator &&)=default
move constructor for the iterator
bool next()
move the iterator to the next value
UnsignedInteger get()
retrieve the current value
Define a custom request to WRITE analog input dead-bands.
Definition: dnp3.hpp:3849
void add_g34v2_u16(uint16_t index, uint32_t dead_band)
Add a g34v2 (unsigned 32-bit) dead-band with 16-bit indexing to the request.
void add_g34v2_u8(uint8_t index, uint32_t dead_band)
Add a g34v2 (unsigned 32-bit) dead-band with 8-bit indexing to the request.
~WriteDeadBandRequest()
Destroy a request created with WriteDeadBandRequest::WriteDeadBandRequest()
void finish_header()
If a header is currently being written, then this will complete the header so that no new objects may...
WriteDeadBandRequest()
A builder class to create one or more headers of analog input dead-bands.
void add_g34v1_u16(uint16_t index, uint16_t dead_band)
Add a g34v1 (unsigned 16-bit) dead-band with 16-bit indexing to the request.
WriteDeadBandRequest(WriteDeadBandRequest &&other) noexcept
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
Definition: dnp3.hpp:3865
void add_g34v1_u8(uint8_t index, uint16_t dead_band)
Add a g34v1 (unsigned 16-bit) dead-band with 8-bit indexing to the request.
void add_g34v3_u8(uint8_t index, float dead_band)
Add a g34v3 (single-precision floating point) dead-band with 8-bit indexing to the request.
void add_g34v3_u16(uint16_t index, float dead_band)
Add a g34v3 (single-precision floating point) dead-band with 16-bit indexing to the request.
class that implements AssociationHandler in terms of a lambda expression
Definition: dnp3.hpp:4279
AssociationHandlerLambda(const T &lambda)
constructor
Definition: dnp3.hpp:4287
UtcTimestamp get_current_time() override
implement virtual method from base class
Definition: dnp3.hpp:4290
class that implements ClientStateListener in terms of a lambda expression
Definition: dnp3.hpp:2372
ClientStateListenerLambda(const T &lambda)
constructor
Definition: dnp3.hpp:2380
void on_change(ClientState state) override
implement virtual method from base class
Definition: dnp3.hpp:2383
class that implements ConnectionStateListener in terms of a lambda expression
Definition: dnp3.hpp:7844
ConnectionStateListenerLambda(const T &lambda)
constructor
Definition: dnp3.hpp:7852
void on_change(ConnectionState state) override
implement virtual method from base class
Definition: dnp3.hpp:7855
class that implements DatabaseTransaction in terms of a lambda expression
Definition: dnp3.hpp:6744
DatabaseTransactionLambda(const T &lambda)
constructor
Definition: dnp3.hpp:6752
void execute(Database &database) override
implement virtual method from base class
Definition: dnp3.hpp:6755
class that implements Logger in terms of a lambda expression
Definition: dnp3.hpp:3319
LoggerLambda(const T &lambda)
constructor
Definition: dnp3.hpp:3327
void on_message(LogLevel level, const char *message) override
implement virtual method from base class
Definition: dnp3.hpp:3330
class that implements PortStateListener in terms of a lambda expression
Definition: dnp3.hpp:2300
void on_change(PortState state) override
implement virtual method from base class
Definition: dnp3.hpp:2311
PortStateListenerLambda(const T &lambda)
constructor
Definition: dnp3.hpp:2308
constexpr uint8_t max_binary_input_index
Maximum binary input point index.
Definition: dnp3.hpp:1913
constexpr uint8_t user_assigned_id
User assigned ID code/number.
Definition: dnp3.hpp:1929
constexpr uint8_t supports_frozen_analog_inputs
Supports frozen analog input events.
Definition: dnp3.hpp:1897
constexpr uint8_t device_manufacturers_name
Device manufacturer's name.
Definition: dnp3.hpp:1939
constexpr uint8_t user_specific_attributes
Identification of user-specific attributes.
Definition: dnp3.hpp:1859
constexpr uint8_t device_location_longitude
Longitude of the device from reference meridian (-180.0 to 180.0 deg)
Definition: dnp3.hpp:1845
constexpr uint8_t num_counter
Number of counter points.
Definition: dnp3.hpp:1895
constexpr uint8_t num_master_defined_data_sets
Number of master defined data-sets.
Definition: dnp3.hpp:1865
constexpr uint8_t duration_of_time_accuracy
Duration of time accuracy (seconds)
Definition: dnp3.hpp:1873
constexpr uint8_t num_analog_input
Number of analog input points.
Definition: dnp3.hpp:1903
constexpr uint8_t device_subset_and_conformance
DNP3 subset and conformance.
Definition: dnp3.hpp:1935
constexpr uint8_t num_binary_input
Number of binary input points.
Definition: dnp3.hpp:1915
constexpr uint8_t max_analog_input_index
Maximum analog input point index.
Definition: dnp3.hpp:1901
constexpr uint8_t config_build_date
Time and date that the outstation's current configuration was built defined.
Definition: dnp3.hpp:1833
constexpr uint8_t supports_binary_input_events
Support binary input events.
Definition: dnp3.hpp:1911
constexpr uint8_t num_outstation_defined_data_sets
Number of outstation defined data-sets.
Definition: dnp3.hpp:1867
constexpr uint8_t user_assigned_primary_operator_name
User-assigned primary operator name.
Definition: dnp3.hpp:1851
constexpr uint8_t supports_counter_events
Supports counter events.
Definition: dnp3.hpp:1891
constexpr uint8_t device_manufacturer_software_version
Device manufacturer software version.
Definition: dnp3.hpp:1921
constexpr uint8_t num_binary_outputs
Number of binary outputs.
Definition: dnp3.hpp:1885
constexpr uint8_t supports_frozen_counter_events
Supports frozen counter events.
Definition: dnp3.hpp:1887
constexpr uint8_t config_version
Configuration version.
Definition: dnp3.hpp:1831
constexpr uint8_t device_serial_number
Device serial number.
Definition: dnp3.hpp:1933
constexpr uint8_t supports_double_bit_binary_input_events
Supports double-bit binary input events.
Definition: dnp3.hpp:1905
constexpr uint8_t user_assigned_owner_name
User-assigned owner name.
Definition: dnp3.hpp:1925
constexpr uint8_t num_analog_outputs
Number of analog outputs.
Definition: dnp3.hpp:1879
constexpr uint8_t max_double_bit_binary_input_index
Maximum double-bit binary input point index.
Definition: dnp3.hpp:1907
constexpr uint8_t max_analog_output_index
Maximum analog output index.
Definition: dnp3.hpp:1877
constexpr uint8_t config_id
Configuration id.
Definition: dnp3.hpp:1829
constexpr uint8_t supports_analog_output_events
Supports analog output events.
Definition: dnp3.hpp:1875
constexpr uint8_t all_attributes_request
Non-specific all attributes request.
Definition: dnp3.hpp:1941
constexpr uint8_t list_of_variations
List of attribute variations.
Definition: dnp3.hpp:1943
constexpr uint8_t user_assigned_system_name
User-assigned system name.
Definition: dnp3.hpp:1853
constexpr uint8_t config_last_change_date
Time and date that the outstation's configuration was last modified.
Definition: dnp3.hpp:1835
constexpr uint8_t num_security_stats_per_assoc
Number of security statistics per association.
Definition: dnp3.hpp:1857
constexpr uint8_t num_master_defined_data_set_proto
Number of master defined data-set prototypes.
Definition: dnp3.hpp:1861
constexpr uint8_t product_name_and_model
Device manufacturer's product name and model.
Definition: dnp3.hpp:1937
constexpr uint8_t supports_frozen_counters
Supports frozen counters.
Definition: dnp3.hpp:1889
constexpr uint8_t max_binary_output_index
Maximum binary output index.
Definition: dnp3.hpp:1883
constexpr uint8_t config_digest
Digest (aka fingerprint) of the configuration using a CRC, HASH, MAC, or public key signature.
Definition: dnp3.hpp:1837
constexpr uint8_t supports_analog_input_events
Supports analog input events.
Definition: dnp3.hpp:1899
constexpr uint8_t user_assigned_device_name
User assigned device name.
Definition: dnp3.hpp:1931
constexpr uint8_t device_manufacturer_hardware_version
Device manufacturer hardware version.
Definition: dnp3.hpp:1923
constexpr uint8_t supports_binary_output_events
Supports binary output events.
Definition: dnp3.hpp:1881
constexpr uint8_t max_counter_index
Maximum counter point index.
Definition: dnp3.hpp:1893
constexpr uint8_t max_rx_fragment_size
Maximum receive fragment size.
Definition: dnp3.hpp:1919
constexpr uint8_t local_timing_accuracy
Local timing accuracy (microseconds)
Definition: dnp3.hpp:1871
constexpr uint8_t device_location_latitude
Latitude of the device from the equator (90.0 to -90.0 deg)
Definition: dnp3.hpp:1847
constexpr uint8_t config_digest_algorithm
Configuration digest algorithm.
Definition: dnp3.hpp:1839
constexpr uint8_t max_tx_fragment_size
Maximum transmit fragment size.
Definition: dnp3.hpp:1917
constexpr uint8_t num_outstation_defined_data_set_proto
Number of outstation defined data-set prototypes.
Definition: dnp3.hpp:1863
constexpr uint8_t user_assigned_secondary_operator_name
User-assigned secondary operator name.
Definition: dnp3.hpp:1849
constexpr uint8_t master_resource_id
Master resource id (mRID)
Definition: dnp3.hpp:1841
constexpr uint8_t num_double_bit_binary_input
Number of double-bit binary input points.
Definition: dnp3.hpp:1909
constexpr uint8_t max_binary_output_per_request
Maximum number of binary outputs per request.
Definition: dnp3.hpp:1869
constexpr uint8_t device_location_altitude
Altitude of the device.
Definition: dnp3.hpp:1843
constexpr uint8_t user_assigned_location
User assigned location name.
Definition: dnp3.hpp:1927
constexpr uint8_t secure_auth_version
Secure authentication version.
Definition: dnp3.hpp:1855
constexpr uint8_t restart
Object value has not been updated since device restart.
Definition: dnp3.hpp:197
constexpr uint8_t discontinuity
Reported counter value cannot be compared against a prior value to obtain the correct count differenc...
Definition: dnp3.hpp:209
constexpr uint8_t chatter_filter
Object value is changing state rapidly (device dependent meaning)
Definition: dnp3.hpp:205
constexpr uint8_t reference_err
Object's value might not have the expected level of accuracy.
Definition: dnp3.hpp:211
constexpr uint8_t over_range
Object's true exceeds the measurement range of the reported variation.
Definition: dnp3.hpp:207
constexpr uint8_t remote_forced
Object value is overridden in a downstream reporting device.
Definition: dnp3.hpp:201
constexpr uint8_t local_forced
Object value is overridden by the device reporting this flag.
Definition: dnp3.hpp:203
constexpr uint8_t online
Object value is 'good' / 'valid' / 'nominal'.
Definition: dnp3.hpp:195
constexpr uint8_t comm_lost
Object value represents the last value available before a communication failure occurred....
Definition: dnp3.hpp:199
std::unique_ptr< ConnectionStateListener > connection_state_listener(const T &lambda)
construct an implementation of ConnectionStateListener based on a lambda expression
Definition: dnp3.hpp:7866
std::unique_ptr< Logger > logger(const T &lambda)
construct an implementation of Logger based on a lambda expression
Definition: dnp3.hpp:3341
std::unique_ptr< PortStateListener > port_state_listener(const T &lambda)
construct an implementation of PortStateListener based on a lambda expression
Definition: dnp3.hpp:2322
std::unique_ptr< ClientStateListener > client_state_listener(const T &lambda)
construct an implementation of ClientStateListener based on a lambda expression
Definition: dnp3.hpp:2394
DatabaseTransactionLambda< T > database_transaction(const T &lambda)
construct an implementation of DatabaseTransaction based on a lambda expression
Definition: dnp3.hpp:6766
std::unique_ptr< AssociationHandler > association_handler(const T &lambda)
construct an implementation of AssociationHandler based on a lambda expression
Definition: dnp3.hpp:4301
main namespace for the dnp3 library
Definition: dnp3.hpp:39
AutoTimeSync
Automatic time synchronization configuration.
Definition: dnp3.hpp:4127
@ non_lan
Perform automatic time sync with Delay Measurement (0x17) function code.
@ lan
Perform automatic time sync with Record Current Time (0x18) function code.
EventBinaryOutputStatusVariation
Event binary output status variation.
Definition: dnp3.hpp:5996
ResponseFunction
Type of response.
Definition: dnp3.hpp:3365
FileType
File type enumeration used in Group 70 objects.
Definition: dnp3.hpp:2905
@ directory
File is a directory.
@ other
Some other unspecified value.
@ simple
File is a simple file type suitable for sequential file transfer.
TimeAttr
Enumeration of all the known DNP3 Time attributes.
Definition: dnp3.hpp:2108
@ config_last_change_date
Variation 199 - Time and date that the outstation's configuration was last modified.
@ config_build_date
Variation 198 - Time and date that the outstation's current configuration was built defined.
TimeFormat
Describes if and how the time will be formatted in log messages.
Definition: dnp3.hpp:3243
@ system
Format the time in a human readable format e.g. 'Jun 25 14:27:12.955'.
@ rfc_3339
Format the time using RFC 3339.
CommandMode
Command operation mode.
Definition: dnp3.hpp:4713
@ select_before_operate
Perform a Select and Operate (0x03 then 0x04)
StringAttr
Enumeration of all the default string attributes.
Definition: dnp3.hpp:1960
@ user_assigned_system_name
Variation 208 - User-assigned system name.
@ user_assigned_location
Variation 245 - User assigned location name.
@ device_serial_number
Variation 248 - Device serial number.
@ device_manufacturer_software_version
Variation 242 - Device manufacturer software version.
@ user_assigned_device_name
Variation 247 - User assigned device name.
@ device_subset_and_conformance
Variation 249 - DNP3 subset and conformance.
@ user_assigned_secondary_operator_name
Variation 206 - User-assigned secondary operator name.
@ device_manufacturers_name
Variation 252 - Device manufacturer's name.
@ master_resource_id
Variation 202 - Master resource id (mRID)
@ device_manufacturer_hardware_version
Variation 243 - Device manufacturer hardware version.
@ config_id
Variation 196 - Configuration id.
@ config_version
Variation 197 - Configuration version.
@ config_digest_algorithm
Variation 201 - Configuration digest algorithm.
@ product_name_and_model
Variation 250 - Device manufacturer's product name and model.
@ user_assigned_owner_name
Variation 244 - User-assigned owner name.
@ user_assigned_id
Variation 246 - User assigned ID code/number.
@ user_specific_attributes
Variation 211 - Identification of user-specific attributes.
@ user_assigned_primary_operator_name
Variation 207 - User-assigned primary operator name.
DataBits
Number of bits per character.
Definition: dnp3.hpp:2714
@ eight
8 bits per character
@ five
5 bits per character
@ seven
7 bits per character
@ six
6 bits per character
ReadType
Describes the source of a read event.
Definition: dnp3.hpp:3558
@ single_poll
Single poll requested by the user.
@ startup_integrity
Startup integrity poll.
@ unsolicited
Unsolicited message.
@ periodic_poll
Periodic poll configured by the user.
EventMode
Controls how events are processed when updating values in the database.
Definition: dnp3.hpp:5783
@ detect
Detect events in a type dependent fashion.
@ suppress
Never produce an event regardless of change.
@ force
Produce an event whether the value has changed or not.
EventAnalogOutputStatusVariation
Event analog output status variation.
Definition: dnp3.hpp:6276
BoolAttr
Enumeration of all the known boolean attributes.
Definition: dnp3.hpp:2079
@ supports_analog_input_events
Variation 231 - Supports analog input events.
@ supports_frozen_counters
Variation 226 - Supports frozen counters.
@ supports_binary_input_events
Variation 237 - Support binary input events.
@ supports_analog_output_events
Variation 219 - Supports analog output events.
@ supports_double_bit_binary_input_events
Variation 234 - Supports double-bit binary input events.
@ supports_counter_events
Variation 227 - Supports counter events.
@ supports_binary_output_events
Variation 222 - Supports binary output events.
@ supports_frozen_analog_inputs
Variation 230 - Supports frozen analog input events.
@ supports_frozen_counter_events
Variation 225 - Supports frozen counter events.
LogLevel
Log level.
Definition: dnp3.hpp:3209
@ debug
Debugging log level.
@ info
Information log level.
AttrDefError
Errors that can occur when defining attributes.
Definition: dnp3.hpp:6335
@ reserved_variation
Variation is reserved and cannot be defined.
@ already_defined
Attribute has already been defined.
@ bad_type
The type does not match the required type in set 0.
@ not_writable
This attribute cannot be configured as writable.
FlowControl
Flow control modes.
Definition: dnp3.hpp:2731
@ hardware
Flow control using RTS/CTS signals.
@ software
Flow control using XON/XOFF bytes.
EventAnalogInputVariation
Event analog variation.
Definition: dnp3.hpp:6200
WriteTimeResult
Write time result used by OutstationApplication::write_absolute_time()
Definition: dnp3.hpp:7125
@ parameter_error
The request parameters are nonsensical.
StaticBinaryOutputStatusVariation
Static binary output status variation.
Definition: dnp3.hpp:5983
TransportDecodeLevel
Controls how transmitted and received transport segments are decoded at the INFO log level.
Definition: dnp3.hpp:232
@ payload
Decode the header and the raw payload as hexadecimal.
FloatAttr
Enumeration of all known float attributes.
Definition: dnp3.hpp:2147
@ device_location_longitude
Variation 204 - Longitude of the device from reference meridian (-180.0 to 180.0 deg)
@ device_location_latitude
Variation 205 - Latitude of the device from the equator (90.0 to -90.0 deg)
@ device_location_altitude
Variation 203 - Altitude of the device.
AnalogCommandType
Describes the encoding of the commanded value.
Definition: dnp3.hpp:1335
@ f32
single-precision floating point
@ f64
double-precision floating point
TimeSyncError
Possible errors that can occur during a time synchronization procedure.
Definition: dnp3.hpp:4800
@ overflow
Overflow in calculation.
@ system_time_not_unix
The system time cannot be converted to a Unix timestamp.
@ system_time_not_available
System time not available.
@ bad_outstation_time_delay
Outstation time delay exceeded the response delay.
@ clock_rollback
Detected a clock rollback.
@ still_needs_time
Outstation did not clear the NEED_TIME IIN bit.
TaskType
Task type used in AssociationInformation.
Definition: dnp3.hpp:4309
@ file_read
Read a file from the outstation.
@ command
Command request.
@ user_read
User-defined read request.
@ auto_event_scan
Automatic event scan caused by RESTART IIN bit detection.
@ time_sync
Time synchronisation task.
@ file_close
Close a file on the outstation.
@ generic_empty_response
Generic request that expects an empty response.
@ write_dead_bands
Write analog input dead-bands.
@ restart
Cold or warm restart task.
@ clear_restart_bit
Clear RESTART IIN bit.
@ file_write_block
Write a file block to the outstation.
@ file_open
Open a file on the outstation.
@ file_auth
Send username and password and get back an auth key from the outstation.
Variation
Group/Variation.
Definition: dnp3.hpp:2402
@ group41_var4
Analog Output - Double-precision floating point.
@ group42_var1
Analog Output Event - 32-bit without time.
@ group23_var2
Frozen Counter Event - 16-bit with flags.
@ group31_var7
Frozen Analog Input - Single-precision floating point with flags.
@ group13_var2
Binary Output Command Event - command status with time.
@ group40_var3
Analog Output Status - Single-precision floating point with flags.
@ group60_var4
Class objects - Class 3 data.
@ group21_var9
Frozen Counter - 32-bit without flag.
@ group33_var8
Frozen Analog Input Event - Double-precision floating point with time.
@ group31_var0
Frozen Analog Input - Default variation.
@ group31_var5
Frozen Analog Input - 32-bit without flags.
@ group21_var2
Frozen Counter - 16-bit with flags.
@ group13_var1
Binary Output Command Event - command status without time.
@ group40_var1
Analog Output Status - 32-bit with flags.
@ group30_var3
Analog Input - 32-bit without flag.
@ group34_var1
Analog Input Reporting Deadband - 16-bit.
@ group11_var1
Binary Output Event - Without time.
@ group70_var2
File control - authentication.
@ group42_var5
Analog Output Event - Single-precision floating point without time.
@ group22_var2
Counter Event - 16-bit with flags.
@ group102_var1
Unsigned Integer - 8-bit.
@ group12_var1
Binary Output Command - Control Relay Output Block.
@ group42_var3
Analog Output Event - 32-bit with time.
@ group33_var0
Frozen Analog Input Event - Default variation.
@ group34_var2
Analog Input Reporting Deadband - 32-bit.
@ group70_var7
File control - file descriptor.
@ group11_var2
Binary Output Event - With time.
@ group22_var5
Counter Event - 32-bit with flags and time.
@ group42_var8
Analog Output Event - Double-precision floating point with time.
@ group30_var6
Analog Input - Double-precision floating point with flags.
@ group50_var1
Time and Date - Absolute time.
@ group60_var2
Class objects - Class 1 data.
@ group20_var2
Counter - 16-bit with flags.
@ group70_var6
File control - file transport status.
@ group2_var0
Binary Input Event - Default variation.
@ group21_var5
Frozen Counter - 32-bit with flags and time.
@ group70_var8
File control - file specification string.
@ group0
Device Attributes - Variations 0 to 253 and 255.
@ group2_var3
Binary Input Event - With relative time.
@ group42_var6
Analog Output Event - Double-precision floating point without time.
@ group32_var0
Analog Input Event - Default variation.
@ group33_var7
Frozen Analog Input Event - Single-precision floating point with time.
@ group22_var6
Counter Event - 16-bit with flags and time.
@ group20_var1
Counter - 32-bit with flags.
@ group33_var4
Frozen Analog Input Event - 16-bit with time.
@ group43_var7
Analog Output Command Event - Single-precision floating point with time.
@ group31_var1
Frozen Analog Input - 32-bit with flags.
@ group32_var1
Analog Input Event - 32-bit without time.
@ group40_var4
Analog Output Status - Double-precision floating point with flags.
@ group1_var2
Binary Input - With flags.
@ group34_var3
Analog Input Reporting Deadband - Single-precision floating point.
@ group23_var5
Frozen Counter Event - 32-bit with flags and time.
@ group0_var254
Device Attributes - Non-Specific All Attributes Request.
@ group60_var1
Class objects - Class 0 data.
@ group42_var4
Analog Output Event - 16-bit with time.
@ group32_var4
Analog Input Event - 16-bit with time.
@ group3_var1
Double-bit Binary Input - Packed format.
@ group31_var3
Frozen Analog Input - 32-bit with flags and time-of-freeze.
@ group42_var7
Analog Output Event - Single-precision floating point with time.
@ group10_var1
Binary Output - Packed format.
@ group43_var3
Analog Output Command Event - 32-bit with time.
@ group33_var6
Frozen Analog Input Event - Double-precision floating point without time.
@ group10_var2
Binary Output - With flags.
@ group4_var1
Double-bit Binary Input Event - Without time.
@ group31_var4
Frozen Analog Input - 16-bit with flags and time-of-freeze.
@ group30_var0
Analog Input - Default variation.
@ group21_var0
Frozen Counter - Default variation.
@ group70_var5
File control - file transport.
@ group33_var5
Frozen Analog Input Event - Single-precision floating point without time.
@ group51_var2
Time and date CTO - Absolute time, unsynchronized.
@ group40_var0
Analog Output Status - Default variation.
@ group33_var2
Frozen Analog Input Event - 16-bit without time.
@ group43_var4
Analog Output Command Event - 16-bit with time.
@ group50_var4
Time and Date - Indexed absolute time and long interval.
@ group52_var1
Time delay - Coarse.
@ group51_var1
Time and date CTO - Absolute time, synchronized.
@ group52_var2
Time delay - Fine.
@ group50_var2
Time and Date - Absolute time and interval.
@ group34_var0
Analog Input Reporting Deadband - Default variation.
@ group20_var0
Counter - Default variation.
@ group32_var7
Analog Input Event - Single-precision floating point with time.
@ group3_var0
Double-bit Binary Input - Default variation.
@ group31_var2
Frozen Analog Input - 16-bit with flags.
@ group30_var1
Analog Input - 32-bit with flags.
@ group32_var8
Analog Input Event - Double-precision floating point with time.
@ group32_var6
Analog Input Event - Double-precision floating point without time.
@ group22_var1
Counter Event - 32-bit with flags.
@ group70_var3
File control - file command.
@ group42_var0
Analog Output Event - Default variation.
@ group33_var3
Frozen Analog Input Event - 32-bit with time.
@ group23_var0
Frozen Counter Event - Default variation.
@ group31_var6
Frozen Analog Input - 16-bit without flags.
@ group50_var3
Time and Date - Absolute time at last recorded time.
@ group22_var0
Counter Event - Default variation.
@ group30_var2
Analog Input - 16-bit with flags.
@ group20_var5
Counter - 32-bit without flag.
@ group31_var8
Frozen Analog Input - Double-precision floating point with flags.
@ group3_var2
Double-bit Binary Input - With flags.
@ group32_var3
Analog Input Event - 32-bit with time.
@ group41_var3
Analog Output - Single-precision floating point.
@ group10_var0
Binary Output - Default variation.
@ group43_var5
Analog Output Command Event - Single-precision floating point without time.
@ group42_var2
Analog Output Event - 16-bit without time.
@ group33_var1
Frozen Analog Input Event - 32-bit without time.
@ group40_var2
Analog Output Status - 16-bit with flags.
@ group1_var0
Binary Input - Default variation.
@ group60_var3
Class objects - Class 2 data.
@ group102_var0
Unsigned Integer - Default Variation.
@ group32_var5
Analog Input Event - Single-precision floating point without time.
@ group21_var10
Frozen Counter - 16-bit without flag.
@ group2_var1
Binary Input Event - Without time.
@ group70_var4
File control - file command status.
@ group43_var1
Analog Output Command Event - 32-bit without time.
@ group41_var2
Analog Output - 16-bit.
@ group43_var6
Analog Output Command Event - Double-precision floating point without time.
@ group30_var4
Analog Input - 16-bit without flag.
@ group41_var1
Analog Output - 32-bit.
@ group20_var6
Counter - 16-bit without flag.
@ group43_var8
Analog Output Command Event - Double-precision floating point with time.
@ group43_var2
Analog Output Command Event - 16-bit without time.
@ group32_var2
Analog Input Event - 16-bit without time.
@ group1_var1
Binary Input - Packed format.
@ group30_var5
Analog Input - Single-precision floating point with flags.
@ group21_var6
Frozen Counter - 16-bit with flags and time.
@ group80_var1
Internal Indications - Packed format.
@ group21_var1
Frozen Counter - 32-bit with flags.
@ group4_var2
Double-bit Binary Input Event - With absolute time.
@ group11_var0
Binary Output Event - Default variation.
@ group23_var1
Frozen Counter Event - 32-bit with flags.
@ group111
Octet String Event.
@ group2_var2
Binary Input Event - With absolute time.
@ group23_var6
Frozen Counter Event - 16-bit with flags and time.
@ group4_var3
Double-bit Binary Input Event - With relative time.
@ group4_var0
Double-bit Binary Input Event - Default variation.
OpType
Operation Type field, used in conjunction with TripCloseCode to specify a control operation.
Definition: dnp3.hpp:449
BitStringAttr
Enumeration of all known bit-string attributes.
Definition: dnp3.hpp:2136
EventCounterVariation
Event counter variation.
Definition: dnp3.hpp:6056
OperateType
Enumeration describing how the master requested the control operation.
Definition: dnp3.hpp:7674
@ direct_operate_no_ack
operate the control via a DirectOperateNoAck request
EventDoubleBitBinaryInputVariation
Event double-bit binary input variation.
Definition: dnp3.hpp:5938
UdpSocketMode
Describes how the UDP socket reads and writes datagrams from remote endpoint(s)
Definition: dnp3.hpp:3177
@ one_to_many
The UDP endpoint will accept packets any remote endpoint.
@ one_to_one
The UDP endpoint will only communicate with the specified remote endpoint.
StaticAnalogOutputStatusVariation
Static analog output status variation.
Definition: dnp3.hpp:6259
CommandStatus
Enumeration received from an outstation in response to command request.
Definition: dnp3.hpp:142
@ format_error
bad control code or timing values (value == 3)
@ automation_inhibit
command not accepted because it was prevented or inhibited by a local automation process,...
@ success
command was accepted, initiated, or queued (value == 0)
@ too_many_ops
the command has been done too often and has been throttled (value == 8)
@ no_select
command requires being selected before operate, configuration issue (value == 2)
@ already_active
command is all ready in progress or its all ready in that mode (value == 5)
@ out_of_range
command not accepted because the value is outside the acceptable range permitted for this point (valu...
@ non_participating
(deprecated) indicates the outstation shall not issue or perform the control operation (value == 126)
@ blocked
command not accepted because the requested function is specifically blocked at the outstation (value ...
@ already_complete
command not accepted because the outstation has already completed the requested operation (value == 1...
@ not_authorized
the command was rejected because the device denied it or an RTU intercepted it (value == 9)
@ timeout
command timed out before completing (value == 1)
@ not_supported
command is not implemented (value == 4)
@ unknown
captures any value not defined in the enumeration
@ canceled
command not accepted because the operation was cancelled (value == 16)
@ hardware_error
something is stopping the command, often a local/remote interlock (value == 6)
@ blocked_other_master
command not accepted because another master is communicating with the outstation and has exclusive ri...
@ processing_limited
command not accepted because the device cannot process any more activities than are presently in prog...
@ local
the function governed by the control is in local only control (value == 7)
@ downstream_local
command not accepted because the outstation is forwarding the request to another downstream device wh...
@ downstream_fail
command not accepted because the outstation is forwarding the request to another downstream device wh...
FileMode
Different modes in which files may be opened.
Definition: dnp3.hpp:3162
@ append
Specifies that the file is to be opened for writing, appending to the end of the file.
TimeQuality
Timestamp quality.
Definition: dnp3.hpp:595
@ invalid_time
Timestamp is not valid, ignore the value and use a local timestamp.
@ synchronized_time
The timestamp is UTC synchronized at the remote device.
@ unsynchronized_time
The device indicates the timestamp may be not be synchronized.
constexpr uint64_t dnp3_version_major
major version number
Definition: dnp3.hpp:42
StaticDoubleBitBinaryInputVariation
Static double-bit binary input variation.
Definition: dnp3.hpp:5925
UpdateResult
Defines what occurred during an update operation and which fields of UpdateInfo are valid.
Definition: dnp3.hpp:5741
@ no_event
The point exists, but the update did not create an event.
@ no_point
No point exists for this type and index.
@ created
An event was created with the specified id.
StaticAnalogInputVariation
Static analog variation.
Definition: dnp3.hpp:6179
LinkReadMode
Controls how the link-layer parser treats frames that span multiple calls to read of the physical lay...
Definition: dnp3.hpp:3194
@ datagram
Reading datagrams (UDP) where link-layer frames MAY NOT span separate calls to read.
@ stream
Reading from a stream (TCP, serial, etc.) where link-layer frames MAY span separate calls to read.
FunctionCode
Application layer function code.
Definition: dnp3.hpp:2830
@ cold_restart
Outstation shall perform a complete reset of all hardware and software in the device (value == 13)
@ operate
Outstation shall activate the output points selected (or armed) by a previous select function code co...
@ get_file_info
Outstation shall retrieve information about a file (value == 28)
@ stop_application
Outstation shall stop running the applications specified by the objects in the request (value == 18)
@ immediate_freeze
Outstation shall copy the point data values specified by the objects in the request to a separate fre...
@ initialize_data
Obsolete-Do not use for new designs (value == 15)
@ delay_measure
Outstation shall report the time it takes to process and initiate the transmission of its response (v...
@ abort_file
Outstation shall abort a file transfer operation (value == 30)
@ disable_unsolicited
Prevents outstation from initiating unsolicited responses from points specified by the objects in the...
@ immediate_freeze_no_response
Same as ImmediateFreeze but outstation shall not send a response (value == 8)
@ unsolicited_response
Master shall interpret this fragment as an unsolicited response that was not prompted by an explicit ...
@ enable_unsolicited
Enables outstation to initiate unsolicited responses from points specified by the objects in the requ...
@ close_file
Outstation shall close a file (value == 26)
@ freeze_clear_no_response
Same as FreezeClear but outstation shall not send a response (value == 10)
@ save_configuration
This code is deprecated-Do not use for new designs (value == 19)
@ record_current_time
Outstation shall save the time when the last octet of this message is received (value == 24)
@ assign_class
Outstation shall assign the events generated by the points specified by the objects in the request to...
@ select
Outstation shall select (or arm) the output points specified by the objects in the request in prepara...
@ delete_file
Outstation shall delete a file (value == 27)
@ start_application
Outstation shall start running the applications specified by the objects in the request (value == 17)
@ freeze_clear
Outstation shall copy the point data values specified by the objects in the request into a separate f...
@ freeze_at_time_no_response
Same as FreezeAtTime but outstation shall not send a response (value == 12)
@ direct_operate_no_response
Same as DirectOperate but outstation shall not send a response (value == 6)
@ confirm
Master sends this to an outstation to confirm the receipt of an Application Layer fragment (value == ...
@ response
Master shall interpret this fragment as an Application Layer response to an ApplicationLayer request ...
@ initialize_application
Outstation shall place the applications specified by the objects in the request into the ready to run...
@ direct_operate
Outstation shall immediately actuate the output points specified by the objects in the request (value...
@ authenticate_file
Outstation shall return a file authentication key (value == 29)
@ read
Outstation shall return the data specified by the objects in the request (value == 1)
@ write
Outstation shall store the data specified by the objects in the request (value == 2)
@ open_file
Outstation shall open a file (value == 25)
@ freeze_at_time
Outstation shall copy the point data values specified by the objects in the request to a separate fre...
@ warm_restart
Outstation shall reset only portions of the device (value == 14)
Nothing
A single value enum which is used as a placeholder for futures that don't return a value.
Definition: dnp3.hpp:2252
StaticBinaryInputVariation
Static binary input variation.
Definition: dnp3.hpp:5867
RestartDelayType
Type of restart delay value. Used by RestartDelay.
Definition: dnp3.hpp:7056
@ seconds
Value is in seconds (corresponds to g51v1)
@ milli_seconds
Value is in milliseconds (corresponds to g51v2)
LinkDecodeLevel
Controls how transmitted and received link frames are decoded at the INFO log level.
Definition: dnp3.hpp:247
CertificateMode
Determines how the certificate(s) presented by the peer are validated.
Definition: dnp3.hpp:1746
@ authority_based
Validates the peer certificate against one or more configured trust anchors.
@ self_signed
Validates that the peer presents a single certificate which is a byte-for-byte match against the conf...
VariationListAttr
Enumeration of all the variation list attributes.
Definition: dnp3.hpp:1947
@ list_of_variations
Variation 255 - List of attribute variations.
UintAttr
Enumeration of all the default uint attributes.
Definition: dnp3.hpp:2007
@ max_tx_fragment_size
Variation 240 - Maximum transmit fragment size.
@ num_counter
Variation 229 - Number of counter points.
@ max_double_bit_binary_input_index
Variation 235 - Maximum double-bit binary input point index.
@ num_binary_input
Variation 239 - Number of binary input points.
@ num_outstation_defined_data_set_proto
Variation 213 - Number of outstation defined data-set prototypes.
@ max_analog_output_index
Variation 220 - Maximum analog output index.
@ num_analog_outputs
Variation 221 - Number of analog outputs.
@ num_master_defined_data_sets
Variation 214 - Number of master defined data-sets.
@ duration_of_time_accuracy
Variation 218 - Duration of time accuracy (seconds)
@ local_timing_accuracy
Variation 217 - Local timing accuracy (microseconds)
@ num_analog_input
Variation 233 - Number of analog input points.
@ max_counter_index
Variation 228 - Maximum counter point index.
@ max_analog_input_index
Variation 232 - Maximum analog input point index.
@ secure_auth_version
Variation 209 - Secure authentication version.
@ num_master_defined_data_set_proto
Variation 212 - Number of master defined data-set prototypes.
@ num_double_bit_binary_input
Variation 236 - Number of double-bit binary input points.
@ max_rx_fragment_size
Variation 241 - Maximum receive fragment size.
@ num_outstation_defined_data_sets
Variation 215 - Number of outstation defined data-sets.
@ num_binary_outputs
Variation 224 - Number of binary outputs.
@ max_binary_output_index
Variation 223 - Maximum binary output index.
@ max_binary_output_per_request
Variation 216 - Maximum number of binary outputs per request.
@ num_security_stats_per_assoc
Variation 210 - Number of security statistics per association.
@ max_binary_input_index
Variation 238 - Maximum binary input point index.
CommandError
Result of a command.
Definition: dnp3.hpp:4726
@ header_mismatch
Number of headers or objects in the response didn't match the number in the request.
EventBinaryInputVariation
Event binary input variation.
Definition: dnp3.hpp:5880
const char * to_string(ParamError value)
convert an instance of enum ParamError into a C-style string
DoubleBit
Double-bit binary input value.
Definition: dnp3.hpp:664
@ determined_off
Determined to be OFF.
@ intermediate
Transition between conditions.
@ indeterminate
Abnormal or custom condition.
@ determined_on
Determined to be ON.
StaticFrozenCounterVariation
Static frozen counter variation.
Definition: dnp3.hpp:6107
StopBits
Number of stop bits.
Definition: dnp3.hpp:2761
ReadError
Errors that can occur during a read operation.
Definition: dnp3.hpp:4563
FreezeType
Freeze operation type.
Definition: dnp3.hpp:7140
@ freeze_and_clear
Copy the current value of a counter to the associated point and clear the current value to 0.
constexpr uint64_t dnp3_version_patch
patch version number
Definition: dnp3.hpp:46
AppDecodeLevel
Controls how transmitted and received application-layer fragments are decoded at the INFO log level.
Definition: dnp3.hpp:215
@ header
Decode the header-only.
@ object_values
Decode the header, the object headers, and the object values.
@ object_headers
Decode the header and the object headers.
EventFrozenCounterVariation
Event frozen counter variation.
Definition: dnp3.hpp:6128
FreezeResult
Result of a freeze operation.
Definition: dnp3.hpp:7153
@ not_supported
The demanded freeze operation is not supported by this device.
OctetStringAttr
Enumeration of all known octet-string attributes.
Definition: dnp3.hpp:2123
@ config_digest
Variation 200 - Digest (aka fingerprint) of the configuration using a CRC, HASH, MAC,...
constexpr uint64_t dnp3_version_minor
minor version number
Definition: dnp3.hpp:44
FileError
Errors that can occur during file transfer.
Definition: dnp3.hpp:3018
@ no_connection
no connection
@ bad_encoding
request data could not be encoded
@ abort_by_user
File transfer aborted by user.
@ response_timeout
timeout occurred before receiving a response
@ no_permission
Outstation indicated no permission to access file.
@ bad_status
Outstation returned an error status code.
@ too_many_requests
too many user requests queued
@ max_length_exceeded
Exceeded the maximum length specified by the user.
@ bad_response
response was malformed or contained object headers
@ bad_block_num
Received an unexpected block number.
@ wrong_handle
File handle returned by the outstation did not match the request.
@ iin_error
outstation returned an IIN.2 error bit
@ write_error
insufficient buffer space to serialize the request
@ association_removed
association was removed mid-task
QualifierCode
Qualifier code used in the response.
Definition: dnp3.hpp:3505
@ range8
8-bit start stop (0x00)
@ all_objects
All objects (0x06)
@ free_format_16
16-bit free format (0x5B)
@ range16
16-bit start stop (0x01)
@ count_and_prefix_16
16-bit count and prefix (0x28)
@ count_and_prefix_8
8-bit count and prefix (0x17)
@ count8
8-bit count (0x07)
@ count16
16-bit count (0x08)
LinkErrorMode
Controls how errors in parsed link-layer frames are handled. This behavior is configurable for physic...
Definition: dnp3.hpp:2817
@ discard
Framing errors are discarded. The link-layer parser is reset on any error, and the parser begins scan...
EmptyResponseError
Errors that may occur when performing a request that expects a response with zero object headers.
Definition: dnp3.hpp:3930
@ rejected_by_iin2
IIN2 indicates request was not completely successful.
constexpr char const * dnp3_version_string
version number as the string major.minor.patch
Definition: dnp3.hpp:48
TaskError
Task error used in AssociationInformation.
Definition: dnp3.hpp:4354
RestartError
Errors that can occur during a cold/warm restart operation.
Definition: dnp3.hpp:4869
ParamError
Error type used throughout the library.
Definition: dnp3.hpp:72
@ wrong_channel_type
This operation cannot be performed on this channel type.
@ invalid_local_certificate
Invalid local certificate file.
@ invalid_timeout
The supplied timeout value is too small or too large.
@ no_support
Native library was compiled without support for this feature.
@ server_bind_error
Server failed to bind to the specified port.
@ ok
Success, i.e. no error occurred.
@ consumed
This object is consumed and cannot be used again.
@ server_already_started
Server already started.
@ invalid_dns_name
Invalid DNS name.
@ other_tls_error
Other TLS error.
@ master_already_shutdown
Master was already shutdown.
@ association_does_not_exist
The specified association does not exist.
@ null_parameter
Null parameter.
@ invalid_peer_certificate
Invalid peer certificate file.
@ string_not_utf8
Provided string argument is not UTF-8.
@ invalid_private_key
Invalid private key file.
@ runtime_cannot_block_within_async
Runtime cannot execute blocking call within asynchronous context.
@ association_duplicate_address
Duplicate association address.
@ runtime_creation_failure
Failed to create Tokio runtime.
@ point_does_not_exist
Point does not exist.
@ invalid_socket_address
Invalid socket address.
@ invalid_dnp3_address
Invalid link-layer DNP3 address.
@ runtime_destroyed
Runtime has already been disposed.
@ address_filter_conflict
Conflict in the address filter specification.
@ logging_already_configured
Logging can only be configured once.
@ invalid_buffer_size
Invalid buffer size.
UpdateFlagsType
Point type on which to update the flags.
Definition: dnp3.hpp:5844
@ binary_input
Binary input.
@ binary_output_status
Binary output status.
@ analog_input
Analog input.
@ double_bit_binary_input
Doubl-bit binary input.
@ frozen_counter
Frozen counter.
@ analog_output_status
Analog output status.
EventClass
Event class.
Definition: dnp3.hpp:5724
TimeSyncMode
Time synchronization mode.
Definition: dnp3.hpp:4787
LinkStatusError
Errors that can occur during a manually initiated link status check. See MasterChannel::check_link_st...
Definition: dnp3.hpp:5108
@ unexpected_response
There was activity on the link, but it wasn't a LINK_STATUS.
StaticCounterVariation
Static counter variation.
Definition: dnp3.hpp:6039
BroadcastAction
Enumeration describing how the outstation processed a broadcast request.
Definition: dnp3.hpp:7584
@ bad_object_headers
Outstation was unable to parse the object headers and ignored the request.
@ ignored_by_configuration
Outstation ignored the broadcast message b/c it is disabled by configuration.
@ processed
Outstation processed the broadcast.
@ unsupported_function
Outstation ignore the broadcast message b/c the function is not supported via Broadcast.
ConnectionState
Outstation connection state for connection-oriented transports, e.g. TCP.
Definition: dnp3.hpp:7812
@ disconnected
Disconnected from the master.
TripCloseCode
Trip-Close Code field, used in conjunction with OpType to specify a control operation.
Definition: dnp3.hpp:432
MinTlsVersion
Minimum TLS version to allow.
Definition: dnp3.hpp:1731
@ v12
Allow TLS 1.2 and 1.3.
LogOutputFormat
Describes how each log event is formatted.
Definition: dnp3.hpp:3230
@ text
A simple text-based format.
@ json
Output formatted as JSON.
Parity
Parity checking modes.
Definition: dnp3.hpp:2746
@ odd
Parity bit sets odd number of 1 bits.
@ even
Parity bit sets even number of 1 bits.
PortState
State of the serial port.
Definition: dnp3.hpp:2263
@ disabled
Disabled until enabled.
@ wait
Waiting to perform an open retry.
@ shutdown
Task has been shut down.
ClientState
State of the client connection.
Definition: dnp3.hpp:2332
@ connected
Client is connected to the remote device.
@ wait_after_failed_connect
Failed to establish a connection, waiting before retrying.
@ connecting
Client is trying to establish a connection to the remote device.
@ wait_after_disconnect
Client was disconnected, waiting before retrying.
IntAttr
Enumeration of all the default integer attributes.
Definition: dnp3.hpp:2066
PhysDecodeLevel
Controls how data transmitted at the physical layer (TCP, serial, etc) is logged.
Definition: dnp3.hpp:262
@ length
Log only the length of data that is sent and received.
@ data
Log the length and the actual data that is sent and received.
Event transferred from master to outstation when the outstation receives a corresponding command.
Definition: dnp3.hpp:1358
double commanded_value
Commanded state of the binary output.
Definition: dnp3.hpp:1380
AnalogCommandType command_type
Describes how the value was encoded in the protocol.
Definition: dnp3.hpp:1382
AnalogOutputCommandEvent(uint16_t index, CommandStatus status, double commanded_value, AnalogCommandType command_type, const Timestamp &time)
Fully construct AnalogOutputCommandEvent specifying the value of each field.
CommandStatus status
Status from processing the command that triggered this event.
Definition: dnp3.hpp:1376
uint16_t index
Index of the command event.
Definition: dnp3.hpp:1374
Timestamp time
Associated timestamp.
Definition: dnp3.hpp:1384
Analog Output Status configuration.
Definition: dnp3.hpp:6303
AnalogOutputStatusConfig(StaticAnalogOutputStatusVariation static_variation, EventAnalogOutputStatusVariation event_variation, double deadband)
Fully construct AnalogOutputStatusConfig specifying the value of each field.
double deadband
Deadband value.
Definition: dnp3.hpp:6331
StaticAnalogOutputStatusVariation static_variation
Default static variation.
Definition: dnp3.hpp:6327
EventAnalogOutputStatusVariation event_variation
Default event variation.
Definition: dnp3.hpp:6329
AnalogOutputStatusConfig()
Initialize to defaults.
analog_output_status point
Definition: dnp3.hpp:1187
Timestamp time
Point timestamp.
Definition: dnp3.hpp:1208
AnalogOutputStatus(uint16_t index, double value, const Flags &flags, const Timestamp &time)
Fully construct AnalogOutputStatus specifying the value of each field.
uint16_t index
Point index.
Definition: dnp3.hpp:1202
Flags flags
Point flags.
Definition: dnp3.hpp:1206
double value
Point value.
Definition: dnp3.hpp:1204
Application-controlled IIN bits.
Definition: dnp3.hpp:7170
bool config_corrupt
IIN2.5 - Configuration corrupt.
Definition: dnp3.hpp:7203
bool need_time
IIN1.4 - Time synchronization is required.
Definition: dnp3.hpp:7197
bool local_control
IIN1.5 - Some output points are in local mode.
Definition: dnp3.hpp:7199
bool device_trouble
IIN1.6 - Device trouble.
Definition: dnp3.hpp:7201
ApplicationIin()
Initialize all fields in ApplicationIin to false.
Association configuration.
Definition: dnp3.hpp:4144
Classes startup_integrity_classes
Startup integrity classes to ask on master startup and when an outstation restart is detected.
Definition: dnp3.hpp:4192
std::chrono::steady_clock::duration keep_alive_timeout
Delay of inactivity before sending a REQUEST_LINK_STATUS to the outstation.
Definition: dnp3.hpp:4200
AssociationConfig(const EventClasses &disable_unsol_classes, const EventClasses &enable_unsol_classes, const Classes &startup_integrity_classes, const EventClasses &event_scan_on_events_available)
Initialize the configuration with the specified values.
AutoTimeSync auto_time_sync
Automatic time synchronization configuration.
Definition: dnp3.hpp:4194
EventClasses enable_unsol_classes
Classes to enable unsolicited responses at startup.
Definition: dnp3.hpp:4188
EventClasses event_scan_on_events_available
Classes to automatically send reads when the IIN bit is asserted.
Definition: dnp3.hpp:4204
uint16_t max_queued_user_requests
maximum number of user requests (e.g. commands, adhoc reads, etc) that will be queued before back-pre...
Definition: dnp3.hpp:4206
EventClasses disable_unsol_classes
Classes to disable unsolicited responses at startup.
Definition: dnp3.hpp:4186
bool auto_integrity_scan_on_buffer_overflow
Automatic integrity scan when an EVENT_BUFFER_OVERFLOW is detected.
Definition: dnp3.hpp:4202
RetryStrategy auto_tasks_retry_strategy
Automatic tasks retry strategy.
Definition: dnp3.hpp:4196
std::chrono::steady_clock::duration response_timeout
Timeout for receiving a response on this association.
Definition: dnp3.hpp:4184
Association identifier.
Definition: dnp3.hpp:3991
An attribute variation and properties pair returned in Group0Var255.
Definition: dnp3.hpp:2187
uint8_t variation
Variation of the attribute.
Definition: dnp3.hpp:2201
AttrProp properties
Properties of the attribute.
Definition: dnp3.hpp:2203
Attribute properties returned in Group0Var255.
Definition: dnp3.hpp:2168
bool is_writable
Indicate if the property can be used in a WRITE operation.
Definition: dnp3.hpp:2181
Event transferred from master to outstation when the outstation receives a corresponding command.
Definition: dnp3.hpp:1263
BinaryOutputCommandEvent(uint16_t index, CommandStatus status, bool commanded_state, const Timestamp &time)
Fully construct BinaryOutputCommandEvent specifying the value of each field.
bool commanded_state
Commanded state of the binary output.
Definition: dnp3.hpp:1284
uint16_t index
Index of the binary command event.
Definition: dnp3.hpp:1278
Timestamp time
Associated timestamp.
Definition: dnp3.hpp:1286
CommandStatus status
Status from processing the command that triggered this event.
Definition: dnp3.hpp:1280
Binary Output Status configuration.
Definition: dnp3.hpp:6011
EventBinaryOutputStatusVariation event_variation
Default event variation.
Definition: dnp3.hpp:6035
StaticBinaryOutputStatusVariation static_variation
Default static variation.
Definition: dnp3.hpp:6033
BinaryOutputStatusConfig()
Initialize to defaults.
BinaryOutputStatusConfig(StaticBinaryOutputStatusVariation static_variation, EventBinaryOutputStatusVariation event_variation)
Fully construct BinaryOutputStatusConfig specifying the value of each field.
binary_output_status point
Definition: dnp3.hpp:827
uint16_t index
Point index.
Definition: dnp3.hpp:842
BinaryOutputStatus(uint16_t index, bool value, const Flags &flags, const Timestamp &time)
Fully construct BinaryOutputStatus specifying the value of each field.
bool value
Point value.
Definition: dnp3.hpp:844
Flags flags
Point flags.
Definition: dnp3.hpp:846
Timestamp time
Point timestamp.
Definition: dnp3.hpp:848
Information about the state of buffer after a CONFIRM has been processed.
Definition: dnp3.hpp:7274
ClassCount classes
Remaining number of events in the buffer on a per-class basis.
Definition: dnp3.hpp:7288
TypeCount types
Remaining number of events in the buffer on a per-type basis.
Definition: dnp3.hpp:7290
Remaining number of events in the buffer after a confirm on a per-class basis.
Definition: dnp3.hpp:7209
uint32_t num_class_1
Number of class 1 events remaining in the buffer.
Definition: dnp3.hpp:7224
uint32_t num_class_2
Number of class 2 events remaining in the buffer.
Definition: dnp3.hpp:7226
uint32_t num_class_3
Number of class 3 events remaining in the buffer.
Definition: dnp3.hpp:7228
Controls which types are reported during a Class 0 read.
Definition: dnp3.hpp:6862
ClassZeroConfig()
Initialize to default values.
bool analog_output_status
Include Analog Output Status in Class 0 reads.
Definition: dnp3.hpp:6909
bool binary
Include Binary Inputs in Class 0 reads.
Definition: dnp3.hpp:6897
bool frozen_counter
Include Frozen Counters in Class 0 reads.
Definition: dnp3.hpp:6905
bool analog
Include Analog Inputs in Class 0 reads.
Definition: dnp3.hpp:6907
bool octet_string
Include Octet Strings in Class 0 reads.
Definition: dnp3.hpp:6913
bool binary_output_status
Include Binary Output Status in Class 0 reads.
Definition: dnp3.hpp:6901
bool double_bit_binary
Include Double-Bit Binary Inputs in Class 0 reads.
Definition: dnp3.hpp:6899
bool counter
Include Counters in Class 0 reads.
Definition: dnp3.hpp:6903
Class 0, 1, 2 and 3 config.
Definition: dnp3.hpp:4078
bool class3
Class 3 events.
Definition: dnp3.hpp:4123
bool class0
Class 0 (static data)
Definition: dnp3.hpp:4117
static Classes all()
Initialize all classes to true.
static Classes none()
Initialize all classes to false.
Classes(bool class0, bool class1, bool class2, bool class3)
Fully construct Classes specifying the value of each field.
bool class1
Class 1 events.
Definition: dnp3.hpp:4119
bool class2
Class 2 events.
Definition: dnp3.hpp:4121
Timing parameters for connection attempts.
Definition: dnp3.hpp:1698
std::chrono::steady_clock::duration reconnect_delay
Delay before attempting a connection after a disconnect.
Definition: dnp3.hpp:1727
std::chrono::steady_clock::duration min_connect_delay
Minimum delay between two connection attempts, doubles up to the maximum delay.
Definition: dnp3.hpp:1723
std::chrono::steady_clock::duration max_connect_delay
Maximum delay between two connection attempts.
Definition: dnp3.hpp:1725
ConnectStrategy()
Initialize to default values.
CROB (Group12Var1) control code.
Definition: dnp3.hpp:470
bool clear
Support for this field is optional. When the clear bit is set, the device shall remove pending contro...
Definition: dnp3.hpp:528
OpType op_type
This field is used in conjunction with the ControlCode::tcc field to specify a control operation.
Definition: dnp3.hpp:532
ControlCode(TripCloseCode tcc, bool clear, OpType op_type)
Initialize a ControlCode instance.
bool queue
This field is obsolete and should always be 0.
Definition: dnp3.hpp:530
static ControlCode from_op_type(OpType op_type)
Initialize a ControlCode instance from a OpType
TripCloseCode tcc
This field is used in conjunction with ControlCode::op_type to specify a control operation.
Definition: dnp3.hpp:526
static ControlCode from_tcc_and_op_type(TripCloseCode tcc, OpType op_type)
Initialize a ControlCode instance from a TripCloseCode and a OpType.
APDU Control field.
Definition: dnp3.hpp:403
bool fir
First fragment in the message.
Definition: dnp3.hpp:420
bool uns
Unsolicited response.
Definition: dnp3.hpp:426
bool fin
Final fragment of the message.
Definition: dnp3.hpp:422
bool con
Requires confirmation.
Definition: dnp3.hpp:424
uint8_t seq
Sequence number.
Definition: dnp3.hpp:428
Counter configuration.
Definition: dnp3.hpp:6075
StaticCounterVariation static_variation
Default static variation.
Definition: dnp3.hpp:6099
uint32_t deadband
Deadband value.
Definition: dnp3.hpp:6103
CounterConfig(StaticCounterVariation static_variation, EventCounterVariation event_variation, uint32_t deadband)
Fully construct CounterConfig specifying the value of each field.
CounterConfig()
Initialize to defaults.
EventCounterVariation event_variation
Default event variation.
Definition: dnp3.hpp:6101
counter point
Definition: dnp3.hpp:899
uint16_t index
Point index.
Definition: dnp3.hpp:914
Timestamp time
Point timestamp.
Definition: dnp3.hpp:920
Flags flags
Point flags.
Definition: dnp3.hpp:918
uint32_t value
Point value.
Definition: dnp3.hpp:916
Counter(uint16_t index, uint32_t value, const Flags &flags, const Timestamp &time)
Fully construct Counter specifying the value of each field.
Controls the decoding of transmitted and received data at the application, transport,...
Definition: dnp3.hpp:279
TransportDecodeLevel transport
Controls transport segment layer decoding.
Definition: dnp3.hpp:320
DecodeLevel()
Initialize log levels to defaults.
AppDecodeLevel application
Controls application fragment decoding.
Definition: dnp3.hpp:318
LinkDecodeLevel link
Controls link frame decoding.
Definition: dnp3.hpp:322
static DecodeLevel nothing()
Initialize log levels to nothing.
PhysDecodeLevel physical
Controls the logging of physical layer read/write.
Definition: dnp3.hpp:324
Configuration related to reading a file.
Definition: dnp3.hpp:5014
uint16_t max_block_size
Maximum block size requested by the master during the file open.
Definition: dnp3.hpp:5038
uint32_t max_file_size
Maximum number of bytes that may be accumulated while reading directory information.
Definition: dnp3.hpp:5040
static DirReadConfig defaults()
Initialize the configuration to default values.
Maximum number of events for each type.
Definition: dnp3.hpp:6807
uint16_t max_counter
Maximum number of Counter events (g22)
Definition: dnp3.hpp:6848
uint16_t max_frozen_counter
Maximum number of Frozen Counter events (g23)
Definition: dnp3.hpp:6850
uint16_t max_binary
Maximum number of Binary Input events (g2)
Definition: dnp3.hpp:6842
uint16_t max_analog_output_status
Maximum number of Analog Output Status events (g42)
Definition: dnp3.hpp:6854
EventBufferConfig(uint16_t max_binary, uint16_t max_double_bit_binary, uint16_t max_binary_output_status, uint16_t max_counter, uint16_t max_frozen_counter, uint16_t max_analog, uint16_t max_analog_output_status, uint16_t max_octet_string)
Fully construct EventBufferConfig specifying the value of each field.
uint16_t max_octet_string
Maximum number of Octet String events (g111)
Definition: dnp3.hpp:6856
uint16_t max_analog
Maximum number of Analog Input events (g32)
Definition: dnp3.hpp:6852
static EventBufferConfig no_events()
Create a configuration where no events are buffered.
uint16_t max_binary_output_status
Maximum number of Binary Output Status events (g11)
Definition: dnp3.hpp:6846
uint16_t max_double_bit_binary
Maximum number of Double-Bit Binary Input events (g4)
Definition: dnp3.hpp:6844
Event classes.
Definition: dnp3.hpp:4032
bool class2
Class 2 events.
Definition: dnp3.hpp:4070
static EventClasses none()
Initialize all classes to false.
bool class1
Class 1 events.
Definition: dnp3.hpp:4068
EventClasses(bool class1, bool class2, bool class3)
Fully construct EventClasses specifying the value of each field.
static EventClasses all()
Initialize all classes to true.
bool class3
Class 3 events.
Definition: dnp3.hpp:4072
Information about a file or directory returned from the outstation.
Definition: dnp3.hpp:3072
uint64_t time_created
DNP3 timestamp.
Definition: dnp3.hpp:3099
Permissions permissions
Outstation permissions for the file.
Definition: dnp3.hpp:3101
uint32_t size
Size of the file in bytes.
Definition: dnp3.hpp:3095
FileType file_type
Simple file or directory.
Definition: dnp3.hpp:3091
std::string file_name
Name of the file or directory.
Definition: dnp3.hpp:3089
Configuration related to reading a file.
Definition: dnp3.hpp:4982
static FileReadConfig defaults()
Initialize the configuration to default values.
uint16_t max_block_size
Maximum block size requested by the master during the file open.
Definition: dnp3.hpp:5006
uint32_t max_file_size
Maximum file size accepted by the master.
Definition: dnp3.hpp:5008
Collection of individual flag bits represented by an underlying mask value.
Definition: dnp3.hpp:579
Flags(uint8_t value)
Fully construct Flags specifying the value of each field.
uint8_t value
bit-mask representing a set of individual flag bits
Definition: dnp3.hpp:591
Frozen Counter configuration.
Definition: dnp3.hpp:6147
FrozenCounterConfig()
Initialize to defaults.
uint32_t deadband
Deadband value.
Definition: dnp3.hpp:6175
StaticFrozenCounterVariation static_variation
Default static variation.
Definition: dnp3.hpp:6171
FrozenCounterConfig(StaticFrozenCounterVariation static_variation, EventFrozenCounterVariation event_variation, uint32_t deadband)
Fully construct FrozenCounterConfig specifying the value of each field.
EventFrozenCounterVariation event_variation
Default event variation.
Definition: dnp3.hpp:6173
frozen_counter point
Definition: dnp3.hpp:971
Flags flags
Point flags.
Definition: dnp3.hpp:990
Timestamp time
Point timestamp.
Definition: dnp3.hpp:992
uint16_t index
Point index.
Definition: dnp3.hpp:986
FrozenCounter(uint16_t index, uint32_t value, const Flags &flags, const Timestamp &time)
Fully construct FrozenCounter specifying the value of each field.
uint32_t value
Point value.
Definition: dnp3.hpp:988
Control Relay Output Block.
Definition: dnp3.hpp:538
static Group12Var1 from_code(const ControlCode &code)
Construct a Group12Var1 from a ControlCode.
uint32_t off_time
Duration the output drive remains non-active (in milliseconds)
Definition: dnp3.hpp:573
uint32_t on_time
Duration the output drive remains active (in milliseconds)
Definition: dnp3.hpp:571
uint8_t count
Count.
Definition: dnp3.hpp:569
ControlCode code
Control code.
Definition: dnp3.hpp:567
Group12Var1(const ControlCode &code, uint8_t count, uint32_t on_time, uint32_t off_time)
Fully construct Group12Var1 specifying the value of each field.
First IIN byte.
Definition: dnp3.hpp:3380
bool need_time
Outstation requires time synchronization.
Definition: dnp3.hpp:3408
bool class_2_events
Outstation has unreported Class 2 events.
Definition: dnp3.hpp:3404
bool device_trouble
An abnormal, device-specific condition exists in the outstation.
Definition: dnp3.hpp:3412
bool local_control
One or more of the outstation’s points are in local control mode.
Definition: dnp3.hpp:3410
bool class_1_events
Outstation has unreported Class 1 events.
Definition: dnp3.hpp:3402
bool class_3_events
Outstation has unreported Class 3 events.
Definition: dnp3.hpp:3406
bool broadcast
Broadcast message was received.
Definition: dnp3.hpp:3400
bool device_restart
Outstation restarted.
Definition: dnp3.hpp:3414
Second IIN byte.
Definition: dnp3.hpp:3420
bool object_unknown
Outstation does not support requested operation for objects in the request.
Definition: dnp3.hpp:3442
bool config_corrupt
The outstation detected corrupt configuration (optional support)
Definition: dnp3.hpp:3450
bool reserved_2
Reserved for future use - should always be set to 0.
Definition: dnp3.hpp:3452
bool event_buffer_overflow
An event buffer overflow condition exists in the outstation, and at least one unconfirmed event was l...
Definition: dnp3.hpp:3446
bool no_func_code_support
Outstation does not support this function code.
Definition: dnp3.hpp:3440
bool reserved_1
Reserved for future use - should always be set to 0.
Definition: dnp3.hpp:3454
bool already_executing
The operation requested is already executing (optional support)
Definition: dnp3.hpp:3448
bool parameter_error
Outstation does not support requested operation for objects in the request.
Definition: dnp3.hpp:3444
Pair of IIN bytes.
Definition: dnp3.hpp:3460
Iin2 iin2
Second IIN byte.
Definition: dnp3.hpp:3476
Iin1 iin1
First IIN byte.
Definition: dnp3.hpp:3474
Configuration that controls how the server performs remote link identification.
Definition: dnp3.hpp:5654
std::chrono::steady_clock::duration timeout
Maximum time period to wait before receiving a link frame from the outstation.
Definition: dnp3.hpp:5681
PhysDecodeLevel decode_level
Set the decode level to use when reading the link header used for identification.
Definition: dnp3.hpp:5683
LinkIdConfig()
Initialize to default values.
uint16_t max_tasks
Set the maximum number of simultaneous tasks used to perform link identification.
Definition: dnp3.hpp:5679
Logging configuration options.
Definition: dnp3.hpp:3258
LogOutputFormat output_format
output formatting options
Definition: dnp3.hpp:3289
bool print_level
optionally print the log level as part to the message string
Definition: dnp3.hpp:3293
LoggingConfig()
Initialize the configuration to default values.
TimeFormat time_format
optional time format
Definition: dnp3.hpp:3291
bool print_module_info
optionally print the underlying Rust module information to the message string
Definition: dnp3.hpp:3295
LogLevel level
logging level
Definition: dnp3.hpp:3287
Configuration for a MasterChannel that is independent of the physical layer.
Definition: dnp3.hpp:3803
DecodeLevel decode_level
Decoding level for this master. You can modify this later on with MasterChannel::set_decode_level().
Definition: dnp3.hpp:3833
uint16_t address
Local DNP3 data-link address.
Definition: dnp3.hpp:3831
MasterChannelConfig(uint16_t address)
Initialize MasterChannelConfig to default values.
uint16_t tx_buffer_size
TX buffer size.
Definition: dnp3.hpp:3837
uint16_t rx_buffer_size
RX buffer size.
Definition: dnp3.hpp:3841
Octet String point.
Definition: dnp3.hpp:1548
uint16_t index
Point index.
Definition: dnp3.hpp:1562
ByteIterator value
Point value.
Definition: dnp3.hpp:1564
The result of opening a file on the outstation.
Definition: dnp3.hpp:2991
uint16_t max_block_size
Maximum block size returned by the outstation.
Definition: dnp3.hpp:3014
uint32_t file_handle
The handle assigned to the file by the outstation.
Definition: dnp3.hpp:3008
uint32_t file_size
Size of the file returned by the outstation.
Definition: dnp3.hpp:3010
Outstation configuration.
Definition: dnp3.hpp:6960
uint32_t max_unsolicited_retries
Maximum number of unsolicited retries.
Definition: dnp3.hpp:7038
uint16_t max_controls_per_request
Maximum number of controls in a single request.
Definition: dnp3.hpp:7050
DecodeLevel decode_level
Decoding level.
Definition: dnp3.hpp:7030
uint16_t unsolicited_buffer_size
Unsolicited response buffer size.
Definition: dnp3.hpp:7024
OutstationFeatures features
Optional features.
Definition: dnp3.hpp:7036
OutstationConfig(uint16_t outstation_address, uint16_t master_address, const EventBufferConfig &event_buffer_config)
Initialize to defaults.
std::chrono::steady_clock::duration select_timeout
Select timeout.
Definition: dnp3.hpp:7034
std::chrono::steady_clock::duration unsolicited_retry_delay
Delay to wait before retrying an unsolicited response.
Definition: dnp3.hpp:7040
std::chrono::steady_clock::duration keep_alive_timeout
Delay of inactivity before sending a REQUEST_LINK_STATUS to the master.
Definition: dnp3.hpp:7044
std::chrono::steady_clock::duration confirm_timeout
Confirmation timeout.
Definition: dnp3.hpp:7032
ClassZeroConfig class_zero
Controls responses to Class 0 reads.
Definition: dnp3.hpp:7052
uint16_t max_read_request_headers
Maximum number of headers that will be processed in a READ request.
Definition: dnp3.hpp:7048
uint16_t master_address
Link-layer master address.
Definition: dnp3.hpp:7014
EventBufferConfig event_buffer_config
Event buffer sizes configuration.
Definition: dnp3.hpp:7016
uint16_t outstation_address
Link-layer outstation address.
Definition: dnp3.hpp:7012
uint16_t solicited_buffer_size
Solicited response buffer size.
Definition: dnp3.hpp:7020
uint16_t rx_buffer_size
Receive buffer size.
Definition: dnp3.hpp:7028
Optional outstation features that can be enabled or disabled.
Definition: dnp3.hpp:6919
bool broadcast
Process valid broadcast messages.
Definition: dnp3.hpp:6948
OutstationFeatures()
Initialize to default values.
bool self_address
Respond to the self address.
Definition: dnp3.hpp:6946
bool unsolicited
Respond to enable/disable unsolicited response and produce unsolicited responses.
Definition: dnp3.hpp:6950
bool respond_to_any_master
Outstation will process every request as if it came from the configured master address.
Definition: dnp3.hpp:6954
UDP outstation configuration.
Definition: dnp3.hpp:7878
std::string remote_endpoint
Remote endpoint where outbound requests are sent. Must be a socket address (ip:port)
Definition: dnp3.hpp:7910
std::chrono::steady_clock::duration retry_delay
Period to wait before retrying after a failure to bind or connect the UDP socket.
Definition: dnp3.hpp:7916
OutstationUdpConfig(const std::string &local_endpoint, const std::string &remote_endpoint)
Initialize the configuration with default settings for unspecified parameter.
UdpSocketMode socket_mode
UDP socket mode to use.
Definition: dnp3.hpp:7912
std::string local_endpoint
Local endpoint to which the UDP socket is bound. Must be a socket address (ip:port)
Definition: dnp3.hpp:7908
LinkReadMode link_read_mode
Read mode to use, this should typically be set to LinkReadMode::datagram
Definition: dnp3.hpp:7914
Defines read, write, execute permissions for particular group or user.
Definition: dnp3.hpp:2922
bool execute
Permission to execute.
Definition: dnp3.hpp:2946
bool read
Permission to read.
Definition: dnp3.hpp:2950
PermissionSet(bool execute, bool write, bool read)
Fully construct PermissionSet specifying the value of each field.
PermissionSet()
Permission set with nothing enabled.
bool write
Permission to write.
Definition: dnp3.hpp:2948
Permissions for world, group, and owner.
Definition: dnp3.hpp:2956
PermissionSet owner
Owner permissions.
Definition: dnp3.hpp:2985
PermissionSet group
Group permissions.
Definition: dnp3.hpp:2983
Permissions(const PermissionSet &world, const PermissionSet &group, const PermissionSet &owner)
Fully construct Permissions specifying the value of each field.
static Permissions none()
Permissions with nothing enabled.
PermissionSet world
World permissions.
Definition: dnp3.hpp:2981
Poll identifier.
Definition: dnp3.hpp:4010
Restart delay used by OutstationApplication::cold_restart() and OutstationApplication::warm_restart()
Definition: dnp3.hpp:7075
static RestartDelay not_supported()
RestartDelay indicating that the request is not supported.
static RestartDelay milliseconds(uint16_t value)
RestartDelay with a count of milliseconds.
uint16_t value
Expected delay before the outstation comes back online.
Definition: dnp3.hpp:7121
static RestartDelay seconds(uint16_t value)
RestartDelay with a count of seconds.
RestartDelayType restart_type
Indicates what RestartDelay::value is.
Definition: dnp3.hpp:7119
Retry strategy configuration.
Definition: dnp3.hpp:2685
RetryStrategy()
Initialize to defaults.
std::chrono::steady_clock::duration max_delay
Maximum delay between two retries.
Definition: dnp3.hpp:2710
std::chrono::steady_clock::duration min_delay
Minimum delay between two retries.
Definition: dnp3.hpp:2708
Runtime configuration.
Definition: dnp3.hpp:332
uint16_t num_core_threads
Number of runtime threads to spawn. For a guess of the number of CPU cores, use 0.
Definition: dnp3.hpp:355
RuntimeConfig()
Initialize the configuration to default values.
Serial port settings.
Definition: dnp3.hpp:2776
StopBits stop_bits
Number of bits to use to signal the end of a character.
Definition: dnp3.hpp:2813
FlowControl flow_control
Type of signalling to use for controlling data transfer.
Definition: dnp3.hpp:2809
Parity parity
Type of parity to use for error checking.
Definition: dnp3.hpp:2811
SerialSettings()
Initialize to default values.
uint32_t baud_rate
Baud rate (in symbols-per-second)
Definition: dnp3.hpp:2805
DataBits data_bits
Number of bits used to represent a character sent on the line.
Definition: dnp3.hpp:2807
Timestamp associated with particular measurement from the outstation. The validity of the value depen...
Definition: dnp3.hpp:612
static Timestamp synchronized_timestamp(uint64_t value)
Creates a synchronized timestamp struct.
static Timestamp invalid_timestamp()
Creates an invalid timestamp struct.
TimeQuality quality
Enumeration that indicates the timestamp's validity.
Definition: dnp3.hpp:660
static Timestamp unsynchronized_timestamp(uint64_t value)
Creates an unsynchronized timestamp struct.
uint64_t value
Count of milliseconds since UNIX epoch.
Definition: dnp3.hpp:658
TLS client configuration.
Definition: dnp3.hpp:1767
MinTlsVersion min_tls_version
Minimum TLS version allowed.
Definition: dnp3.hpp:1819
CertificateMode certificate_mode
Certificate validation mode.
Definition: dnp3.hpp:1821
bool allow_server_name_wildcard
If set to true, a '*' may be used for TlsClientConfig::dns_name to bypass server name validation.
Definition: dnp3.hpp:1823
TlsClientConfig(const std::string &dns_name, const std::string &peer_cert_path, const std::string &local_cert_path, const std::string &private_key_path, const std::string &password)
construct the configuration with defaults
std::string peer_cert_path
Path to the PEM-encoded certificate of the peer.
Definition: dnp3.hpp:1807
std::string local_cert_path
Path to the PEM-encoded local certificate.
Definition: dnp3.hpp:1809
std::string private_key_path
Path to the the PEM-encoded private key.
Definition: dnp3.hpp:1811
std::string password
Optional password if the private key file is encrypted.
Definition: dnp3.hpp:1817
std::string dns_name
Subject name which is verified in the presented server certificate, from the SAN extension or in the ...
Definition: dnp3.hpp:1805
TLS server configuration.
Definition: dnp3.hpp:8109
std::string dns_name
Subject name which is verified in the presented client certificate, from the SAN extension or in the ...
Definition: dnp3.hpp:8147
CertificateMode certificate_mode
Certificate validation mode.
Definition: dnp3.hpp:8163
std::string local_cert_path
Path to the PEM-encoded local certificate.
Definition: dnp3.hpp:8151
MinTlsVersion min_tls_version
Minimum TLS version allowed.
Definition: dnp3.hpp:8161
std::string password
Optional password if the private key file is encrypted.
Definition: dnp3.hpp:8159
std::string peer_cert_path
Path to the PEM-encoded certificate of the peer.
Definition: dnp3.hpp:8149
bool allow_client_name_wildcard
If set to true, a '*' may be used for TlsServerConfig::dns_name to allow any authenticated client to ...
Definition: dnp3.hpp:8165
std::string private_key_path
Path to the PEM-encoded private key.
Definition: dnp3.hpp:8153
TlsServerConfig(const std::string &dns_name, const std::string &peer_cert_path, const std::string &local_cert_path, const std::string &private_key_path, const std::string &password)
construct the configuration with defaults
Remaining number of events in the buffer after a confirm on a per-type basis.
Definition: dnp3.hpp:7234
uint32_t num_counter
Number of counter events remaining in the buffer.
Definition: dnp3.hpp:7260
uint32_t num_frozen_counter
Number of frozen counter events remaining in the buffer.
Definition: dnp3.hpp:7262
uint32_t num_double_bit_binary_input
Number of double-bit binary input events remaining in the buffer.
Definition: dnp3.hpp:7256
uint32_t num_binary_output_status
Number of binary output status events remaining in the buffer.
Definition: dnp3.hpp:7258
uint32_t num_binary_input
Number of binary input events remaining in the buffer.
Definition: dnp3.hpp:7254
uint32_t num_analog_output_status
Number of analog output status events remaining in the buffer.
Definition: dnp3.hpp:7266
uint32_t num_analog
Number of analog events remaining in the buffer.
Definition: dnp3.hpp:7264
uint32_t num_octet_string
Number octet string events remaining in the buffer.
Definition: dnp3.hpp:7268
Unsigned byte corresponding to group 102 variation 1.
Definition: dnp3.hpp:1437
UnsignedInteger(uint16_t index, uint8_t value)
Fully construct UnsignedInteger specifying the value of each field.
uint8_t value
Value of the object.
Definition: dnp3.hpp:1452
uint16_t index
Index of the object.
Definition: dnp3.hpp:1450
Defines what occurred during an update operation. Only certain id fields are valid depending on the v...
Definition: dnp3.hpp:5760
UpdateResult result
Defines what happened and which id fields are valid.
Definition: dnp3.hpp:5775
uint64_t discarded
The id of the discarded event if the result is UpdateResult::overflow
Definition: dnp3.hpp:5779
uint64_t created
The id of the created event if the result is UpdateResult::created or UpdateResult::overflow
Definition: dnp3.hpp:5777
Options that control how the update is performed.
Definition: dnp3.hpp:5804
static UpdateOptions detect_event()
Default event detection mode. Updates the static value and automatically detects event.
EventMode event_mode
Determines how/if an event is produced.
Definition: dnp3.hpp:5840
bool update_static
Optionally bypass updating the static database (the current value)
Definition: dnp3.hpp:5838
static UpdateOptions no_event()
Only update the static value. Usefull during initialization of the database.
Timestamp value returned by AssociationHandler::get_current_time().
Definition: dnp3.hpp:4214
static UtcTimestamp invalid()
Construct an invalid UtcTimestamp.
uint64_t value
Count of milliseconds since UNIX epoch.
Definition: dnp3.hpp:4250
static UtcTimestamp valid(uint64_t value)
Construct a valid UtcTimestamp.
bool is_valid
True if the timestamp is valid, false otherwise.
Definition: dnp3.hpp:4252