Classes | Typedefs | Enumerations | Functions | Variables
psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io Namespace Reference

Contains all types, etc. needed to describe the IOs information contained in a data_conversion_layer::monitoring_frame::Message. More...

Classes

struct  PinData
 Represents the IO PIN field of a monitoring frame. More...
 

Typedefs

using IoName = std::string
 
using Lit = LogicalInputType
 
using Ot = OutputType
 
using RawChunk = std::array< uint8_t, io::RAW_CHUNK_LENGTH_IN_BYTES >
 

Enumerations

enum  LogicalInputType {
  LogicalInputType::zone_sw_2, LogicalInputType::zone_sw_1, LogicalInputType::overr_2_a, LogicalInputType::overr_1_a,
  LogicalInputType::muting_2_a, LogicalInputType::muting_1_a, LogicalInputType::reset_a, LogicalInputType::zone_sw_8,
  LogicalInputType::zone_sw_7, LogicalInputType::zone_sw_6, LogicalInputType::zone_sw_5, LogicalInputType::zone_sw_4,
  LogicalInputType::zone_sw_3, LogicalInputType::cor_seq_mut_2, LogicalInputType::mut_en_2_a, LogicalInputType::restart_2_a,
  LogicalInputType::cor_seq_or_1, LogicalInputType::cor_seq_mut_1, LogicalInputType::mut_en_1_a, LogicalInputType::restart_1_a,
  LogicalInputType::cor_seq_or_2, LogicalInputType::unused
}
 
enum  OutputType {
  OutputType::unused, OutputType::ossd1_refpts, OutputType::warn_2_int, OutputType::warn_1_int,
  OutputType::ossd3_lock, OutputType::safe_3_int, OutputType::int_lock_2, OutputType::safe_2_int,
  OutputType::int_lock_1, OutputType::safe_1_int
}
 

Functions

template<size_t ChunkSize>
void deserializePinField (std::istream &is, std::array< std::bitset< 8 >, ChunkSize > &pin_states)
 
PinData deserializePins (std::istream &is)
 
static std::string getInputName (std::size_t byte_location, std::size_t bit_location)
 
static LogicalInputType getInputType (std::size_t byte_location, std::size_t bit_location)
 
static std::string getOutputName (std::size_t byte_location, std::size_t bit_location)
 
static OutputType getOutputType (std::size_t byte_location, std::size_t bit_location)
 
std::ostream & operator<< (std::ostream &os, const PinData &pd)
 

Variables

static const std::map< Lit, IoNameLOGICAL_INPUT_BIT_TO_NAME
 
static constexpr std::array< std::array< Lit, 8 >, RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTESLOGICAL_INPUT_BITS
 
static constexpr uint32_t NUMBER_OF_INPUT_BYTES { RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES }
 
static constexpr uint32_t NUMBER_OF_OUTPUT_BYTES { RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES }
 
static const std::map< Ot, IoNameOUTPUT_BIT_TO_NAME
 
static constexpr std::array< std::array< Ot, 8 >, RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTESOUTPUT_BITS
 
static constexpr uint32_t RAW_CHUNK_LENGTH_IN_BYTES
 
static constexpr uint32_t RAW_CHUNK_LENGTH_RESERVED_IN_BYTES { 4 }
 Contains constants and types needed to define PinData and for the (de)serialization. More...
 
static constexpr uint32_t RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES { 8 }
 
static constexpr uint32_t RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES { 4 }
 
static constexpr uint32_t RAW_CHUNK_PHYSICAL_INPUT_SIGNALS_IN_BYTES { 10 }
 

Detailed Description

Contains all types, etc. needed to describe the IOs information contained in a data_conversion_layer::monitoring_frame::Message.

Typedef Documentation

◆ IoName

Definition at line 78 of file io_constants.h.

◆ Lit

Definition at line 77 of file io_constants.h.

◆ Ot

Definition at line 137 of file io_constants.h.

◆ RawChunk

Definition at line 44 of file io_constants.h.

Enumeration Type Documentation

◆ LogicalInputType

Enumerator
zone_sw_2 
zone_sw_1 
overr_2_a 
overr_1_a 
muting_2_a 
muting_1_a 
reset_a 
zone_sw_8 
zone_sw_7 
zone_sw_6 
zone_sw_5 
zone_sw_4 
zone_sw_3 
cor_seq_mut_2 
mut_en_2_a 
restart_2_a 
cor_seq_or_1 
cor_seq_mut_1 
mut_en_1_a 
restart_1_a 
cor_seq_or_2 
unused 

