00001 // this is for emacs file handling -*- mode: c++; indent-tabs-mode: nil -*- 00002 00003 // -- BEGIN LICENSE BLOCK ---------------------------------------------- 00004 00024 // -- END LICENSE BLOCK ------------------------------------------------ 00025 00026 //---------------------------------------------------------------------- 00033 //---------------------------------------------------------------------- 00034 00035 #ifndef SICK_SAFETYSCANNERS_DATASTRUCTURE_APPLICATIONOUTPUTS_H 00036 #define SICK_SAFETYSCANNERS_DATASTRUCTURE_APPLICATIONOUTPUTS_H 00037 00038 #include <stdint.h> 00039 #include <vector> 00040 00041 00042 namespace sick { 00043 namespace datastructure { 00044 00048 class ApplicationOutputs 00049 { 00050 public: 00054 ApplicationOutputs(); 00055 00061 std::vector<bool> getEvalOutVector() const; 00067 void setEvalOutVector(const std::vector<bool>& eval_out_vector); 00068 00074 std::vector<bool> getEvalOutIsSafeVector() const; 00080 void setEvalOutIsSafeVector(const std::vector<bool>& eval_out_is_safe_vector); 00081 00087 std::vector<bool> getEvalOutIsValidVector() const; 00093 void setEvalOutIsValidVector(const std::vector<bool>& eval_out_is_valid_vector); 00094 00100 std::vector<uint16_t> getMonitoringCaseVector() const; 00106 void setMonitoringCaseVector(const std::vector<uint16_t>& monitoring_case_vector); 00107 00113 std::vector<bool> getMonitoringCaseFlagsVector() const; 00119 void setMonitoringCaseFlagsVector(const std::vector<bool>& monitoring_case_flags_vector); 00120 00126 int8_t getSleepModeOutput() const; 00132 void setSleepModeOutput(const int8_t& sleep_mode_output); 00133 00139 bool getHostErrorFlagContaminationWarning() const; 00145 void setHostErrorFlagContaminationWarning(bool host_error_flag_contamination_warning); 00146 00152 bool getHostErrorFlagContaminationError() const; 00158 void setHostErrorFlagContaminationError(bool host_error_flag_contamination_error); 00159 00165 bool getHostErrorFlagManipulationError() const; 00171 void setHostErrorFlagManipulationError(bool host_error_flag_manipulation_error); 00172 00178 bool getHostErrorFlagGlare() const; 00184 void setHostErrorFlagGlare(bool host_error_flag_glare); 00185 00191 bool getHostErrorFlagReferenceContourIntruded() const; 00197 void setHostErrorFlagReferenceContourIntruded(bool host_error_flag_reference_contour_intruded); 00198 00204 bool getHostErrorFlagCriticalError() const; 00210 void setHostErrorFlagCriticalError(bool host_error_flag_critical_error); 00211 00217 int16_t getVelocity0() const; 00223 void setVelocity0(const int16_t& velocity_0); 00224 00230 int16_t getVelocity1() const; 00236 void setVelocity1(const int16_t& velocity_1); 00237 00243 bool getVelocity0Valid() const; 00249 void setVelocity0Valid(bool velocity_0_valid); 00250 00256 bool getVelocity1Valid() const; 00262 void setVelocity1Valid(bool velocity_1_valid); 00263 00269 bool getVelocity0TransmittedSafely() const; 00275 void setVelocity0TransmittedSafely(bool velocity_0_transmitted_safely); 00276 00282 bool getVelocity1TransmittedSafely() const; 00289 void setVelocity1TransmittedSafely(bool velocity_1_transmitted_safely); 00290 00296 std::vector<int16_t> getResultingVelocityVector() const; 00302 void setResultingVelocityVector(const std::vector<int16_t>& resulting_velocity_vector); 00303 00309 std::vector<bool> getResultingVelocityIsValidVector() const; 00310 void 00316 setResultingVelocityIsValidVector(const std::vector<bool>& resulting_velocity_is_valid_vector); 00317 00323 bool getFlagsSleepModeOutputIsValid() const; 00329 void setFlagsSleepModeOutputIsValid(bool flags_sleep_mode_output_is_valid); 00330 00336 bool getFlagsHostErrorFlagsAreValid() const; 00342 void setFlagsHostErrorFlagsAreValid(bool flags_host_error_flags_are_valid); 00343 00344 private: 00345 std::vector<bool> m_eval_out_vector; 00346 std::vector<bool> m_eval_out_is_safe_vector; 00347 std::vector<bool> m_eval_out_is_valid_vector; 00348 00349 std::vector<uint16_t> m_monitoring_case_vector; 00350 std::vector<bool> m_monitoring_case_flags_vector; 00351 00352 int8_t m_sleep_mode_output; 00353 00354 bool m_host_error_flag_contamination_warning; 00355 bool m_host_error_flag_contamination_error; 00356 bool m_host_error_flag_manipulation_error; 00357 bool m_host_error_flag_glare; 00358 bool m_host_error_flag_reference_contour_intruded; 00359 bool m_host_error_flag_critical_error; 00360 00361 int16_t m_velocity_0; 00362 int16_t m_velocity_1; 00363 00364 bool m_velocity_0_valid; 00365 bool m_velocity_1_valid; 00366 bool m_velocity_0_transmitted_safely; 00367 bool m_velocity_1_transmitted_safely; 00368 00369 std::vector<int16_t> m_resulting_velocity_vector; 00370 std::vector<bool> m_resulting_velocity_is_valid_vector; 00371 00372 bool m_flags_sleep_mode_output_is_valid; 00373 bool m_flags_host_error_flags_are_valid; 00374 }; 00375 00376 00377 } // namespace datastructure 00378 } // namespace sick 00379 00380 #endif // SICK_SAFETYSCANNERS_DATASTRUCTURE_APPLICATIONOUTPUTS_H