Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net) |
Andrea Campanella | 7167ebb | 2020-02-24 09:56:38 +0100 | [diff] [blame] | 3 | * Copyright 2020-present Open Networking Foundation |
| 4 | |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 5 | * 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 Campanella | 7167ebb | 2020-02-24 09:56:38 +0100 | [diff] [blame] | 8 | |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
Andrea Campanella | 7167ebb | 2020-02-24 09:56:38 +0100 | [diff] [blame] | 10 | |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 11 | * 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 Boling | 34ebcb6 | 2021-02-02 12:13:58 -0600 | [diff] [blame] | 17 | /* |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 18 | * 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 | |
| 24 | package generated |
| 25 | |
| 26 | import "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 Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 30 | const XgPonDownstreamManagementPerformanceMonitoringHistoryDataClassID = ClassID(345) // 0x0159 |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 31 | |
| 32 | var xgpondownstreammanagementperformancemonitoringhistorydataBME *ManagedEntityDefinition |
| 33 | |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 34 | // XgPonDownstreamManagementPerformanceMonitoringHistoryData (Class ID: #345 / 0x0159) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 35 | // 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 Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 45 | // 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 Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 47 | // |
| 48 | // Interval End Time |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 49 | // This attribute identifies the most recently finished 15-min interval. (R) (mandatory) (1-byte) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 50 | // |
| 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 Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 62 | // This attribute counts PLOAM messages received, either directed to this ONU or broadcast to all |
| 63 | // ONUs. (R) (optional) (4-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 64 | // |
| 65 | // Profile Messages Received |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 66 | // 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 Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 69 | // |
| 70 | // Ranging_Time Messages Received |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 71 | // 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 Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 73 | // |
| 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 Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 80 | // This attribute counts the number of disable_serial_number messages received, whose serial number |
| 81 | // specified this ONU. (R) (optional) (4-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 82 | // |
| 83 | // Request_Registration Messages Received |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 84 | // This attribute counts the number of request_registration messages received. (R) (optional) |
| 85 | // (4-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 86 | // |
| 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 Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 92 | // 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 Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 94 | // |
| 95 | // Sleep_Allow Messages Received |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 96 | // 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 Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 98 | // |
| 99 | // Baseline Omci Messages Received Count |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 100 | // This attribute counts the number of OMCI messages received in the baseline message format. (R) |
| 101 | // (optional) (4-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 102 | // |
| 103 | // Extended Omci Messages Received Count |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 104 | // This attribute counts the number of OMCI messages received in the extended message format. (R) |
| 105 | // (optional) (4-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 106 | // |
| 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 Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 112 | // This attribute counts MIC errors detected in OMCI messages directed to this ONU. (R) (optional) |
| 113 | // (4-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 114 | // |
| 115 | type XgPonDownstreamManagementPerformanceMonitoringHistoryData struct { |
| 116 | ManagedEntityDefinition |
| 117 | Attributes AttributeValueMap |
| 118 | } |
| 119 | |
| 120 | func init() { |
| 121 | xgpondownstreammanagementperformancemonitoringhistorydataBME = &ManagedEntityDefinition{ |
| 122 | Name: "XgPonDownstreamManagementPerformanceMonitoringHistoryData", |
| 123 | ClassID: 345, |
| 124 | MessageTypes: mapset.NewSetWith( |
| 125 | Create, |
| 126 | Delete, |
| 127 | Get, |
| 128 | Set, |
Chip Boling | 2d51f05 | 2021-02-09 09:04:15 -0600 | [diff] [blame] | 129 | GetCurrentData, |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 130 | ), |
| 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 Boling | 34ebcb6 | 2021-02-02 12:13:58 -0600 | [diff] [blame] | 153 | Alarms: AlarmMap{ |
| 154 | 1: "PLOAM MIC error count", |
| 155 | 2: "OMCI MIC error count", |
| 156 | }, |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 157 | } |
| 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. |
| 163 | func NewXgPonDownstreamManagementPerformanceMonitoringHistoryData(params ...ParamData) (*ManagedEntity, OmciErrors) { |
| 164 | return NewManagedEntity(*xgpondownstreammanagementperformancemonitoringhistorydataBME, params...) |
| 165 | } |