blob: ea700ddc6fb21a75590eaa30779b2aea68b52659 [file] [log] [blame]
Andrea Campanella10426e22021-10-15 17:58:04 +02001/*
2 * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net)
3 * Copyright 2020-present Open Networking Foundation
Elia Battiston9bfe1102022-02-03 10:38:03 +01004 *
Andrea Campanella10426e22021-10-15 17:58:04 +02005 * 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
Elia Battiston9bfe1102022-02-03 10:38:03 +01008 *
Andrea Campanella10426e22021-10-15 17:58:04 +02009 * http://www.apache.org/licenses/LICENSE-2.0
Elia Battiston9bfe1102022-02-03 10:38:03 +010010 *
Andrea Campanella10426e22021-10-15 17:58:04 +020011 * 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 */
17/*
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
24package generated
25
26import "github.com/deckarep/golang-set"
27
28// PhysicalPathTerminationPointPotsUniClassID is the 16-bit ID for the OMCI
29// Managed entity Physical path termination point POTS UNI
30const PhysicalPathTerminationPointPotsUniClassID = ClassID(53) // 0x0035
31
32var physicalpathterminationpointpotsuniBME *ManagedEntityDefinition
33
34// PhysicalPathTerminationPointPotsUni (Class ID: #53 / 0x0035)
35// This ME represents a POTS UNI in the ONU, where a physical path terminates and physical path
36// level functions (analogue telephony) are performed.
37//
38// The ONU automatically creates an instance of this ME per port as follows.
39//
40// o When the ONU has POTS ports built into its factory configuration.
41//
42// o When a cardholder is provisioned to expect a circuit pack of the POTS type.
43//
44// o When a cardholder provisioned for plug-and-play is equipped with a circuit pack of the POTS
45// type. Note that the installation of a plug-and-play card may indicate the presence of POTS ports
46// via equipment ID as well as type, and indeed may cause the ONU to instantiate a port-mapping
47// package that specifies POTS ports.
48//
49// The ONU automatically deletes instances of this ME when a cardholder is neither provisioned to
50// expect a POTS circuit pack, nor is it equipped with a POTS circuit pack.
51//
52// Relationships
53// An instance of this ME is associated with each real or pre-provisioned POTS port. Either a SIP
54// or a VoIP voice CTP links to the POTS UNI. Status is available from a VoIP line status ME, and
55// RTP and call control PM may be collected on this point.
56//
57// Attributes
58// Managed Entity Id
59// This attribute uniquely identifies each instance of this ME. This 2-byte number indicates the
60// physical position of the UNI. The first byte is the slot ID (defined in clause 9.1.5). The
61// second byte is the port ID, with the range 1..255. (R) (mandatory) (2-bytes)
62//
63// Administrative State
64// When the administrative state is set to lock, all user functions of this UNI are blocked, and
65// alarms, TCAs and AVCs for this ME and all dependent MEs are no longer generated. Selection of a
66// default value for this attribute is outside the scope of this Recommendation. (R, W) (mandatory)
67// (1 byte)
68//
69// This attribute shuts down (2), locks (1) and unlocks (0) the functions performed by this ME. If
70// the administrative state is set to shut down while the POTS UNI line state is non-idle, no
71// action is taken until the POTS UNI line state changes to idle, whereupon the administrative
72// state changes to locked. If the administrative state is set to shut down and the POTS UNI line
73// state is already idle, the administrative state is immediately set to locked. In both cases, the
74// transition from shutting down to locked state is signalled with an AVC.
75//
76// Deprecated
77// This attribute is not used and should not be supported. (R,-W) (optional) (2-bytes)
78//
79// Arc
80// See clause A.1.4.3. (R,-W) (optional) (1-byte)
81//
82// Arc Interval
83// See clause A.1.4.3. (R,-W) (optional) (1-byte)
84//
85// Impedance
86// 2 C1=150 nF, R1=750 Ohm, R2=270 Ohm
87//
88// 3 C1=115 nF, R1=820 Ohm, R2=220 Ohm
89//
90// 4 C1=230 nF, R1=1050 Ohm, R2=320 Ohm
91//
92// where C1, R1, and R2 are related as shown in Figure 9.9.1-1. Upon ME instantiation, the ONU sets
93// this attribute to 0. (R,-W) (optional) (1-byte)
94//
95// This attribute specifies the impedance for the POTS UNI. Valid values include the following.
96//
97// 0 600 Ohm
98//
99// 1 900 Ohm
100//
101// The following parameter sets from Annex C of [ETSI TS 101 270-1] are also defined:
102//
103// Transmission Path
104// This attribute allows setting the POTS UNI either to full-time on-hook transmission (0) or part-
105// time on-hook transmission (1). Upon ME instantiation, the ONU sets this attribute to 0. (R,-W)
106// (optional) (1-byte)
107//
108// Rx Gain
109// This attribute specifies a gain value for the received signal in the form of a 2s complement
110// number. Valid values are -120 (12.0-dB) to 60 (+6.0-dB). The direction of the affected signal is
111// in the D to A direction, towards the telephone set. Upon ME instantiation, the ONU sets this
112// attribute to 0. (R, W) (optional) (1 byte)
113//
114// Tx Gain
115// This attribute specifies a gain value for the transmit signal in the form of a 2s complement
116// number. Valid values are -120 (12.0-dB) to 60 (+6.0-dB). The direction of the affected signal is
117// in the A to D direction, away from the telephone set. Upon ME instantiation, the ONU sets this
118// attribute to 0. (R, W) (optional) (1 byte)
119//
120// Operational State
121// This attribute indicates whether the ME is capable of performing its function. Valid values are
122// enabled (0) and disabled (1). (R) (optional) (1-byte)
123//
124// Hook State
125// This attribute indicates the current state of the subscriber line: 0-= on hook, 1-= off hook (R)
126// (optional) (1-byte)
127//
128// Pots Holdover Time
129// This attribute determines the time during which the POTS loop voltage is held up when a LOS or
130// softswitch connectivity is detected (please refer to the following table for description of
131// behaviours).. After the specified time elapses, the ONU drops the loop voltage, and may thereby
132// cause premises intrusion alarm or fire panel circuits to go active. When the ONU ranges
133// successfully on the PON or softswitch connectivity is restored, it restores the POTS loop
134// voltage immediately and resets the timer to zero. The attribute is expressed in seconds. The
135// default value 0 selects the vendor's factory policy. (R,-W) (optional) (2-bytes)
136//
137// Nominal Feed Voltage
138// This attribute indicates the designed nominal feed voltage of the POTS loop. It is an absolute
139// value with resolution 1-V. This attribute does not represent the actual voltage measured on the
140// loop, which is available through the test command. (R,-W) (optional) (1-byte)
141//
142// Loss Of Softswitch
143// This Boolean attribute controls whether the T/R holdover initiation criteria. False disables
144// loss of softswitch connectivity detection as criteria for initiating the POTS holdover timer.
145// True enables loss of softswitch connectivity detection as criteria for initiating the POTS
146// holdover timer. This attribute is optional (if not implemented, the POTS holdover time is
147// triggered on a LOS when POTS holdover is greater than zero). (R,-W) (optional) (1-byte)
148//
149type PhysicalPathTerminationPointPotsUni struct {
150 ManagedEntityDefinition
151 Attributes AttributeValueMap
152}
153
Elia Battiston9bfe1102022-02-03 10:38:03 +0100154// Attribute name constants
155
156const PhysicalPathTerminationPointPotsUni_AdministrativeState = "AdministrativeState"
157const PhysicalPathTerminationPointPotsUni_Deprecated = "Deprecated"
158const PhysicalPathTerminationPointPotsUni_Arc = "Arc"
159const PhysicalPathTerminationPointPotsUni_ArcInterval = "ArcInterval"
160const PhysicalPathTerminationPointPotsUni_Impedance = "Impedance"
161const PhysicalPathTerminationPointPotsUni_TransmissionPath = "TransmissionPath"
162const PhysicalPathTerminationPointPotsUni_RxGain = "RxGain"
163const PhysicalPathTerminationPointPotsUni_TxGain = "TxGain"
164const PhysicalPathTerminationPointPotsUni_OperationalState = "OperationalState"
165const PhysicalPathTerminationPointPotsUni_HookState = "HookState"
166const PhysicalPathTerminationPointPotsUni_PotsHoldoverTime = "PotsHoldoverTime"
167const PhysicalPathTerminationPointPotsUni_NominalFeedVoltage = "NominalFeedVoltage"
168const PhysicalPathTerminationPointPotsUni_LossOfSoftswitch = "LossOfSoftswitch"
169
Andrea Campanella10426e22021-10-15 17:58:04 +0200170func init() {
171 physicalpathterminationpointpotsuniBME = &ManagedEntityDefinition{
172 Name: "PhysicalPathTerminationPointPotsUni",
Elia Battiston9bfe1102022-02-03 10:38:03 +0100173 ClassID: PhysicalPathTerminationPointPotsUniClassID,
Andrea Campanella10426e22021-10-15 17:58:04 +0200174 MessageTypes: mapset.NewSetWith(
175 Get,
176 Set,
177 Test,
178 ),
179 AllowedAttributeMask: 0xfff8,
180 AttributeDefinitions: AttributeDefinitionMap{
Elia Battiston9bfe1102022-02-03 10:38:03 +0100181 0: Uint16Field(ManagedEntityID, PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read), false, false, false, 0),
182 1: ByteField(PhysicalPathTerminationPointPotsUni_AdministrativeState, UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read, Write), true, false, false, 1),
183 2: Uint16Field(PhysicalPathTerminationPointPotsUni_Deprecated, UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, Write), false, true, true, 2),
184 3: ByteField(PhysicalPathTerminationPointPotsUni_Arc, UnsignedIntegerAttributeType, 0x2000, 0, mapset.NewSetWith(Read, Write), true, true, false, 3),
185 4: ByteField(PhysicalPathTerminationPointPotsUni_ArcInterval, UnsignedIntegerAttributeType, 0x1000, 0, mapset.NewSetWith(Read, Write), false, true, false, 4),
186 5: ByteField(PhysicalPathTerminationPointPotsUni_Impedance, UnsignedIntegerAttributeType, 0x0800, 0, mapset.NewSetWith(Read, Write), false, true, false, 5),
187 6: ByteField(PhysicalPathTerminationPointPotsUni_TransmissionPath, UnsignedIntegerAttributeType, 0x0400, 0, mapset.NewSetWith(Read, Write), false, true, false, 6),
188 7: ByteField(PhysicalPathTerminationPointPotsUni_RxGain, UnsignedIntegerAttributeType, 0x0200, 0, mapset.NewSetWith(Read, Write), false, true, false, 7),
189 8: ByteField(PhysicalPathTerminationPointPotsUni_TxGain, UnsignedIntegerAttributeType, 0x0100, 0, mapset.NewSetWith(Read, Write), false, true, false, 8),
190 9: ByteField(PhysicalPathTerminationPointPotsUni_OperationalState, UnsignedIntegerAttributeType, 0x0080, 0, mapset.NewSetWith(Read), true, true, false, 9),
191 10: ByteField(PhysicalPathTerminationPointPotsUni_HookState, UnsignedIntegerAttributeType, 0x0040, 0, mapset.NewSetWith(Read), false, true, false, 10),
192 11: Uint16Field(PhysicalPathTerminationPointPotsUni_PotsHoldoverTime, UnsignedIntegerAttributeType, 0x0020, 0, mapset.NewSetWith(Read, Write), false, true, false, 11),
193 12: ByteField(PhysicalPathTerminationPointPotsUni_NominalFeedVoltage, UnsignedIntegerAttributeType, 0x0010, 0, mapset.NewSetWith(Read, Write), false, true, false, 12),
194 13: ByteField(PhysicalPathTerminationPointPotsUni_LossOfSoftswitch, UnsignedIntegerAttributeType, 0x0008, 0, mapset.NewSetWith(Read, Write), false, true, false, 13),
Andrea Campanella10426e22021-10-15 17:58:04 +0200195 },
196 Access: CreatedByOnu,
197 Support: UnknownSupport,
198 }
199}
200
201// NewPhysicalPathTerminationPointPotsUni (class ID 53) creates the basic
202// Managed Entity definition that is used to validate an ME of this type that
203// is received from or transmitted to the OMCC.
204func NewPhysicalPathTerminationPointPotsUni(params ...ParamData) (*ManagedEntity, OmciErrors) {
205 return NewManagedEntity(*physicalpathterminationpointpotsuniBME, params...)
206}