You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@plc4x.apache.org by sr...@apache.org on 2022/05/30 12:26:53 UTC

[plc4x] branch develop updated: feat(bacnet): mapped units to out of service

This is an automated email from the ASF dual-hosted git repository.

sruehl pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/plc4x.git


The following commit(s) were added to refs/heads/develop by this push:
     new 577196469f feat(bacnet): mapped units to out of service
577196469f is described below

commit 577196469f502e1ca1bf47f0b0ac072a64db8d50
Author: Sebastian Rühl <sr...@apache.org>
AuthorDate: Mon May 30 14:26:43 2022 +0200

    feat(bacnet): mapped units to out of service
---
 .../protocols/bacnetip/readwrite/ParserHelper.go   |  12 +-
 .../bacnetip/readwrite/XmlParserHelper.go          |  14 +-
 .../readwrite/model/BACnetConstructedData.go       |   2 +
 .../model/BACnetConstructedDataOutOfService.go     | 211 +++++++++++++++++++++
 ...tEventProrities.go => BACnetEventPriorities.go} |  56 +++---
 .../bacnetip/readwrite/model/BACnetEventSummary.go |  12 +-
 .../plc4x/java/bacnetip/RandomPackagesTest.java    |   4 +-
 .../resources/protocols/bacnetip/bacnetip.mspec    |   8 +-
 8 files changed, 267 insertions(+), 52 deletions(-)

diff --git a/plc4go/protocols/bacnetip/readwrite/ParserHelper.go b/plc4go/protocols/bacnetip/readwrite/ParserHelper.go
index 1fc2789e7b..59a62dd4fa 100644
--- a/plc4go/protocols/bacnetip/readwrite/ParserHelper.go
+++ b/plc4go/protocols/bacnetip/readwrite/ParserHelper.go
@@ -347,12 +347,6 @@ func (m BacnetipParserHelper) Parse(typeName string, arguments []string, io util
 			return nil, errors.Wrap(err, "Error parsing")
 		}
 		return model.BACnetConfirmedServiceRequestParse(io, serviceRequestLength)
