ConOpSys V2970  P004.07
ANVILEX control operating system
P014_42_V1_0_RIO.h
Go to the documentation of this file.
1 //------------------------------------------------------------------------------
2 //! @file P014_42_V1_0_RIO.h
3 //! @brief remore I/O board P014.42 V1.0 hardware driver header file.
4 //! @attention No special attention requered.
5 //! @copyright (C) 2015-2020 ANVILEX LLC
6 //! $HeadURL: https://192.168.3.4:8443/svn/P004_07/ConOpSys/Hardware/P014_42_V1_0_RIO/P014_42_V1_0_RIO.h $
7 //! $Revision: 2262 $
8 //! $Date: 2020-12-05 07:20:48 +0500 (Sa, 05 Dez 2020) $
9 //! $Author: minch $
10 //------------------------------------------------------------------------------
11 //
12 // Redistribution and use in source and binary forms, with or without
13 // modification, are permitted provided that the following conditions are met:
14 //
15 // 1. Redistributions of source code must retain the above copyright notice,
16 // this list of conditions and the following disclaimer.
17 //
18 // 2. Redistributions in binary form must reproduce the above copyright notice,
19 // this list of conditions and the following disclaimer in the documentation
20 // and/or other materials provided with the distribution.
21 //
22 // 3. Neither the name of ANVILEX nor the names of its contributors may be
23 // used to endorse or promote products derived from this software without
24 // specific prior written permission.
25 //
26 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
27 // AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
28 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
29 // ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
30 // LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
31 // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
32 // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
33 // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
34 // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
35 // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
36 // POSSIBILITY OF SUCH DAMAGE.
37 //
38 //------------------------------------------------------------------------------
39 
40 //------------------------------------------------------------------------------
41 // Protecting header files from mutual, recursive inclusion.
42 //------------------------------------------------------------------------------
43 
44 #pragma once
45 
46 //------------------------------------------------------------------------------
47 // Include standard libraries header files
48 //------------------------------------------------------------------------------
49 
50 //------------------------------------------------------------------------------
51 // Include thrid party header files
52 //------------------------------------------------------------------------------
53 
54 //------------------------------------------------------------------------------
55 // Include ConOpSys header files
56 //------------------------------------------------------------------------------
57 
58 #include "Functional_Block_Base.h"
59 
60 //------------------------------------------------------------------------------
61 // Include ConOpSys application header files
62 //------------------------------------------------------------------------------
63 
64 //------------------------------------------------------------------------------
65 // Macros
66 //------------------------------------------------------------------------------
67 
68 //------------------------------------------------------------------------------
69 //! @brief Remote I/O board P014.42 V2.0 class
70 //------------------------------------------------------------------------------
71 
72 class TP014_42_V1_0_RIO : public TFunctional_Block_Base
73 {
74 
75  //----------------------------------------------------------------------------
76  // Public defines, methods and variables
77  //----------------------------------------------------------------------------
78 
79  public:
80 
81  // Register structure for generic access
82  typedef struct
83  {
84 
85  // Control and status registers
86  U16 u16_Control_Word_Overwrite_Bits; //!< Control word overwrite bis
87  U16 u16_Control_Word_Set_Bits; //!< Control word set bits
88  U16 u16_Control_Word_Reset_Bits; //!< Control word reset bits
89  U16 u16_Control_Word_Toggle_Bits; //!< Control word toggle bits
90  U16 u16_Status_Word; //!< Status word
91 
93 
94  //--------------------------------------------------------------------------
95  // Public methods
96  //--------------------------------------------------------------------------
97 
98  // Constructor and destructor
101 
102  VOID Map( TP014_42_V1_0_RIO_Registers *struct_Registers_Base_Address );
103  virtual VOID Init();
104  virtual VOID Execute();
105 
106  //----------------------------------------------------------------------------
107  // Protected defines, methods and variables
108  //----------------------------------------------------------------------------
109 
110  protected:
111 
112  //----------------------------------------------------------------------------
113  // Private defines, methods and variables
114  //----------------------------------------------------------------------------
115 
116  private:
117 
119 
120 };
121 
122 //------------------------------------------------------------------------------
123 // End Of File
124 //------------------------------------------------------------------------------
void VOID
Datatypesess datatype definition.
Definition: Defines.h:105
unsigned short U16
Binary 16-Bit unsigned integer datatype defenition.
Definition: Defines.h:193
Remote I/O board P014.42 V2.0 class.
Definition: P014_42_V1_0_RIO.h:73
virtual VOID Execute()
Remote I/O board P014.42 V1.0 execute method.
Definition: P014_42_V1_0_RIO.cpp:117
virtual VOID Init()
Remote I/O board P014.42 V1.0 object initialization.
Definition: P014_42_V1_0_RIO.cpp:107
TP014_42_V1_0_RIO()
Remote I/O board P014.42 V1.0 object conctructor.
Definition: P014_42_V1_0_RIO.cpp:68
volatile TP014_42_V1_0_RIO_Registers * struct_Registers
Definition: P014_42_V1_0_RIO.h:118
VOID Map(TP014_42_V1_0_RIO_Registers *struct_Registers_Base_Address)
Remote I/O board P014.42 V1.0 memory mapping.
Definition: P014_42_V1_0_RIO.cpp:92
~TP014_42_V1_0_RIO()
Remote I/O board P014.42 V1.0 object destructor.
Definition: P014_42_V1_0_RIO.cpp:81
Definition: P014_42_V1_0_RIO.h:83
U16 u16_Status_Word
Status word.
Definition: P014_42_V1_0_RIO.h:90
U16 u16_Control_Word_Set_Bits
Control word set bits.
Definition: P014_42_V1_0_RIO.h:87
U16 u16_Control_Word_Toggle_Bits
Control word toggle bits.
Definition: P014_42_V1_0_RIO.h:89
U16 u16_Control_Word_Reset_Bits
Control word reset bits.
Definition: P014_42_V1_0_RIO.h:88
U16 u16_Control_Word_Overwrite_Bits
Control word overwrite bis.
Definition: P014_42_V1_0_RIO.h:86