UNPKG

bacnet-device

Version:

A TypeScript library for implementing BACnet IP devices in Node.js.

15 lines 1.01 kB
import { BDSingletProperty } from '../properties/index.js'; import { BDObject } from './generic/object.js'; import { ObjectType, ApplicationTag, EngineeringUnits, PropertyIdentifier, } from '@innovation-system/node-bacnet'; export class BDPositiveIntegerValue extends BDObject { presentValue; covIncrement; engineeringUnit; constructor(instance, opts) { super(ObjectType.POSITIVE_INTEGER_VALUE, instance, opts.name, opts.description); this.presentValue = this.addProperty(new BDSingletProperty(PropertyIdentifier.PRESENT_VALUE, ApplicationTag.UNSIGNED_INTEGER, opts.writable ?? false, opts.presentValue ?? 0)); this.engineeringUnit = this.addProperty(new BDSingletProperty(PropertyIdentifier.UNITS, ApplicationTag.ENUMERATED, false, opts.unit)); this.covIncrement = this.addProperty(new BDSingletProperty(PropertyIdentifier.COV_INCREMENT, ApplicationTag.UNSIGNED_INTEGER, true, opts.covIncrement ?? 0)); } } //# sourceMappingURL=positiveintegervalue.js.map