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 | // PhysicalPathTerminationPointVideoAniClassID is the 16-bit ID for the OMCI |
| 29 | // Managed entity Physical path termination point video ANI |
| 30 | const PhysicalPathTerminationPointVideoAniClassID ClassID = ClassID(90) |
| 31 | |
| 32 | var physicalpathterminationpointvideoaniBME *ManagedEntityDefinition |
| 33 | |
| 34 | // PhysicalPathTerminationPointVideoAni (class ID #90) |
| 35 | // This ME represents an RF video ANI in the ONU, where physical paths terminate and physical path |
| 36 | // level functions are performed. |
| 37 | // |
| 38 | // The ONU automatically creates an instance of this ME per port as follows. |
| 39 | // |
| 40 | // o When the ONU has video ANI ports built into its factory configuration. |
| 41 | // |
| 42 | // o When a cardholder is provisioned to expect a circuit pack of the video ANI type. |
| 43 | // |
| 44 | // o When a cardholder provisioned for plug-and-play is equipped with a circuit pack of the video |
| 45 | // ANI type. Note that the installation of a plug-and-play card may indicate the presence of video |
| 46 | // ANI ports via equipment ID as well as its type, and indeed may cause the ONU to instantiate a |
| 47 | // port-mapping package that specifies video ANI ports. |
| 48 | // |
| 49 | // The ONU automatically deletes instances of this ME when a cardholder is neither provisioned to |
| 50 | // expect a video ANI circuit pack, nor is it equipped with a video ANI circuit pack. |
| 51 | // |
| 52 | // Relationships |
| 53 | // An instance of this ME is associated with each instance of a real or pre-provisioned video ANI |
| 54 | // port. |
| 55 | // |
| 56 | // Attributes |
| 57 | // Managed Entity Id |
| 58 | // Managed entity ID: This attribute uniquely identifies each instance of this ME. This 2-byte |
| 59 | // number indicates the physical position of the ANI. The first byte is the slot ID (defined in |
| 60 | // clause 9.1.5). The second byte is the port ID, with the range 1..255. (R) (mandatory) (2-bytes) |
| 61 | // |
| 62 | // Administrative State |
| 63 | // Administrative state: This attribute locks (1) and unlocks (0) the functions performed by this |
| 64 | // ME. Administrative state is further described in clause-A.1.6. (R,-W) (mandatory) (1-byte) |
| 65 | // |
| 66 | // Operational State |
| 67 | // Operational state: This attribute indicates whether the ME is capable of performing its |
| 68 | // function. Valid values are enabled (0) and disabled (1). (R) (optional) (1-byte) |
| 69 | // |
| 70 | // Arc |
| 71 | // ARC: See clause A.1.4.3. (R,-W) (optional) (1-byte) |
| 72 | // |
| 73 | // Arc Interval |
| 74 | // ARC interval: See clause A.1.4.3. (R,-W) (optional) (1-byte) |
| 75 | // |
| 76 | // Frequency Range Low |
| 77 | // (R) (mandatory) (1-byte) |
| 78 | // |
| 79 | // Frequency Range High |
| 80 | // (R) (mandatory) (1-byte) |
| 81 | // |
| 82 | // Signal Capability |
| 83 | // (R) (mandatory) (1-byte) |
| 84 | // |
| 85 | // Optical Signal Level |
| 86 | // (R) (optional) (1-byte) |
| 87 | // |
| 88 | // Pilot Signal Level |
| 89 | // (R) (optional) (1-byte) |
| 90 | // |
| 91 | // Signal Level Min |
| 92 | // Signal level min: This attribute indicates the minimum optical RF power per channel that results |
| 93 | // in a CNR of 47-dBc for a channel of 4.5 MHz bandwidth at a receive optical power of -5-dBm. The |
| 94 | // unit of this attribute is decibel-microwatt optical. (R) (mandatory) (1-byte) |
| 95 | // |
| 96 | // Signal Level Max |
| 97 | // Signal level max: This attribute indicates the maximum optical RF power per channel that results |
| 98 | // in a CTB of -57-dBc for an 80-channel ensemble of carriers at a perchannel optical modulation |
| 99 | // index (OMI) of 3.5%. The unit of this attribute is decibel-microwatt optical. (R) (mandatory) |
| 100 | // (1-byte) |
| 101 | // |
| 102 | // Pilot Frequency |
| 103 | // (R,-W) (optional) (4-bytes) |
| 104 | // |
| 105 | // Agc Mode |
| 106 | // (R,-W) (optional) (1-byte) |
| 107 | // |
| 108 | // Agc Setting |
| 109 | // (R,-W) (optional) (1-byte) |
| 110 | // |
| 111 | // Video Lower Optical Threshold |
| 112 | // NOTE - Because the power measurement returned in the optical signal level attribute has a |
| 113 | // resolution of 1-dB, it is possible that the measured value could appear to be in-range, even |
| 114 | // though an out-of-range alarm has been declared against a threshold with 0.1-dB resolution. |
| 115 | // |
| 116 | // Video Upper Optical Threshold |
| 117 | // Video upper optical threshold: This attribute specifies the optical level used to declare the |
| 118 | // video OOR high alarm. Valid values are -12 to +6-dBm in 0.1-dB increments, represented as a 2s |
| 119 | // complement integer. (Coding -120 to +60, 0x00-= 0-dBm, 0x88-= -12.0-dBm, etc.) Upon ME |
| 120 | // instantiation, the ONU sets this attribute to 0x19 (+2.5-dBm). (R,-W) (optional) (1-byte) |
| 121 | // |
| 122 | type PhysicalPathTerminationPointVideoAni struct { |
| 123 | ManagedEntityDefinition |
| 124 | Attributes AttributeValueMap |
| 125 | } |
| 126 | |
| 127 | func init() { |
| 128 | physicalpathterminationpointvideoaniBME = &ManagedEntityDefinition{ |
| 129 | Name: "PhysicalPathTerminationPointVideoAni", |
| 130 | ClassID: 90, |
| 131 | MessageTypes: mapset.NewSetWith( |
| 132 | Get, |
| 133 | Set, |
| 134 | ), |
| 135 | AllowedAttributeMask: 0xffff, |
| 136 | AttributeDefinitions: AttributeDefinitionMap{ |
| 137 | 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read), false, false, false, 0), |
| 138 | 1: ByteField("AdministrativeState", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read, Write), false, false, false, 1), |
| 139 | 2: ByteField("OperationalState", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read), true, true, false, 2), |
| 140 | 3: ByteField("Arc", UnsignedIntegerAttributeType, 0x2000, 0, mapset.NewSetWith(Read, Write), true, true, false, 3), |
| 141 | 4: ByteField("ArcInterval", UnsignedIntegerAttributeType, 0x1000, 0, mapset.NewSetWith(Read, Write), false, true, false, 4), |
| 142 | 5: ByteField("FrequencyRangeLow", UnsignedIntegerAttributeType, 0x0800, 0, mapset.NewSetWith(Read), false, false, false, 5), |
| 143 | 6: ByteField("FrequencyRangeHigh", UnsignedIntegerAttributeType, 0x0400, 0, mapset.NewSetWith(Read), false, false, false, 6), |
| 144 | 7: ByteField("SignalCapability", UnsignedIntegerAttributeType, 0x0200, 0, mapset.NewSetWith(Read), false, false, false, 7), |
| 145 | 8: ByteField("OpticalSignalLevel", UnsignedIntegerAttributeType, 0x0100, 0, mapset.NewSetWith(Read), false, true, false, 8), |
| 146 | 9: ByteField("PilotSignalLevel", UnsignedIntegerAttributeType, 0x0080, 0, mapset.NewSetWith(Read), false, true, false, 9), |
| 147 | 10: ByteField("SignalLevelMin", UnsignedIntegerAttributeType, 0x0040, 0, mapset.NewSetWith(Read), false, false, false, 10), |
| 148 | 11: ByteField("SignalLevelMax", UnsignedIntegerAttributeType, 0x0020, 0, mapset.NewSetWith(Read), false, false, false, 11), |
| 149 | 12: Uint32Field("PilotFrequency", UnsignedIntegerAttributeType, 0x0010, 0, mapset.NewSetWith(Read, Write), false, true, false, 12), |
| 150 | 13: ByteField("AgcMode", UnsignedIntegerAttributeType, 0x0008, 0, mapset.NewSetWith(Read, Write), false, true, false, 13), |
| 151 | 14: ByteField("AgcSetting", UnsignedIntegerAttributeType, 0x0004, 0, mapset.NewSetWith(Read, Write), false, true, false, 14), |
| 152 | 15: ByteField("VideoLowerOpticalThreshold", UnsignedIntegerAttributeType, 0x0002, 0, mapset.NewSetWith(Read, Write), false, true, false, 15), |
| 153 | 16: ByteField("VideoUpperOpticalThreshold", UnsignedIntegerAttributeType, 0x0001, 0, mapset.NewSetWith(Read, Write), false, true, false, 16), |
| 154 | }, |
| 155 | Access: CreatedByOnu, |
| 156 | Support: UnknownSupport, |
Chip Boling | 34ebcb6 | 2021-02-02 12:13:58 -0600 | [diff] [blame] | 157 | Alarms: AlarmMap{ |
| 158 | 0: "Video LOS", |
| 159 | 1: "Video OOR low", |
| 160 | 2: "Video OOR high", |
| 161 | }, |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 162 | } |
| 163 | } |
| 164 | |
| 165 | // NewPhysicalPathTerminationPointVideoAni (class ID 90) creates the basic |
| 166 | // Managed Entity definition that is used to validate an ME of this type that |
| 167 | // is received from or transmitted to the OMCC. |
| 168 | func NewPhysicalPathTerminationPointVideoAni(params ...ParamData) (*ManagedEntity, OmciErrors) { |
| 169 | return NewManagedEntity(*physicalpathterminationpointvideoaniBME, params...) |
| 170 | } |