Definition at line 48 of file io_constants.h.

◆ OutputType

Enumerator
unused 
ossd1_refpts 
warn_2_int 
warn_1_int 
ossd3_lock 
safe_3_int 
int_lock_2 
safe_2_int 
int_lock_1 
safe_1_int 

Definition at line 122 of file io_constants.h.

Function Documentation

◆ deserializePinField()

template<size_t ChunkSize>
void psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::deserializePinField ( std::istream &  is,
std::array< std::bitset< 8 >, ChunkSize > &  pin_states 
)

Definition at line 158 of file monitoring_frame_deserialization.h.

◆ deserializePins()

PinData psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::deserializePins ( std::istream &  is)

Definition at line 185 of file monitoring_frame_deserialization.cpp.

◆ getInputName()

static std::string psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::getInputName ( std::size_t  byte_location,
std::size_t  bit_location 
)
inlinestatic
Exceptions
std::out_of_rangeif byte_location >= NUMBER_OF_INPUT_BYTES or bit_location >= 8

Definition at line 52 of file io_pin_data.h.

◆ getInputType()

static LogicalInputType psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::getInputType ( std::size_t  byte_location,
std::size_t  bit_location 
)
inlinestatic
Exceptions
std::out_of_rangeif byte_location >= NUMBER_OF_INPUT_BYTES or bit_location >= 8

Definition at line 46 of file io_pin_data.h.

◆ getOutputName()

static std::string psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::getOutputName ( std::size_t  byte_location,
std::size_t  bit_location 
)
inlinestatic
Exceptions
std::out_of_rangeif byte_location >= NUMBER_OF_OUTPUT_BYTES or bit_location >= 8

Definition at line 64 of file io_pin_data.h.

◆ getOutputType()

static OutputType psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::getOutputType ( std::size_t  byte_location,
std::size_t  bit_location 
)
inlinestatic
Exceptions
std::out_of_rangeif byte_location >= NUMBER_OF_OUTPUT_BYTES or bit_location >= 8

Definition at line 58 of file io_pin_data.h.

◆ operator<<()

std::ostream& psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::operator<< ( std::ostream &  os,
const PinData pd 
)
inline

Definition at line 84 of file io_pin_data.h.

Variable Documentation

◆ LOGICAL_INPUT_BIT_TO_NAME

const std::map<Lit, IoName> psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::LOGICAL_INPUT_BIT_TO_NAME
static
Initial value:
{
{ Lit::zone_sw_2, "Zone Set Switching Input 2" },
{ Lit::zone_sw_1, "Zone Set Switching Input 1" },
{ Lit::overr_2_a, "Override 2 Activated" },
{ Lit::overr_1_a, "Override 1 Activated" },
{ Lit::muting_2_a, "Muting 2 Activated" },
{ Lit::muting_1_a, "Muting 1 Activated" },
{ Lit::reset_a, "Reset Activated" },
{ Lit::zone_sw_8, "Zone Set Switching Input 8" },
{ Lit::zone_sw_7, "Zone Set Switching Input 7" },
{ Lit::zone_sw_6, "Zone Set Switching Input 6" },
{ Lit::zone_sw_5, "Zone Set Switching Input 5" },
{ Lit::zone_sw_4, "Zone Set Switching Input 4" },
{ Lit::zone_sw_3, "Zone Set Switching Input 3" },
{ Lit::cor_seq_mut_2, "Correct activation sequence of Muting 2 Pins" },
{ Lit::mut_en_2_a, "Muting Enable 2 Activated" },
{ Lit::restart_2_a, "Restart 2 Activated" },
{ Lit::cor_seq_or_1, "Correct activation sequence of Override 1 Pins" },
{ Lit::cor_seq_mut_1, "Correct activation sequence of Muting 1 Pins" },
{ Lit::mut_en_1_a, "Muting Enable 1 Activated" },
{ Lit::restart_1_a, "Restart 1 Activated" },
{ Lit::cor_seq_or_2, "Correct activation sequence of Override 2 Pins" },
{ Lit::unused, "unused" },
}

Definition at line 80 of file io_constants.h.

◆ LOGICAL_INPUT_BITS

