blob: 3245441bf3a0ae6a4438d2c37cb9a32e89d43456 [file] [log] [blame]
Chip Boling6e27b352020-02-14 09:10:01 -06001/*
2 * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net)
Andrea Campanella7167ebb2020-02-24 09:56:38 +01003 * Copyright 2020-present Open Networking Foundation
4
Chip Boling6e27b352020-02-14 09:10:01 -06005 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
Andrea Campanella7167ebb2020-02-24 09:56:38 +01008
Chip Boling6e27b352020-02-14 09:10:01 -06009 * http://www.apache.org/licenses/LICENSE-2.0
Andrea Campanella7167ebb2020-02-24 09:56:38 +010010
Chip Boling6e27b352020-02-14 09:10:01 -060011 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
Chip Boling34ebcb62021-02-02 12:13:58 -060017/*
Chip Boling6e27b352020-02-14 09:10:01 -060018 * NOTE: This file was generated, manual edits will be overwritten!
19 *
20 * Generated by 'goCodeGenerator.py':
21 * https://github.com/cboling/OMCI-parser/README.md
22 */
23
24package generated
25
26import "github.com/deckarep/golang-set"
27
28// XgPonDownstreamManagementPerformanceMonitoringHistoryDataClassID is the 16-bit ID for the OMCI
29// Managed entity XG-PON downstream management performance monitoring history data
Chip Boling610117d2021-09-09 11:24:34 -050030const XgPonDownstreamManagementPerformanceMonitoringHistoryDataClassID = ClassID(345) // 0x0159
Chip Boling6e27b352020-02-14 09:10:01 -060031
32var xgpondownstreammanagementperformancemonitoringhistorydataBME *ManagedEntityDefinition
33
Chip Boling610117d2021-09-09 11:24:34 -050034// XgPonDownstreamManagementPerformanceMonitoringHistoryData (Class ID: #345 / 0x0159)
Chip Boling6e27b352020-02-14 09:10:01 -060035// This ME collects PM data associated with the XG-PON TC layer. It collects counters associated
36// with downstream PLOAM and OMCI messages.
37//
38// For a complete discussion of generic PM architecture, refer to clause I.4.
39//
40// Relationships
41// An instance of this ME is associated with an ANI-G.
42//
43// Attributes
44// Managed Entity Id
Chip Boling610117d2021-09-09 11:24:34 -050045// This attribute uniquely identifies each instance of this ME. Through an identical ID, this ME is
46// implicitly linked to an instance of the ANI-G. (R, set-by-create) (mandatory) (2-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060047//
48// Interval End Time
Chip Boling610117d2021-09-09 11:24:34 -050049// This attribute identifies the most recently finished 15-min interval. (R) (mandatory) (1-byte)
Chip Boling6e27b352020-02-14 09:10:01 -060050//
51// Threshold Data 1_2 Id
52// Threshold data 1/2 ID: This attribute points to an instance of the threshold data 1 ME that
53// contains PM threshold values. Since no threshold value attribute number exceeds 7, a threshold
54// data 2 ME is optional. (R,-W, set-by-create) (mandatory) (2-bytes)
55//
56// Ploam Message Integrity Check Mic Error Count
57// PLOAM message integrity check (MIC) error count: This attribute counts MIC errors detected in
58// downstream PLOAM messages, either directed to this ONU or broadcast to all ONUs. (R) (optional)
59// (4-bytes)
60//
61// Downstream Ploam Messages Count
Chip Boling610117d2021-09-09 11:24:34 -050062// This attribute counts PLOAM messages received, either directed to this ONU or broadcast to all
63// ONUs. (R) (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060064//
65// Profile Messages Received
Chip Boling610117d2021-09-09 11:24:34 -050066// This attribute counts the number of profile messages received, either directed to this ONU or
67// broadcast to all ONUs. In [ITU-T G.9807.1], this attribute is used for received burst_profile
68// message count. (R) (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060069//
70// Ranging_Time Messages Received
Chip Boling610117d2021-09-09 11:24:34 -050071// This attribute counts the number of ranging_time messages received, either directed to this ONU
72// or broadcast to all ONUs. (R) (mandatory) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060073//
74// Deactivate_Onu_Id Messages Received
75// Deactivate_ONU-ID messages received: This attribute counts the number of deactivate_ONU-ID
76// messages received, either directed to this ONU or broadcast to all ONUs. Deactivate_ONU-ID
77// messages do not reset this counter. (R) (optional) (4-bytes)
78//
79// Disable_Serial_Number Messages Received
Chip Boling610117d2021-09-09 11:24:34 -050080// This attribute counts the number of disable_serial_number messages received, whose serial number
81// specified this ONU. (R) (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060082//
83// Request_Registration Messages Received
Chip Boling610117d2021-09-09 11:24:34 -050084// This attribute counts the number of request_registration messages received. (R) (optional)
85// (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060086//
87// Assign_Alloc_Id Messages Received
88// Assign_alloc-ID messages received: This attribute counts the number of assign_alloc-ID messages
89// received. (R) (optional) (4-bytes)
90//
91// Key_Control Messages Received
Chip Boling610117d2021-09-09 11:24:34 -050092// This attribute counts the number of key_control messages received, either directed to this ONU
93// or broadcast to all ONUs. (R) (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060094//
95// Sleep_Allow Messages Received
Chip Boling610117d2021-09-09 11:24:34 -050096// This attribute counts the number of sleep_allow messages received, either directed to this ONU
97// or broadcast to all ONUs. (R) (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -060098//
99// Baseline Omci Messages Received Count
Chip Boling610117d2021-09-09 11:24:34 -0500100// This attribute counts the number of OMCI messages received in the baseline message format. (R)
101// (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -0600102//
103// Extended Omci Messages Received Count
Chip Boling610117d2021-09-09 11:24:34 -0500104// This attribute counts the number of OMCI messages received in the extended message format. (R)
105// (optional) (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -0600106//
107// Assign_Onu_Id Messages Received
108// Assign_ONU-ID messages received: This attribute counts the number of assign_ONU-ID messages
109// received since the last re-boot. (R) (optional) (4-bytes)
110//
111// Omci Mic Error Count
Chip Boling610117d2021-09-09 11:24:34 -0500112// This attribute counts MIC errors detected in OMCI messages directed to this ONU. (R) (optional)
113// (4-bytes)
Chip Boling6e27b352020-02-14 09:10:01 -0600114//
115type XgPonDownstreamManagementPerformanceMonitoringHistoryData struct {
116 ManagedEntityDefinition
117 Attributes AttributeValueMap
118}
119
120func init() {
121 xgpondownstreammanagementperformancemonitoringhistorydataBME = &ManagedEntityDefinition{
122 Name: "XgPonDownstreamManagementPerformanceMonitoringHistoryData",
123 ClassID: 345,
124 MessageTypes: mapset.NewSetWith(
125 Create,
126 Delete,
127 Get,
128 Set,
Chip Boling2d51f052021-02-09 09:04:15 -0600129 GetCurrentData,
Chip Boling6e27b352020-02-14 09:10:01 -0600130 ),
131 AllowedAttributeMask: 0xffff,
132 AttributeDefinitions: AttributeDefinitionMap{
133 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0),
134 1: ByteField("IntervalEndTime", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read), false, false, false, 1),
135 2: Uint16Field("ThresholdData12Id", PointerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 2),
136 3: Uint32Field("PloamMessageIntegrityCheckMicErrorCount", CounterAttributeType, 0x2000, 0, mapset.NewSetWith(Read), false, true, false, 3),
137 4: Uint32Field("DownstreamPloamMessagesCount", CounterAttributeType, 0x1000, 0, mapset.NewSetWith(Read), false, true, false, 4),
138 5: Uint32Field("ProfileMessagesReceived", CounterAttributeType, 0x0800, 0, mapset.NewSetWith(Read), false, true, false, 5),
139 6: Uint32Field("RangingTimeMessagesReceived", CounterAttributeType, 0x0400, 0, mapset.NewSetWith(Read), false, false, false, 6),
140 7: Uint32Field("DeactivateOnuIdMessagesReceived", CounterAttributeType, 0x0200, 0, mapset.NewSetWith(Read), false, true, false, 7),
141 8: Uint32Field("DisableSerialNumberMessagesReceived", CounterAttributeType, 0x0100, 0, mapset.NewSetWith(Read), false, true, false, 8),
142 9: Uint32Field("RequestRegistrationMessagesReceived", CounterAttributeType, 0x0080, 0, mapset.NewSetWith(Read), false, true, false, 9),
143 10: Uint32Field("AssignAllocIdMessagesReceived", CounterAttributeType, 0x0040, 0, mapset.NewSetWith(Read), false, true, false, 10),
144 11: Uint32Field("KeyControlMessagesReceived", CounterAttributeType, 0x0020, 0, mapset.NewSetWith(Read), false, true, false, 11),
145 12: Uint32Field("SleepAllowMessagesReceived", CounterAttributeType, 0x0010, 0, mapset.NewSetWith(Read), false, true, false, 12),
146 13: Uint32Field("BaselineOmciMessagesReceivedCount", CounterAttributeType, 0x0008, 0, mapset.NewSetWith(Read), false, true, false, 13),
147 14: Uint32Field("ExtendedOmciMessagesReceivedCount", CounterAttributeType, 0x0004, 0, mapset.NewSetWith(Read), false, true, false, 14),
148 15: Uint32Field("AssignOnuIdMessagesReceived", CounterAttributeType, 0x0002, 0, mapset.NewSetWith(Read), false, true, false, 15),
149 16: Uint32Field("OmciMicErrorCount", CounterAttributeType, 0x0001, 0, mapset.NewSetWith(Read), false, true, false, 16),
150 },
151 Access: CreatedByOlt,
152 Support: UnknownSupport,
Chip Boling34ebcb62021-02-02 12:13:58 -0600153 Alarms: AlarmMap{
154 1: "PLOAM MIC error count",
155 2: "OMCI MIC error count",
156 },
Chip Boling6e27b352020-02-14 09:10:01 -0600157 }
158}
159
160// NewXgPonDownstreamManagementPerformanceMonitoringHistoryData (class ID 345) creates the basic
161// Managed Entity definition that is used to validate an ME of this type that
162// is received from or transmitted to the OMCC.
163func NewXgPonDownstreamManagementPerformanceMonitoringHistoryData(params ...ParamData) (*ManagedEntity, OmciErrors) {
164 return NewManagedEntity(*xgpondownstreammanagementperformancemonitoringhistorydataBME, params...)
165}