ParseDataHeader.h
Go to the documentation of this file.
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_DATA_PROCESSING_PARSEDATAHEADER_H
00036 #define SICK_SAFETYSCANNERS_DATA_PROCESSING_PARSEDATAHEADER_H
00037 
00038 
00039 #include <sick_safetyscanners/datastructure/Data.h>
00040 #include <sick_safetyscanners/datastructure/DataHeader.h>
00041 #include <sick_safetyscanners/datastructure/PacketBuffer.h>
00042 
00043 #include <sick_safetyscanners/data_processing/ReadWriteHelper.h>
00044 
00045 namespace sick {
00046 namespace data_processing {
00047 
00054 class ParseDataHeader
00055 {
00056 public:
00060   ParseDataHeader();
00061 
00070   datastructure::DataHeader parseUDPSequence(const datastructure::PacketBuffer& buffer,
00071                                              datastructure::Data& data) const;
00072 
00073 private:
00074   std::shared_ptr<sick::data_processing::ReadWriteHelper> m_reader_ptr;
00075   void setVersionIndicatorInDataHeader(const uint8_t*& data_ptr,
00076                                        datastructure::DataHeader& data_header) const;
00077   void setMajorVersionInDataHeader(const uint8_t*& data_ptr,
00078                                    datastructure::DataHeader& data_header) const;
00079   void setMinorVersionInDataHeader(const uint8_t*& data_ptr,
00080                                    datastructure::DataHeader& data_header) const;
00081   void setVersionReleaseInDataHeader(const uint8_t*& data_ptr,
00082                                      datastructure::DataHeader& data_header) const;
00083   void setSerialNumberOfDeviceInDataHeader(const uint8_t*& data_ptr,
00084                                            datastructure::DataHeader& data_header) const;
00085   void setSerialNumberOfSystemPlugInDataHeader(const uint8_t*& data_ptr,
00086                                                datastructure::DataHeader& data_header) const;
00087   void setChannelNumberInDataHeader(const uint8_t*& data_ptr,
00088                                     datastructure::DataHeader& data_header) const;
00089   void setSequenceNumberInDataHeader(const uint8_t*& data_ptr,
00090                                      datastructure::DataHeader& data_header) const;
00091   void setScanNumberInDataHeader(const uint8_t*& data_ptr,
00092                                  datastructure::DataHeader& data_header) const;
00093   void setTimestampDateInDataHeader(const uint8_t*& data_ptr,
00094                                     datastructure::DataHeader& data_header) const;
00095   void setTimestampTimeInDataHeader(const uint8_t*& data_ptr,
00096                                     datastructure::DataHeader& data_header) const;
00097   void setGeneralSystemStateBlockOffsetInDataHeader(const uint8_t*& data_ptr,
00098                                                     datastructure::DataHeader& data_header) const;
00099   void setGeneralSystemStateBlockSizeInDataHeader(const uint8_t*& data_ptr,
00100                                                   datastructure::DataHeader& data_header) const;
00101   void setDerivedValuesBlockOffsetInDataHeader(const uint8_t*& data_ptr,
00102                                                datastructure::DataHeader& data_header) const;
00103   void setDerivedValuesBlockSizeInDataHeader(const uint8_t*& data_ptr,
00104                                              datastructure::DataHeader& data_header) const;
00105   void setMeasurementDataBlockOffsetInDataHeader(const uint8_t*& data_ptr,
00106                                                  datastructure::DataHeader& data_header) const;
00107   void setMeasurementDataBlockSizeInDataHeader(const uint8_t*& data_ptr,
00108                                                datastructure::DataHeader& data_header) const;
00109   void setIntrusionDataBlockOffsetInDataHeader(const uint8_t*& data_ptr,
00110                                                datastructure::DataHeader& data_header) const;
00111   void setIntrusionDataBlockSizeInDataHeader(const uint8_t*& data_ptr,
00112                                              datastructure::DataHeader& data_header) const;
00113   void setApplicationDataBlockOffsetInDataHeader(const uint8_t*& data_ptr,
00114                                                  datastructure::DataHeader& data_header) const;
00115   void setApplicationDataBlockSizeInDataHeader(const uint8_t*& data_ptr,
00116                                                datastructure::DataHeader& data_header) const;
00117   void setDataInDataHeader(const uint8_t*& data_ptr, datastructure::DataHeader& data_header) const;
00118   void setVersionInDataHeader(const uint8_t*& data_ptr,
00119                               datastructure::DataHeader& data_header) const;
00120   void setScanHeaderInDataHeader(const uint8_t*& data_ptr,
00121                                  datastructure::DataHeader& data_header) const;
00122   void setDataBlocksInDataHeader(const uint8_t*& data_ptr,
00123                                  datastructure::DataHeader& data_header) const;
00124 };
00125 
00126 } // namespace data_processing
00127 } // namespace sick
00128 
00129 #endif // SICK_SAFETYSCANNERS_DATA_PROCESSING_PARSEDATAHEADER_H


sick_safetyscanners
Author(s): Lennart Puck
autogenerated on Tue May 7 2019 03:27:36