constexpr std::array<std::array<Lit, 8>, RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES> psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::LOGICAL_INPUT_BITS
staticconstexpr
Initial value:
{{
{ Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused },
{ Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused },
{ Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused },
{ Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused },
{ REV(Lit::zone_sw_2, Lit::zone_sw_1, Lit::unused, Lit::overr_2_a, Lit::overr_1_a, Lit::unused, Lit::muting_2_a, Lit::muting_1_a) },
{ REV(Lit::unused, Lit::reset_a, Lit::zone_sw_8, Lit::zone_sw_7, Lit::zone_sw_6, Lit::zone_sw_5, Lit::zone_sw_4, Lit::zone_sw_3) },
{ REV(Lit::cor_seq_mut_2, Lit::mut_en_2_a, Lit::restart_2_a, Lit::unused, Lit::cor_seq_or_1, Lit::cor_seq_mut_1, Lit::mut_en_1_a, Lit::restart_1_a) },
{ REV(Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::unused, Lit::cor_seq_or_2) },
}}

Definition at line 109 of file io_constants.h.

◆ NUMBER_OF_INPUT_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::NUMBER_OF_INPUT_BYTES { RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES }
staticconstexpr

Definition at line 42 of file io_pin_data.h.

◆ NUMBER_OF_OUTPUT_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::NUMBER_OF_OUTPUT_BYTES { RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES }
staticconstexpr

Definition at line 43 of file io_pin_data.h.

◆ OUTPUT_BIT_TO_NAME

const std::map<Ot, IoName> psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::OUTPUT_BIT_TO_NAME
static
Initial value:
{
{ Ot::unused, "unused" },
{ Ot::ossd1_refpts, "REFERENCE POINTS VIOLATION" },
{ Ot::warn_2_int, "Warning 2 intrusion" },
{ Ot::warn_1_int, "Warning 1 intrusion" },
{ Ot::safe_3_int, "Safety 3 intrusion" },
{ Ot::int_lock_2, "INTERLOCK 2" },
{ Ot::safe_2_int, "Safety 2 intrusion" },
{ Ot::int_lock_1, "INTERLOCK 1" },
{ Ot::safe_1_int, "Safety 1 intrusion" }
}

Definition at line 141 of file io_constants.h.

◆ OUTPUT_BITS

constexpr std::array<std::array<Ot, 8>, RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES> psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::OUTPUT_BITS
staticconstexpr
Initial value:
{{
{ REV(Ot::warn_2_int, Ot::warn_1_int, Ot::unused, Ot::safe_3_int, Ot::int_lock_2, Ot::safe_2_int, Ot::int_lock_1, Ot::safe_1_int) },
{ REV(Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused) },
{ REV(Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused, Ot::unused) },
{ REV(Ot::unused, Ot::unused, Ot::unused, Ot::ossd1_refpts, Ot::unused, Ot::unused, Ot::unused, Ot::unused) }
}}

Definition at line 154 of file io_constants.h.

◆ RAW_CHUNK_LENGTH_IN_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_LENGTH_IN_BYTES
staticconstexpr

◆ RAW_CHUNK_LENGTH_RESERVED_IN_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_LENGTH_RESERVED_IN_BYTES { 4 }
staticconstexpr

Contains constants and types needed to define PinData and for the (de)serialization.

Definition at line 34 of file io_constants.h.

◆ RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES { 8 }
staticconstexpr

Definition at line 36 of file io_constants.h.

◆ RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES { 4 }
staticconstexpr

Definition at line 37 of file io_constants.h.

◆ RAW_CHUNK_PHYSICAL_INPUT_SIGNALS_IN_BYTES

constexpr uint32_t psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_PHYSICAL_INPUT_SIGNALS_IN_BYTES { 10 }
staticconstexpr

Definition at line 35 of file io_constants.h.

psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES
static constexpr uint32_t RAW_CHUNK_LOGICAL_INPUT_SIGNALS_IN_BYTES
Definition: io_constants.h:36
REV
#define REV(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8)
Definition: io_constants.h:46
psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_PHYSICAL_INPUT_SIGNALS_IN_BYTES
static constexpr uint32_t RAW_CHUNK_PHYSICAL_INPUT_SIGNALS_IN_BYTES
Definition: io_constants.h:35
psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_LENGTH_RESERVED_IN_BYTES
static constexpr uint32_t RAW_CHUNK_LENGTH_RESERVED_IN_BYTES
Contains constants and types needed to define PinData and for the (de)serialization.
Definition: io_constants.h:34
psen_scan_v2_standalone::data_conversion_layer::monitoring_frame::io::RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES
static constexpr uint32_t RAW_CHUNK_OUTPUT_SIGNALS_IN_BYTES
Definition: io_constants.h:37


psen_scan_v2
Author(s): Pilz GmbH + Co. KG
autogenerated on Sat Nov 25 2023 03:46:26