-	case "BACnetEventProrities":
-		tagNumber, err := utils.StrToUint8(arguments[0])
-		if err != nil {
-			return nil, errors.Wrap(err, "Error parsing")
-		}
-		return model.BACnetEventProritiesParse(io, tagNumber)
 	case "ListOfCovNotificationsList":
 		tagNumber, err := utils.StrToUint8(arguments[0])
 		if err != nil {
@@ -792,6 +786,12 @@ func (m BacnetipParserHelper) Parse(typeName string, arguments []string, io util
 		}
 		tagClass := model.TagClassByName(arguments[1])
 		return model.BACnetBinaryPVTaggedParse(io, tagNumber, tagClass)
+	case "BACnetEventPriorities":
+		tagNumber, err := utils.StrToUint8(arguments[0])
+		if err != nil {
+			return nil, errors.Wrap(err, "Error parsing")
+		}
+		return model.BACnetEventPrioritiesParse(io, tagNumber)
 	case "BACnetConfirmedServiceRequestGetEnrollmentSummaryEventStateFilterTagged":
 		tagNumber, err := utils.StrToUint8(arguments[0])
 		if err != nil {
diff --git a/plc4go/protocols/bacnetip/readwrite/XmlParserHelper.go b/plc4go/protocols/bacnetip/readwrite/XmlParserHelper.go
index 93586eaff1..e4303572ce 100644
--- a/plc4go/protocols/bacnetip/readwrite/XmlParserHelper.go
+++ b/plc4go/protocols/bacnetip/readwrite/XmlParserHelper.go
@@ -401,13 +401,6 @@ func (m BacnetipXmlParserHelper) Parse(typeName string, xmlString string, parser
 		}
 		serviceRequestLength := uint16(parsedUint0)
 		return model.BACnetConfirmedServiceRequestParse(utils.NewXmlReadBuffer(strings.NewReader(xmlString)), serviceRequestLength)
-	case "BACnetEventProrities":
-		parsedUint0, err := strconv.ParseUint(parserArguments[0], 10, 8)
-		if err != nil {
-			return nil, err
-		}
-		tagNumber := uint8(parsedUint0)
-		return model.BACnetEventProritiesParse(utils.NewXmlReadBuffer(strings.NewReader(xmlString)), tagNumber)
 	case "ListOfCovNotificationsList":
 		parsedUint0, err := strconv.ParseUint(parserArguments[0], 10, 8)
 		if err != nil {
@@ -905,6 +898,13 @@ func (m BacnetipXmlParserHelper) Parse(typeName string, xmlString string, parser
 		tagNumber := uint8(parsedUint0)
 		tagClass := model.TagClassByName(parserArguments[1])
 		return model.BACnetBinaryPVTaggedParse(utils.NewXmlReadBuffer(strings.NewReader(xmlString)), tagNumber, tagClass)
+	case "BACnetEventPriorities":
+		parsedUint0, err := strconv.ParseUint(parserArguments[0], 10, 8)
+		if err != nil {
+			return nil, err
+		}
+		tagNumber := uint8(parsedUint0)
+		return model.BACnetEventPrioritiesParse(utils.NewXmlReadBuffer(strings.NewReader(xmlString)), tagNumber)
 	case "BACnetConfirmedServiceRequestGetEnrollmentSummaryEventStateFilterTagged":
 		parsedUint0, err := strconv.ParseUint(parserArguments[0], 10, 8)
 		if err != nil {
diff --git a/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedData.go b/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedData.go
index e8643f5534..9f00d7b53f 100644
--- a/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedData.go
+++ b/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedData.go
@@ -310,6 +310,8 @@ func BACnetConstructedDataParse(readBuffer utils.ReadBuffer, tagNumber uint8, ob
 		_child, typeSwitchError = BACnetConstructedDataListOfObjectPropertyReferencesParse(readBuffer, tagNumber, objectType, propertyIdentifierArgument)
 	case true && propertyIdentifierArgument == BACnetPropertyIdentifier_MEMBER_OF: // BACnetConstructedDataMemberOf
 		_child, typeSwitchError = BACnetConstructedDataMemberOfParse(readBuffer, tagNumber, objectType, propertyIdentifierArgument)
+	case true && propertyIdentifierArgument == BACnetPropertyIdentifier_OUT_OF_SERVICE: // BACnetConstructedDataOutOfService
+		_child, typeSwitchError = BACnetConstructedDataOutOfServiceParse(readBuffer, tagNumber, objectType, propertyIdentifierArgument)
 	case true && propertyIdentifierArgument == BACnetPropertyIdentifier_OUTPUT_UNITS: // BACnetConstructedDataOutputUnits
 		_child, typeSwitchError = BACnetConstructedDataOutputUnitsParse(readBuffer, tagNumber, objectType, propertyIdentifierArgument)
 	case true && propertyIdentifierArgument == BACnetPropertyIdentifier_PROPORTIONAL_CONSTANT_UNITS: // BACnetConstructedDataProportionalConstantUnits
diff --git a/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedDataOutOfService.go b/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedDataOutOfService.go
new file mode 100644
index 0000000000..0e38d1c776
--- /dev/null
+++ b/plc4go/protocols/bacnetip/readwrite/model/BACnetConstructedDataOutOfService.go
@@ -0,0 +1,211 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package model
+
+import (
+	"github.com/apache/plc4x/plc4go/internal/spi/utils"
+	"github.com/pkg/errors"
+)
+
+// Code generated by code-generation. DO NOT EDIT.
+
+// BACnetConstructedDataOutOfService is the data-structure of this message
+type BACnetConstructedDataOutOfService struct {
+	*BACnetConstructedData
+	OutOfService *BACnetApplicationTagBoolean
+
+	// Arguments.
+	TagNumber uint8
+}
+
+// IBACnetConstructedDataOutOfService is the corresponding interface of BACnetConstructedDataOutOfService
+type IBACnetConstructedDataOutOfService interface {
+	IBACnetConstructedData
+	// GetOutOfService returns OutOfService (property field)
+	GetOutOfService() *BACnetApplicationTagBoolean
+	// GetLengthInBytes returns the length in bytes
+	GetLengthInBytes() uint16
+	// GetLengthInBits returns the length in bits
+	GetLengthInBits() uint16
+	// Serialize serializes this type
+	Serialize(writeBuffer utils.WriteBuffer) error
+}
+
+///////////////////////////////////////////////////////////
+///////////////////////////////////////////////////////////
+/////////////////////// Accessors for discriminator values.
+///////////////////////
+
+func (m *BACnetConstructedDataOutOfService) GetObjectType() BACnetObjectType {
+	return 0
+}
+
+func (m *BACnetConstructedDataOutOfService) GetPropertyIdentifierArgument() BACnetPropertyIdentifier {
+	return BACnetPropertyIdentifier_OUT_OF_SERVICE
+}
+
+///////////////////////
+///////////////////////
+///////////////////////////////////////////////////////////
+///////////////////////////////////////////////////////////
+
+func (m *BACnetConstructedDataOutOfService) InitializeParent(parent *BACnetConstructedData, openingTag *BACnetOpeningTag, closingTag *BACnetClosingTag) {
+	m.BACnetConstructedData.OpeningTag = openingTag
+	m.BACnetConstructedData.ClosingTag = closingTag
+}
+
+func (m *BACnetConstructedDataOutOfService) GetParent() *BACnetConstructedData {
+	return m.BACnetConstructedData
+}
+
+///////////////////////////////////////////////////////////
+///////////////////////////////////////////////////////////
+/////////////////////// Accessors for property fields.
+///////////////////////
+
+func (m *BACnetConstructedDataOutOfService) GetOutOfService() *BACnetApplicationTagBoolean {
+	return m.OutOfService
+}
+
+///////////////////////
+///////////////////////
+///////////////////////////////////////////////////////////
+///////////////////////////////////////////////////////////
+
+// NewBACnetConstructedDataOutOfService factory function for BACnetConstructedDataOutOfService
+func NewBACnetConstructedDataOutOfService(outOfService *BACnetApplicationTagBoolean, openingTag *BACnetOpeningTag, closingTag *BACnetClosingTag, tagNumber uint8) *BACnetConstructedDataOutOfService {
+	_result := &BACnetConstructedDataOutOfService{
+		OutOfService:          outOfService,
+		BACnetConstructedData: NewBACnetConstructedData(openingTag, closingTag, tagNumber),
+	}
+	_result.Child = _result
+	return _result
+}
+
+func CastBACnetConstructedDataOutOfService(structType interface{}) *BACnetConstructedDataOutOfService {
+	if casted, ok := structType.(BACnetConstructedDataOutOfService); ok {
+		return &casted
+	}
+	if casted, ok := structType.(*BACnetConstructedDataOutOfService); ok {
+		return casted
+	}
+	if casted, ok := structType.(BACnetConstructedData); ok {
+		return CastBACnetConstructedDataOutOfService(casted.Child)
+	}
+	if casted, ok := structType.(*BACnetConstructedData); ok {
+		return CastBACnetConstructedDataOutOfService(casted.Child)
+	}
+	return nil
+}
+
+func (m *BACnetConstructedDataOutOfService) GetTypeName() string {
+	return "BACnetConstructedDataOutOfService"
+}
+
+func (m *BACnetConstructedDataOutOfService) GetLengthInBits() uint16 {
+	return m.GetLengthInBitsConditional(false)
+}
+
+func (m *BACnetConstructedDataOutOfService) GetLengthInBitsConditional(lastItem bool) uint16 {
+	lengthInBits := uint16(m.GetParentLengthInBits())
+
+	// Simple field (outOfService)
+	lengthInBits += m.OutOfService.GetLengthInBits()
+
+	return lengthInBits
+}
+
+func (m *BACnetConstructedDataOutOfService) GetLengthInBytes() uint16 {
+	return m.GetLengthInBits() / 8
+}
+
+func BACnetConstructedDataOutOfServiceParse(readBuffer utils.ReadBuffer, tagNumber uint8, objectType BACnetObjectType, propertyIdentifierArgument BACnetPropertyIdentifier) (*BACnetConstructedDataOutOfService, error) {
+	positionAware := readBuffer
+	_ = positionAware
+	if pullErr := readBuffer.PullContext("BACnetConstructedDataOutOfService"); pullErr != nil {
+		return nil, pullErr
+	}
+	currentPos := positionAware.GetPos()
+	_ = currentPos
+
+	// Simple Field (outOfService)
+	if pullErr := readBuffer.PullContext("outOfService"); pullErr != nil {
+		return nil, pullErr
+	}
+	_outOfService, _outOfServiceErr := BACnetApplicationTagParse(readBuffer)
+	if _outOfServiceErr != nil {
+		return nil, errors.Wrap(_outOfServiceErr, "Error parsing 'outOfService' field")
+	}
+	outOfService := CastBACnetApplicationTagBoolean(_outOfService)
+	if closeErr := readBuffer.CloseContext("outOfService"); closeErr != nil {
+		return nil, closeErr
+	}
+
+	if closeErr := readBuffer.CloseContext("BACnetConstructedDataOutOfService"); closeErr != nil {
+		return nil, closeErr
+	}
+
+	// Create a partially initialized instance
+	_child := &BACnetConstructedDataOutOfService{
+		OutOfService:          CastBACnetApplicationTagBoolean(outOfService),
+		BACnetConstructedData: &BACnetConstructedData{},
+	}
+	_child.BACnetConstructedData.Child = _child
+	return _child, nil
+}
+
+func (m *BACnetConstructedDataOutOfService) Serialize(writeBuffer utils.WriteBuffer) error {
+	positionAware := writeBuffer
+	_ = positionAware
+	ser := func() error {
+		if pushErr := writeBuffer.PushContext("BACnetConstructedDataOutOfService"); pushErr != nil {
+			return pushErr
+		}
+
+		// Simple Field (outOfService)
+		if pushErr := writeBuffer.PushContext("outOfService"); pushErr != nil {
+			return pushErr
+		}
+		_outOfServiceErr := m.OutOfService.Serialize(writeBuffer)
+		if popErr := writeBuffer.PopContext("outOfService"); popErr != nil {
+			return popErr
+		}
+		if _outOfServiceErr != nil {
+			return errors.Wrap(_outOfServiceErr, "Error serializing 'outOfService' field")
+		}
+
+		if popErr := writeBuffer.PopContext("BACnetConstructedDataOutOfService"); popErr != nil {
+			return popErr
+		}
+		return nil
+	}
+	return m.SerializeParent(writeBuffer, m, ser)
+}
+
+func (m *BACnetConstructedDataOutOfService) String() string {
+	if m == nil {
+		return "<nil>"
+	}
+	buffer := utils.NewBoxedWriteBufferWithOptions(true, true)
+	if err := m.Serialize(buffer); err != nil {
+		return err.Error()
+	}
+	return buffer.GetBox().String()
+}
diff --git a/plc4go/protocols/bacnetip/readwrite/model/BACnetEventProrities.go b/plc4go/protocols/bacnetip/readwrite/model/BACnetEventPriorities.go
similarity index 77%
rename from plc4go/protocols/bacnetip/readwrite/model/BACnetEventProrities.go
rename to plc4go/protocols/bacnetip/readwrite/model/BACnetEventPriorities.go
index 49dd4a57ec..252b8b5ca5 100644
--- a/plc4go/protocols/bacnetip/readwrite/model/BACnetEventProrities.go
+++ b/plc4go/protocols/bacnetip/readwrite/model/BACnetEventPriorities.go
@@ -26,8 +26,8 @@ import (
 
 // Code generated by code-generation. DO NOT EDIT.
 
-// BACnetEventProrities is the data-structure of this message
-type BACnetEventProrities struct {
+// BACnetEventPriorities is the data-structure of this message
+type BACnetEventPriorities struct {
 	OpeningTag  *BACnetOpeningTag
 	ToOffnormal *BACnetApplicationTagUnsignedInteger
 	ToFault     *BACnetApplicationTagUnsignedInteger
@@ -38,8 +38,8 @@ type BACnetEventProrities struct {
 	TagNumber uint8
 }
 
-// IBACnetEventProrities is the corresponding interface of BACnetEventProrities
-type IBACnetEventProrities interface {
+// IBACnetEventPriorities is the corresponding interface of BACnetEventPriorities
+type IBACnetEventPriorities interface {
 	// GetOpeningTag returns OpeningTag (property field)
 	GetOpeningTag() *BACnetOpeningTag
 	// GetToOffnormal returns ToOffnormal (property field)
@@ -63,23 +63,23 @@ type IBACnetEventProrities interface {
 /////////////////////// Accessors for property fields.
 ///////////////////////
 
-func (m *BACnetEventProrities) GetOpeningTag() *BACnetOpeningTag {
+func (m *BACnetEventPriorities) GetOpeningTag() *BACnetOpeningTag {
 	return m.OpeningTag
 }
 
-func (m *BACnetEventProrities) GetToOffnormal() *BACnetApplicationTagUnsignedInteger {
+func (m *BACnetEventPriorities) GetToOffnormal() *BACnetApplicationTagUnsignedInteger {
 	return m.ToOffnormal
 }
 
-func (m *BACnetEventProrities) GetToFault() *BACnetApplicationTagUnsignedInteger {
+func (m *BACnetEventPriorities) GetToFault() *BACnetApplicationTagUnsignedInteger {
 	return m.ToFault
 }
 
-func (m *BACnetEventProrities) GetToNormal() *BACnetApplicationTagUnsignedInteger {
+func (m *BACnetEventPriorities) GetToNormal() *BACnetApplicationTagUnsignedInteger {
 	return m.ToNormal
 }
 
-func (m *BACnetEventProrities) GetClosingTag() *BACnetClosingTag {
+func (m *BACnetEventPriorities) GetClosingTag() *BACnetClosingTag {
 	return m.ClosingTag
 }
 
@@ -88,30 +88,30 @@ func (m *BACnetEventProrities) GetClosingTag() *BACnetClosingTag {
 ///////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////
 
-// NewBACnetEventProrities factory function for BACnetEventProrities
-func NewBACnetEventProrities(openingTag *BACnetOpeningTag, toOffnormal *BACnetApplicationTagUnsignedInteger, toFault *BACnetApplicationTagUnsignedInteger, toNormal *BACnetApplicationTagUnsignedInteger, closingTag *BACnetClosingTag, tagNumber uint8) *BACnetEventProrities {
-	return &BACnetEventProrities{OpeningTag: openingTag, ToOffnormal: toOffnormal, ToFault: toFault, ToNormal: toNormal, ClosingTag: closingTag, TagNumber: tagNumber}
+// NewBACnetEventPriorities factory function for BACnetEventPriorities
+func NewBACnetEventPriorities(openingTag *BACnetOpeningTag, toOffnormal *BACnetApplicationTagUnsignedInteger, toFault *BACnetApplicationTagUnsignedInteger, toNormal *BACnetApplicationTagUnsignedInteger, closingTag *BACnetClosingTag, tagNumber uint8) *BACnetEventPriorities {
+	return &BACnetEventPriorities{OpeningTag: openingTag, ToOffnormal: toOffnormal, ToFault: toFault, ToNormal: toNormal, ClosingTag: closingTag, TagNumber: tagNumber}
 }
 
-func CastBACnetEventProrities(structType interface{}) *BACnetEventProrities {
-	if casted, ok := structType.(BACnetEventProrities); ok {
+func CastBACnetEventPriorities(structType interface{}) *BACnetEventPriorities {
+	if casted, ok := structType.(BACnetEventPriorities); ok {
 		return &casted
 	}
-	if casted, ok := structType.(*BACnetEventProrities); ok {
+	if casted, ok := structType.(*BACnetEventPriorities); ok {
 		return casted
 	}
 	return nil
 }
 
-func (m *BACnetEventProrities) GetTypeName() string {
-	return "BACnetEventProrities"
+func (m *BACnetEventPriorities) GetTypeName() string {
+	return "BACnetEventPriorities"
 }
 
-func (m *BACnetEventProrities) GetLengthInBits() uint16 {
+func (m *BACnetEventPriorities) GetLengthInBits() uint16 {
 	return m.GetLengthInBitsConditional(false)
 }
 
-func (m *BACnetEventProrities) GetLengthInBitsConditional(lastItem bool) uint16 {
+func (m *BACnetEventPriorities) GetLengthInBitsConditional(lastItem bool) uint16 {
 	lengthInBits := uint16(0)
 
 	// Simple field (openingTag)
@@ -132,14 +132,14 @@ func (m *BACnetEventProrities) GetLengthInBitsConditional(lastItem bool) uint16
 	return lengthInBits
 }
 
-func (m *BACnetEventProrities) GetLengthInBytes() uint16 {
+func (m *BACnetEventPriorities) GetLengthInBytes() uint16 {
 	return m.GetLengthInBits() / 8
 }
 
-func BACnetEventProritiesParse(readBuffer utils.ReadBuffer, tagNumber uint8) (*BACnetEventProrities, error) {
+func BACnetEventPrioritiesParse(readBuffer utils.ReadBuffer, tagNumber uint8) (*BACnetEventPriorities, error) {
 	positionAware := readBuffer
 	_ = positionAware
-	if pullErr := readBuffer.PullContext("BACnetEventProrities"); pullErr != nil {
+	if pullErr := readBuffer.PullContext("BACnetEventPriorities"); pullErr != nil {
 		return nil, pullErr
 	}
 	currentPos := positionAware.GetPos()
@@ -210,18 +210,18 @@ func BACnetEventProritiesParse(readBuffer utils.ReadBuffer, tagNumber uint8) (*B
 		return nil, closeErr
 	}
 
-	if closeErr := readBuffer.CloseContext("BACnetEventProrities"); closeErr != nil {
+	if closeErr := readBuffer.CloseContext("BACnetEventPriorities"); closeErr != nil {
 		return nil, closeErr
 	}
 
 	// Create the instance
-	return NewBACnetEventProrities(openingTag, toOffnormal, toFault, toNormal, closingTag, tagNumber), nil
+	return NewBACnetEventPriorities(openingTag, toOffnormal, toFault, toNormal, closingTag, tagNumber), nil
 }
 
-func (m *BACnetEventProrities) Serialize(writeBuffer utils.WriteBuffer) error {
+func (m *BACnetEventPriorities) Serialize(writeBuffer utils.WriteBuffer) error {
 	positionAware := writeBuffer
 	_ = positionAware
-	if pushErr := writeBuffer.PushContext("BACnetEventProrities"); pushErr != nil {
+	if pushErr := writeBuffer.PushContext("BACnetEventPriorities"); pushErr != nil {
 		return pushErr
 	}
 
@@ -285,13 +285,13 @@ func (m *BACnetEventProrities) Serialize(writeBuffer utils.WriteBuffer) error {
 		return errors.Wrap(_closingTagErr, "Error serializing 'closingTag' field")
 	}
 
-	if popErr := writeBuffer.PopContext("BACnetEventProrities"); popErr != nil {
+	if popErr := writeBuffer.PopContext("BACnetEventPriorities"); popErr != nil {
 		return popErr
 	}
 	return nil
 }
 
-func (m *BACnetEventProrities) String() string {
+func (m *BACnetEventPriorities) String() string {
 	if m == nil {
 		return "<nil>"
 	}
diff --git a/plc4go/protocols/bacnetip/readwrite/model/BACnetEventSummary.go b/plc4go/protocols/bacnetip/readwrite/model/BACnetEventSummary.go
index df12df4da8..2fe6c8bb2d 100644
--- a/plc4go/protocols/bacnetip/readwrite/model/BACnetEventSummary.go
+++ b/plc4go/protocols/bacnetip/readwrite/model/BACnetEventSummary.go
@@ -34,7 +34,7 @@ type BACnetEventSummary struct {
 	EventTimestamps         *BACnetEventTimestamps
 	NotifyType              *BACnetNotifyTypeTagged
 	EventEnable             *BACnetEventTransitionBits
-	EventPriorities         *BACnetEventProrities
+	EventPriorities         *BACnetEventPriorities
 }
 
 // IBACnetEventSummary is the corresponding interface of BACnetEventSummary
@@ -52,7 +52,7 @@ type IBACnetEventSummary interface {
 	// GetEventEnable returns EventEnable (property field)
 	GetEventEnable() *BACnetEventTransitionBits
 	// GetEventPriorities returns EventPriorities (property field)
-	GetEventPriorities() *BACnetEventProrities
+	GetEventPriorities() *BACnetEventPriorities
 	// GetLengthInBytes returns the length in bytes
 	GetLengthInBytes() uint16
 	// GetLengthInBits returns the length in bits
@@ -90,7 +90,7 @@ func (m *BACnetEventSummary) GetEventEnable() *BACnetEventTransitionBits {
 	return m.EventEnable
 }
 
-func (m *BACnetEventSummary) GetEventPriorities() *BACnetEventProrities {
+func (m *BACnetEventSummary) GetEventPriorities() *BACnetEventPriorities {
 	return m.EventPriorities
 }
 
@@ -100,7 +100,7 @@ func (m *BACnetEventSummary) GetEventPriorities() *BACnetEventProrities {
 ///////////////////////////////////////////////////////////
 
 // NewBACnetEventSummary factory function for BACnetEventSummary
-func NewBACnetEventSummary(objectIdentifier *BACnetContextTagObjectIdentifier, eventState *BACnetEventStateTagged, acknowledgedTransitions *BACnetEventTransitionBits, eventTimestamps *BACnetEventTimestamps, notifyType *BACnetNotifyTypeTagged, eventEnable *BACnetEventTransitionBits, eventPriorities *BACnetEventProrities) *BACnetEventSummary {
+func NewBACnetEventSummary(objectIdentifier *BACnetContextTagObjectIdentifier, eventState *BACnetEventStateTagged, acknowledgedTransitions *BACnetEventTransitionBits, eventTimestamps *BACnetEventTimestamps, notifyType *BACnetNotifyTypeTagged, eventEnable *BACnetEventTransitionBits, eventPriorities *BACnetEventPriorities) *BACnetEventSummary {
 	return &BACnetEventSummary{ObjectIdentifier: objectIdentifier, EventState: eventState, AcknowledgedTransitions: acknowledgedTransitions, EventTimestamps: eventTimestamps, NotifyType: notifyType, EventEnable: eventEnable, EventPriorities: eventPriorities}
 }
 
@@ -244,11 +244,11 @@ func BACnetEventSummaryParse(readBuffer utils.ReadBuffer) (*BACnetEventSummary,
 	if pullErr := readBuffer.PullContext("eventPriorities"); pullErr != nil {
 		return nil, pullErr
 	}
-	_eventPriorities, _eventPrioritiesErr := BACnetEventProritiesParse(readBuffer, uint8(uint8(6)))
+	_eventPriorities, _eventPrioritiesErr := BACnetEventPrioritiesParse(readBuffer, uint8(uint8(6)))
 	if _eventPrioritiesErr != nil {
 		return nil, errors.Wrap(_eventPrioritiesErr, "Error parsing 'eventPriorities' field")
 	}
-	eventPriorities := CastBACnetEventProrities(_eventPriorities)
+	eventPriorities := CastBACnetEventPriorities(_eventPriorities)
 	if closeErr := readBuffer.CloseContext("eventPriorities"); closeErr != nil {
 		return nil, closeErr
 	}
diff --git a/plc4j/drivers/bacnet/src/test/java/org/apache/plc4x/java/bacnetip/RandomPackagesTest.java b/plc4j/drivers/bacnet/src/test/java/org/apache/plc4x/java/bacnetip/RandomPackagesTest.java
index 9e0238c8f0..9e7b716d7e 100644
--- a/plc4j/drivers/bacnet/src/test/java/org/apache/plc4x/java/bacnetip/RandomPackagesTest.java
+++ b/plc4j/drivers/bacnet/src/test/java/org/apache/plc4x/java/bacnetip/RandomPackagesTest.java
@@ -1224,8 +1224,8 @@ public class RandomPackagesTest {
                         {
                             BACnetPropertyValue baCnetPropertyValue = baCnetNotificationParametersComplexEventType.getListOfValues().getData().get(6);
                             assertEquals(BACnetPropertyIdentifier.UNITS, baCnetPropertyValue.getPropertyIdentifier().getValue());
-                            BACnetApplicationTagEnumerated baCnetApplicationTagEnumerated = (BACnetApplicationTagEnumerated) ((BACnetConstructedDataUnspecified) baCnetPropertyValue.getPropertyValue().getConstructedData()).getData().get(0).getApplicationTag();
-                            assertEquals(64, baCnetApplicationTagEnumerated.getActualValue());
+                            BACnetConstructedDataUnits baCnetConstructedDataUnits = (BACnetConstructedDataUnits) ((BACnetConstructedDataUnits) baCnetPropertyValue.getPropertyValue().getConstructedData());
+                            assertEquals(BACnetEngineeringUnits.DEGREES_FAHRENHEIT, baCnetConstructedDataUnits.getUnits().getValue());
                         }
                         {
                             BACnetPropertyValue baCnetPropertyValue = baCnetNotificationParametersComplexEventType.getListOfValues().getData().get(7);
diff --git a/protocols/bacnetip/src/main/resources/protocols/bacnetip/bacnetip.mspec b/protocols/bacnetip/src/main/resources/protocols/bacnetip/bacnetip.mspec
index 2a9b3cd0ba..9c9e8f6724 100644
--- a/protocols/bacnetip/src/main/resources/protocols/bacnetip/bacnetip.mspec
+++ b/protocols/bacnetip/src/main/resources/protocols/bacnetip/bacnetip.mspec
@@ -1057,7 +1057,7 @@
                     notifyType                      ]
     [simple   BACnetEventTransitionBits('5')
                     eventEnable                     ]
-    [simple   BACnetEventProrities('6')
+    [simple   BACnetEventPriorities('6')
                     eventPriorities                 ]
 ]
 
@@ -1076,7 +1076,7 @@
     ]
 ]
 
-[type BACnetEventProrities(uint 8 tagNumber)
+[type BACnetEventPriorities(uint 8 tagNumber)
     [simple  BACnetOpeningTag('tagNumber')
                     openingTag
     ]
@@ -2790,7 +2790,9 @@
         //[*, 'OPERATION_DIRECTION'                     BACnetConstructedDataOperationDirection [validation    '1 == 2'    "TODO: implement me OPERATION_DIRECTION BACnetConstructedDataOperationDirection"]]
         //[*, 'OPERATION_EXPECTED'                      BACnetConstructedDataOperationExpected [validation    '1 == 2'    "TODO: implement me OPERATION_EXPECTED BACnetConstructedDataOperationExpected"]]
         //[*, 'OPTIONAL'                                BACnetConstructedDataOptional [validation    '1 == 2'    "TODO: implement me OPTIONAL BACnetConstructedDataOptional"]]
-        //[*, 'OUT_OF_SERVICE'                          BACnetConstructedDataOutOfService [validation    '1 == 2'    "TODO: implement me OUT_OF_SERVICE BACnetConstructedDataOutOfService"]]
+        [*, 'OUT_OF_SERVICE'                          BACnetConstructedDataOutOfService
+            [simple   BACnetApplicationTagBoolean  outOfService         ]
+        ]
         [*, 'OUTPUT_UNITS'                            BACnetConstructedDataOutputUnits
           [simple   BACnetEngineeringUnitsTagged('0', 'TagClass.APPLICATION_TAGS') units                           ]