bacnetip

package
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2026 License: BSD-3-Clause, GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BVLCResult                            = 0x00
	BVLCWriteBroadcastDistributionTable   = 0x01
	BVLCReadBroadcastDistributionTable    = 0x02
	BVLCReadBroadcastDistributionTableAck = 0x03
	BVLCForwardedNPDU                     = 0x04
	BVLCRegisterForeignDevice             = 0x05
	BVLCReadForeignDeviceTable            = 0x06
	BVLCReadForeignDeviceTableAck         = 0x07
	BVLCDeleteForeignDeviceTableEntry     = 0x08
	BVLCDistributeBroadcastToNetwork      = 0x09
	BVLCOriginalUnicastNPDU               = 0x0A
	BVLCOriginalBroadcastNPDU             = 0x0B
	BVLCSecureBVLL                        = 0x0C
)

BVLC Function codes

View Source
const (
	APDUConfirmedRequest   = 0
	APDUUnconfirmedRequest = 1
	APDUSimpleAck          = 2
	APDUComplexAck         = 3
	APDUSegmentAck         = 4
	APDUError              = 5
	APDUReject             = 6
	APDUAbort              = 7
)

APDU Types (Application Protocol Data Unit)

View Source
const (
	// Alarm and Event Services
	ServiceAcknowledgeAlarm           = 0
	ServiceConfirmedCOVNotification   = 1
	ServiceConfirmedEventNotification = 2
	ServiceGetAlarmSummary            = 3
	ServiceGetEnrollmentSummary       = 4
	ServiceSubscribeCOV               = 5
	ServiceSubscribeCOVProperty       = 28
	ServiceLifeSafetyOperation        = 27

	// File Services
	ServiceAtomicReadFile  = 6
	ServiceAtomicWriteFile = 7

	// Object Access Services
	ServiceAddListElement          = 8
	ServiceRemoveListElement       = 9
	ServiceCreateObject            = 10
	ServiceDeleteObject            = 11
	ServiceReadProperty            = 12
	ServiceReadPropertyConditional = 13
	ServiceReadPropertyMultiple    = 14
	ServiceReadRange               = 26
	ServiceWriteProperty           = 15
	ServiceWritePropertyMultiple   = 16

	// Remote Device Management Services
	ServiceDeviceCommunicationControl = 17
	ServiceConfirmedPrivateTransfer   = 18
	ServiceConfirmedTextMessage       = 19
	ServiceReinitializeDevice         = 20

	// Virtual Terminal Services
	ServiceVTOpen  = 21
	ServiceVTClose = 22
	ServiceVTData  = 23
)

Confirmed Service Choices

View Source
const (
	ServiceIAm                                = 0
	ServiceIHave                              = 1
	ServiceUnconfirmedCOVNotification         = 2
	ServiceUnconfirmedEventNotification       = 3
	ServiceUnconfirmedPrivateTransfer         = 4
	ServiceUnconfirmedTextMessage             = 5
	ServiceTimeSynchronization                = 6
	ServiceWhoHas                             = 7
	ServiceWhoIs                              = 8
	ServiceUTCTimeSynchronization             = 9
	ServiceWriteGroup                         = 10
	ServiceUnconfirmedCOVNotificationMultiple = 11
)

Unconfirmed Service Choices

View Source
const (
	NetworkWhoIsRouterToNetwork          = 0x00
	NetworkIAmRouterToNetwork            = 0x01
	NetworkICouldBeRouterToNetwork       = 0x02
	NetworkRejectMessageToNetwork        = 0x03
	NetworkRouterBusyToNetwork           = 0x04
	NetworkRouterAvailableToNetwork      = 0x05
	NetworkInitRouteTable                = 0x06
	NetworkInitRouteTableAck             = 0x07
	NetworkEstablishConnectionToNetwork  = 0x08
	NetworkDisconnectConnectionToNetwork = 0x09
	NetworkWhatIsNetworkNumber           = 0x12
	NetworkNetworkNumberIs               = 0x13
)

Network Layer Message Types

View Source
const (
	ObjectAnalogInput           = 0
	ObjectAnalogOutput          = 1
	ObjectAnalogValue           = 2
	ObjectBinaryInput           = 3
	ObjectBinaryOutput          = 4
	ObjectBinaryValue           = 5
	ObjectCalendar              = 6
	ObjectCommand               = 7
	ObjectDevice                = 8
	ObjectEventEnrollment       = 9
	ObjectFile                  = 10
	ObjectGroup                 = 11
	ObjectLoop                  = 12
	ObjectMultiStateInput       = 13
	ObjectMultiStateOutput      = 14
	ObjectNotificationClass     = 15
	ObjectProgram               = 16
	ObjectSchedule              = 17
	ObjectAveraging             = 18
	ObjectMultiStateValue       = 19
	ObjectTrendLog              = 20
	ObjectLifeSafetyPoint       = 21
	ObjectLifeSafetyZone        = 22
	ObjectAccumulator           = 23
	ObjectPulseConverter        = 24
	ObjectEventLog              = 25
	ObjectGlobalGroup           = 26
	ObjectTrendLogMultiple      = 27
	ObjectLoadControl           = 28
	ObjectStructuredView        = 29
	ObjectAccessDoor            = 30
	ObjectAccessCredential      = 32
	ObjectAccessPoint           = 33
	ObjectAccessRights          = 34
	ObjectAccessUser            = 35
	ObjectAccessZone            = 36
	ObjectCredentialDataInput   = 37
	ObjectNetworkSecurity       = 38
	ObjectBitstringValue        = 39
	ObjectCharacterStringValue  = 40
	ObjectDatePatternValue      = 41
	ObjectDateValue             = 42
	ObjectDateTimePatternValue  = 43
	ObjectDateTimeValue         = 44
	ObjectIntegerValue          = 45
	ObjectLargeAnalogValue      = 46
	ObjectOctetStringValue      = 47
	ObjectPositiveIntegerValue  = 48
	ObjectTimePatternValue      = 49
	ObjectTimeValue             = 50
	ObjectNotificationForwarder = 51
	ObjectAlertEnrollment       = 52
	ObjectChannel               = 53
	ObjectLightingOutput        = 54
)

Object Types

Variables

View Source
var Decoder = &decoder.StreamDecoder{
	Type:        types.Type_NC_BACnetIP,
	Name:        serviceBACnetIP,
	Description: "BACnet/IP (Building Automation and Control Networks over IP) for building automation systems",
	PostInit: func(d *decoder.StreamDecoder) error {
		var err error
		bacnetipLog, _, err = logging.InitZapLogger(
			decoderconfig.Instance.Out,
			"bacnetip",
			decoderconfig.Instance.Debug,
		)
		return err
	},
	CanDecode: func(client, server []byte) bool {

		return canDecodeBACnetIP(client) || canDecodeBACnetIP(server)
	},
	DeInit: func(sd *decoder.StreamDecoder) error {
		return bacnetipLog.Sync()
	},
	Factory: &bacnetipReader{},
	Typ:     core.UDP,
}

Decoder for protocol analysis and writing audit records to disk.

Functions

func GetBVLCFunctionName

func GetBVLCFunctionName(code uint8) string

GetBVLCFunctionName returns the human-readable name for a BVLC function code.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL