libiec61850  1.5.3
mms_types.h
Go to the documentation of this file.
1 /*
2  * mms_types.h
3  *
4  * Copyright 2013, 2014 Michael Zillgith
5  *
6  * This file is part of libIEC61850.
7  *
8  * libIEC61850 is free software: you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation, either version 3 of the License, or
11  * (at your option) any later version.
12  *
13  * libIEC61850 is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with libIEC61850. If not, see <http://www.gnu.org/licenses/>.
20  *
21  * See COPYING file for the complete license text.
22  */
23 
24 #ifndef MMS_TYPES_H_
25 #define MMS_TYPES_H_
26 
27 #include "libiec61850_common_api.h"
28 
29 typedef enum {
37 
46 typedef struct sMmsVariableSpecification MmsVariableSpecification;
47 
50 struct ATTRIBUTE_PACKED sMmsVariableSpecification {
52  char* name;
54  {
55  struct sMmsArray {
56  int elementCount; /* number of array elements */
57  MmsVariableSpecification* elementTypeSpec;
58  } array;
59  struct sMmsStructure {
61  MmsVariableSpecification** elements;
62  } structure;
63  int boolean; /* dummy - not required */
64  int integer; /* size of integer in bits */
65  int unsignedInteger; /* size of integer in bits */
66  struct sMmsFloat
67  {
68  uint8_t exponentWidth;
69  uint8_t formatWidth;
70  } floatingpoint;
71  int bitString; /* Number of bits in bitstring */
72  int octetString; /* Number of octets in octet string */
73  int visibleString; /* Maximum size of string */
74  int mmsString;
75  int utctime; /* dummy - not required */
76  int binaryTime; /* size: either 4 or 6 */
77  } typeSpec;
78 };
79 
80 
81 #endif /* MMS_TYPES_H_ */
MmsType
Definition: mms_common.h:106
MmsValueIndication
Definition: mms_types.h:29
@ MMS_VALUE_ACCESS_DENIED
Definition: mms_types.h:32
@ MMS_VALUE_NO_RESPONSE
Definition: mms_types.h:30
@ MMS_VALUE_VALUE_INVALID
Definition: mms_types.h:33
@ MMS_VALUE_TEMPORARILY_UNAVAILABLE
Definition: mms_types.h:34
@ MMS_VALUE_OBJECT_ACCESS_UNSUPPORTED
Definition: mms_types.h:35
@ MMS_VALUE_OK
Definition: mms_types.h:31
MmsVariableSpecification * elementTypeSpec
Definition: mms_types.h:57
MmsVariableSpecification ** elements
Definition: mms_types.h:61
Definition: mms_types.h:50
MmsType type
Definition: mms_types.h:51
char * name
Definition: mms_types.h:52
int visibleString
Definition: mms_types.h:73
int unsignedInteger
Definition: mms_types.h:65
int octetString
Definition: mms_types.h:72
int binaryTime
Definition: mms_types.h:76