blob: 9e22a6381309d4fedc9c59831a4578b8921f89e0 [file] [log] [blame]
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -07001/*
2 * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net)
Matteo Scandolof9d43412021-01-12 11:11:34 -08003 * Copyright 2020-present Open Networking Foundation
4
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -07005 * 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
Matteo Scandolof9d43412021-01-12 11:11:34 -08008
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -07009 * http://www.apache.org/licenses/LICENSE-2.0
Matteo Scandolof9d43412021-01-12 11:11:34 -080010
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070011 * 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 */
Matteo Scandolof9d43412021-01-12 11:11:34 -080017 /*
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070018 * 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 */
Matteo Scandolof9d43412021-01-12 11:11:34 -080023
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070024package generated
25
26import "github.com/deckarep/golang-set"
27
Matteo Scandolof9d43412021-01-12 11:11:34 -080028// XdslLineInventoryAndStatusDataPart1ClassID is the 16-bit ID for the OMCI
29// Managed entity xDSL line inventory and status data part 1
30const XdslLineInventoryAndStatusDataPart1ClassID ClassID = ClassID(100)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070031
32var xdsllineinventoryandstatusdatapart1BME *ManagedEntityDefinition
33
34// XdslLineInventoryAndStatusDataPart1 (class ID #100)
35// This ME contains part 1 of the line inventory and status data for an xDSL UNI. The ONU
36// automatically creates or deletes an instance of this ME upon the creation or deletion of a PPTP
37// xDSL UNI part 1.
38//
39// Relationships
40// An instance of this ME is associated with an xDSL UNI.
41//
42// Attributes
43// Managed Entity Id
44// Managed entity ID: This attribute uniquely identifies each instance of this ME. Through an
45// identical ID, this ME is implicitly linked to an instance of the PPTP xDSL UNI part 1. (R)
Matteo Scandolof9d43412021-01-12 11:11:34 -080046// (mandatory) (2-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070047//
48// Xtu_C G.994.1 Vendor Id
Matteo Scandolof9d43412021-01-12 11:11:34 -080049// xTU-C G.994.1 vendor ID: This is the vendor ID as inserted by the xTU-C in the ITUT-G.994.1 CL
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070050// message. It comprises 8 octets, including a country code followed by a (regionally allocated)
Matteo Scandolof9d43412021-01-12 11:11:34 -080051// provider code, as defined in [ITUT-T.35]. (R) (mandatory) (8-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070052//
53// Xtu_R G.994.1 Vendor Id
Matteo Scandolof9d43412021-01-12 11:11:34 -080054// xTU-R G.994.1 vendor ID: This is the vendor ID as inserted by the xTU-R in the ITUT-G.994.1 CLR
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070055// message. It comprises 8 binary octets, with the same format as the xTUC ITUT G.994.1 vendor ID.
Matteo Scandolof9d43412021-01-12 11:11:34 -080056// (R) (mandatory) (8-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070057//
58// Xtu_C System Vendor Id
59// xTU-C system vendor ID: This is the vendor ID as inserted by the xTU-C in the overhead messages
60// of [ITU-T G.992.3] and [ITU-T G.992.4]. It comprises 8 binary octets, with the same format as
Matteo Scandolof9d43412021-01-12 11:11:34 -080061// the xTU-C ITUT-G.994.1 vendor ID. (R) (mandatory) (8-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070062//
63// Xtu_R System Vendor Id
64// xTU-R system vendor ID: This is the vendor ID as inserted by the xTU-R in the embedded
Matteo Scandolof9d43412021-01-12 11:11:34 -080065// operations channel and overhead messages of [ITU-T G.992.3] and [ITUT-G.992.4]. It comprises 8
66// binary octets, with the same format as the xTU-C ITUT-G.994.1 vendor ID. (R) (mandatory)
67// (8-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070068//
69// Xtu_C Version Number
70// xTU-C version number: This is the vendorspecific version number as inserted by the xTUC in the
71// overhead messages of [ITU-T G.992.3] and [ITU-T G.992.4]. It comprises up to 16 binary octets.
Matteo Scandolof9d43412021-01-12 11:11:34 -080072// (R) (mandatory) (16-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070073//
74// Xtu_R Version Number
75// xTU-R version number: This is the version number as inserted by the xTUR in the embedded
76// operations channel of [ITU-T G.992.1] or [ITU-T G.992.2], or the overhead messages of [ITU-T
77// G.992.3], [ITU-T G.992.4], [ITU-T G.992.5] and [ITU-T G.993.2]. The attribute value may be
78// vendor-specific, but is recommended to comprise up to 16 ASCII characters, null-terminated if it
79// is shorter than 16. The string should contain the xTU-R firmware version and the xTU-R model,
80// encoded in that order and separated by a space character: "<xTU-R firmware version><xTU-R
81// model>". It is recognized that legacy xTU-Rs may not support this format. (R) (mandatory)
Matteo Scandolof9d43412021-01-12 11:11:34 -080082// (16-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070083//
84// Xtu_C Serial Number Part 1
85// xTU-C serial number part 1: The vendorspecific serial number inserted by the xTU-C in the
86// overhead messages of [ITU-T G.992.3] and [ITU-T G.992.4] comprises up to 32 ASCII characters,
87// null terminated if it is shorter than 32 characters. This attribute contains the first 16
Matteo Scandolof9d43412021-01-12 11:11:34 -080088// characters. (R) (mandatory) (16-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070089//
90// Xtu_C Serial Number Part 2
91// xTU-C serial number part 2: This attribute contains the second 16 characters of the xTU-C serial
Matteo Scandolof9d43412021-01-12 11:11:34 -080092// number. (R) (mandatory) (16-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070093//
94// Xtu_R Serial Number Part 1
95// xTU-R serial number part 1: The serial number inserted by the xTU-R in the embedded operations
96// channel of [ITU-T G.992.1] or [ITU-T G.992.2], or the overhead messages of [ITU-T G.992.3],
Matteo Scandolof9d43412021-01-12 11:11:34 -080097// [ITU-T G.992.4], [ITU-T G.992.5] and [ITUT-G.993.2], comprises up to 32 ASCII characters,
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -070098// nullterminated if it is shorter than 32. It is recommended that the equipment serial number, the
99// equipment model and the equipment firmware version, encoded in that order and separated by space
100// characters, be contained: "<equipment serial number><equipment model><equipment firmware
101// version>". It is recognized that legacy xTU-Rs may not support this format. This attribute
Matteo Scandolof9d43412021-01-12 11:11:34 -0800102// contains the first 16 characters. (R) (mandatory) (16-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700103//
104// Xtu_R Serial Number Part 2
105// xTU-R serial number part 2: This attribute contains the second 16 characters of the xTU-R serial
Matteo Scandolof9d43412021-01-12 11:11:34 -0800106// number. (R) (mandatory) (16-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700107//
108// Xtu_C Self Test Results
109// xTU-C selftest results: This parameter reports the xTU-C self-test result. It is coded in two
110// fields. The most significant octet is 0 if the self-test passed and 1 if it failed. The three
111// least significant octets are a vendor-discretionary integer that can be interpreted in
Matteo Scandolof9d43412021-01-12 11:11:34 -0800112// combination with [ITU-T G.994.1] and the system vendor ID. (R) (mandatory) (4-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700113//
114// Xtu_R Self Test Results
115// xTU-R selftest results: This parameter defines the xTU-R self-test result. It is coded in two
116// fields. The most significant octet is 0 if the self-test passed and 1 if it failed. The three
117// least significant octets are a vendor-discretionary integer that can be interpreted in
Matteo Scandolof9d43412021-01-12 11:11:34 -0800118// combination with [ITU-T G.994.1] and the system vendor ID. (R) (mandatory) (4-bytes)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700119//
120// Xtu_C Transmission System Capability
Matteo Scandolof9d43412021-01-12 11:11:34 -0800121// NOTE 1 - This attribute is only 7-bytes long. An eighth byte identifying VDSL2 capabilities is
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700122// defined in the VDSL2 line inventory and status data part 1 ME.
123//
124// Xtu_R Transmission System Capability
Matteo Scandolof9d43412021-01-12 11:11:34 -0800125// NOTE 2 - This attribute is only 7-bytes long. An eighth byte identifying VDSL2 capabilities is
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700126// defined in the VDSL2 line inventory and status data part 2 ME.
127//
128// Initialization Success_Failure Cause
Matteo Scandolof9d43412021-01-12 11:11:34 -0800129// (R) (mandatory) (1-byte)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700130//
131type XdslLineInventoryAndStatusDataPart1 struct {
132 ManagedEntityDefinition
133 Attributes AttributeValueMap
134}
135
136func init() {
137 xdsllineinventoryandstatusdatapart1BME = &ManagedEntityDefinition{
138 Name: "XdslLineInventoryAndStatusDataPart1",
139 ClassID: 100,
140 MessageTypes: mapset.NewSetWith(
141 Get,
142 ),
Matteo Scandolof9d43412021-01-12 11:11:34 -0800143 AllowedAttributeMask: 0xfffe,
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700144 AttributeDefinitions: AttributeDefinitionMap{
Matteo Scandolof9d43412021-01-12 11:11:34 -0800145 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read), false, false, false, 0),
146 1: Uint64Field("XtuCG9941VendorId", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read), false, false, false, 1),
147 2: Uint64Field("XtuRG9941VendorId", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read), false, false, false, 2),
148 3: Uint64Field("XtuCSystemVendorId", UnsignedIntegerAttributeType, 0x2000, 0, mapset.NewSetWith(Read), false, false, false, 3),
149 4: Uint64Field("XtuRSystemVendorId", UnsignedIntegerAttributeType, 0x1000, 0, mapset.NewSetWith(Read), false, false, false, 4),
150 5: MultiByteField("XtuCVersionNumber", OctetsAttributeType, 0x0800, 16, toOctets("AAAAAAAAAAAAAAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 5),
151 6: MultiByteField("XtuRVersionNumber", OctetsAttributeType, 0x0400, 16, toOctets("AAAAAAAAAAAAAAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 6),
152 7: MultiByteField("XtuCSerialNumberPart1", OctetsAttributeType, 0x0200, 16, toOctets("AAAAAAAAAAAAAAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 7),
153 8: MultiByteField("XtuCSerialNumberPart2", OctetsAttributeType, 0x0100, 16, toOctets("AAAAAAAAAAAAAAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 8),
154 9: MultiByteField("XtuRSerialNumberPart1", OctetsAttributeType, 0x0080, 16, toOctets("AAAAAAAAAAAAAAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 9),
155 10: MultiByteField("XtuRSerialNumberPart2", OctetsAttributeType, 0x0040, 16, toOctets("AAAAAAAAAAAAAAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 10),
156 11: Uint32Field("XtuCSelfTestResults", UnsignedIntegerAttributeType, 0x0020, 0, mapset.NewSetWith(Read), false, false, false, 11),
157 12: Uint32Field("XtuRSelfTestResults", UnsignedIntegerAttributeType, 0x0010, 0, mapset.NewSetWith(Read), false, false, false, 12),
158 13: MultiByteField("XtuCTransmissionSystemCapability", OctetsAttributeType, 0x0008, 7, toOctets("AAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 13),
159 14: MultiByteField("XtuRTransmissionSystemCapability", OctetsAttributeType, 0x0004, 7, toOctets("AAAAAAAAAA=="), mapset.NewSetWith(Read), false, false, false, 14),
160 15: ByteField("InitializationSuccessFailureCause", UnsignedIntegerAttributeType, 0x0002, 0, mapset.NewSetWith(Read), false, false, false, 15),
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700161 },
Matteo Scandolof9d43412021-01-12 11:11:34 -0800162 Access: CreatedByOnu,
163 Support: UnknownSupport,
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700164 }
165}
166
Matteo Scandolof9d43412021-01-12 11:11:34 -0800167// NewXdslLineInventoryAndStatusDataPart1 (class ID 100) creates the basic
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700168// Managed Entity definition that is used to validate an ME of this type that
Matteo Scandolof9d43412021-01-12 11:11:34 -0800169// is received from or transmitted to the OMCC.
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700170func NewXdslLineInventoryAndStatusDataPart1(params ...ParamData) (*ManagedEntity, OmciErrors) {
Matteo Scandolof9d43412021-01-12 11:11:34 -0800171 return NewManagedEntity(*xdsllineinventoryandstatusdatapart1BME, params...)
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -0700172}