Skip to content

Latest commit

 

History

History
384 lines (321 loc) · 22.3 KB

PICS.md

File metadata and controls

384 lines (321 loc) · 22.3 KB

BACnet Protocol Implementation Conformance Statement (PICS)

For the BACnet B-RTR (Router) C++ example - see README.md.

This is the PICS for the example as shipped. It describes a tutorial device announcing itself as a Chipkin demo, not a product. When you turn this example into your own device, this document is one of the things you rewrite: the vendor, model and version rows all come from the CHANGE ALL OF THIS BEFORE YOU SHIP block at the top of main.cpp. The example has not been submitted for BTL certification.

1. Product description

Vendor Name Chipkin Automation Systems
Vendor Identifier 389
Product Name CAS BACnet Stack Example - B-RTR
Product Model Number CAS BACnet Stack Example - B-RTR
Application Software Version 1.2.1
Firmware Revision 6.0.23.0 (the CAS BACnet Stack version, read at run time)
BACnet Protocol Version 1
BACnet Protocol Revision 30 (the stack default; this example does not set it)

Product Description: a stand-alone BACnet router built on the CAS BACnet Stack. It owns two BACnet/IP Network Port objects, one per network it joins (networks 1 and 2), and forwards NPDUs between them: a ReadProperty sent from network 1 to a device on network 2 crosses the router and its answer comes back with SNET = 2. It also carries the shared minimum/commandable object pattern (three read-only inputs, three writable commandable outputs) used across this example series and a Group object whose member list clients edit with AddListElement / RemoveListElement. It is a tutorial for implementers of the B-RTR profile; section 9 lists the router behaviours that are not yet conformant, all of them outside this example.

2. BACnet standardized device profile (Annex L)

B-RTR - BACnet Router.

This device claims exactly one profile. Because the B-RTR requirements are a superset of B-GENERAL's, a conformant B-RTR device also satisfies B-GENERAL (Annex L.8); that is subsumption, not a second claim.

3. BIBBs supported (Annex K)

BIBB Description Supported
DS-RP-B Data Sharing - ReadProperty - B yes
DS-WP-B Data Sharing - WriteProperty - B yes
DM-DDB-B Device Management - Dynamic Device Binding - B yes
DM-DOB-B Device Management - Dynamic Object Binding - B yes
DM-LM-B Device Management - List Manipulation - B (AddListElement/RemoveListElement) yes - on Group 1's List_Of_Group_Members
NM-RC-B Network Management - Router Configuration - B yes - forwards between networks 1 and 2, answers Who-Is-Router-To-Network, rejects a message for an unreachable network, announces itself at start-up; section 9 lists the parts that are not yet conformant

No other BIBBs are supported. In particular this device does not support DM-DDB-A (it answers Who-Is but never initiates it), DS-RPM-B (ReadPropertyMultiple), DS-COV-B, any alarm and event (AE-) BIBB, scheduling (SCHED-), trending (T-*), or DM-DCC-B (DeviceCommunicationControl).

Against Annex L.7 of ANSI/ASHRAE 135-2024. The L.7 BIBB table lists, for B-RTR: DS-RP-B, DS-WP-B, DM-DDB-B, DM-DOB-B and NM-RC-B - all supported above. In that table DM-LM-B is under B-DAP, not B-RTR; this device supports it anyway. DM-DCC-B is under B-ACDC and B-ACCR only, so it is not required here and not supported - even though L.7.1's prose for B-RTR lists "Ability to respond to communication control messages". The table is the list of BIBBs a profile "shall" support; a product that also wants to meet the prose adds DeviceCommunicationControl the way the B-ASC example does.

4. Application services supported

Service Initiate Execute
ReadProperty no yes
WriteProperty no yes
AddListElement no yes
RemoveListElement no yes
Who-Is no yes
I-Am yes -
Who-Has no yes
I-Have yes -

An unsolicited I-Am is broadcast on both networks at start-up.

Network layer messages (clause 6) this router sends and answers:

Message Sent Answered / processed
Who-Is-Router-To-Network at start-up on both ports (unrestricted query) yes - with I-Am-Router-To-Network listing every network reachable through the router except those reached through the port the query arrived on (section 9: sent unicast)
I-Am-Router-To-Network at start-up and on the r key, on both ports, each listing the networks reachable through the router from that port processed (learns routes)
Network-Number-Is at start-up on both ports, each port's own number processed
Reject-Message-To-Network to the originator of a message for a network the router cannot reach (reason 1) -

Any other confirmed service is rejected. That rejection is part of the profile boundary, not a limitation to work around.

5. Segmentation capability

Segmentation is supported in both directions (Segmentation_Supported = segmented-both), by the stack: at 6.x @ 1e7dffe2b the customer build compiles STACK_OPTION_SEGMENTATION in (stack #2992), and this example keeps the stack's defaults - Max_Segments_Accepted 16 and APDU_Segment_Timeout 5000 ms, both read on the wire. Table 12-13 footnote 1: "These properties are required if, and shall be present only if, segmentation of any kind is supported" - they are not rows in section 7 because its generator lists only unconditionally required properties. Max_APDU_Length_Accepted is 1476 octets, the BACnet/IP maximum, on both Network Ports. (At the previous pin, e6de4ffd, this example answered no-segmentation.)

6. Standard object types supported

No object is dynamically creatable or deletable.

Object type Instance Object_Name Writable Optional properties supported
Device 389018 Chipkin Example B-RTR no Description
Analog Input 1 Bronze no -
Binary Input 1 Emerald no -
Multi-State Input 1 Hot Pink no State_Text
Analog Output 1 Chartreuse yes (commandable) -
Binary Output 1 Fuchsia yes (commandable) -
Multi-State Output 1 Indigo yes (commandable) -
Group 1 Olive List_Of_Group_Members (AddListElement / RemoveListElement) -
Network Port 1 Vermilion no -
Network Port 2 Vermilion 2 no -

The device instance is configurable at start-up with --deviceID, and the Device's Object_Name with --deviceName (BACnet requires both to be configurable, cl. 12.1.1.3 and 12.1.1.4). Changing either means restarting the device; neither is writable over the network. The table shows the defaults.

7. Data link layer options

BACnet/IP (Annex J), two independent instances on one host, distinguished by UDP port: Network Port 1 (Vermilion) on --port (default 47808), Network Port 2 (Vermilion 2) on --port2 (default --port + 1 = 47809).

BBMD is not supported, Foreign Device registration is not supported, and BACnet/SC, MS/TP, Ethernet (Annex H) and PTP are not supported.

8. Device address binding

Static device binding is not supported. The device answers Who-Is/Who-Has; it does not initiate Who-Is or otherwise bind a peer address ahead of time.

9. Networking options

This device is a router between two directly-connected BACnet/IP networks: network 1 on Network Port 1 (Vermilion) and network 2 on Network Port 2 (Vermilion 2). Each Network Port carries its own Network_Number (configured), which gives each port its own BACnet/IP datalink in the stack. A third network, 3, is configured as reachable one hop beyond port 2 (BACnetStack_AddRouterRoute) to demonstrate that API; nothing sits on it.

Verified on the wire by the scripts in tests/, each of which fails when the feature it checks is removed:

  • Forwarding (cl. 6.5). A ReadProperty sent from network 1 with DNET = 2, DADR = a (simulated) device's address, reaches that device through Network Port 2, and the ComplexACK comes back to network 1 with SNET = 2 and SADR = the device's address.
  • Unreachable network (cl. 6.6.3.1, 6.4.4). A request for DNET = 99 is answered with Reject-Message-To-Network, reason 1, network 99, sent to the originator - after the router has searched for network 99 with a Who-Is-Router-To-Network broadcast on Network Port 2.
  • Remote and global broadcasts (cl. 6.3.2, 6.5.4). A Who-Is sent from network 1 with DNET = 2, DLEN = 0 is re-broadcast on network 2 without a DNET, and one with DNET = 0xFFFF is re-broadcast there still carrying DNET = 0xFFFF; both carry SNET = 1 / SADR = the client. A (simulated) device on network 2 answers, and its I-Am reaches the client with SNET = 2 - so device discovery works across this router.
  • Who-Is-Router-To-Network (cl. 6.6.3.2). Asked on Network Port 1, the router lists networks 2 and 3; asked on Network Port 2, it lists network 1. Neither answer lists a network reached through the port the query arrived on.
  • Start-up (cl. 6.6.2, 6.4.20). I-Am-Router-To-Network is broadcast on each port by the stack itself - networks 2 and 3 on Network Port 1, network 1 on Network Port 2 - and each port broadcasts Network-Number-Is with its own number.
  • Network_Number / Network_Number_Quality read 1/configured and 2/configured.
  • Routing_Table (cl. 12.56.62), kept by the stack while routing is enabled: Network Port 1 reads an empty list (no router beyond it); Network Port 2 reads one entry, network 3 (the demonstration route), empty MAC address (no next-hop router configured), status available. Directly connected networks are not listed (tests/routing_table_test.py).
  • A Network-Number-Is heard on a port is attributed to that port (tests/routing_table_test.py).

Not yet conformant - each is outside this example, listed in TODO.md, and reported as a [KNOWN GAP] by the tests:

  • The I-Am-Router-To-Network answering a Who-Is-Router-To-Network is sent unicast to the requester; cl. 6.4.2 requires a broadcast MAC address (stack #3931).

BBMD and Foreign Device functionality are not implemented by this router.

10. Character sets supported

UTF-8 (ANSI X3.4). Supporting a character set does not imply the device can handle data in all character sets.

11. Objects and properties

Every object this example creates, and every REQUIRED property of each (per ANSI/ASHRAE 135-2024 clause 12 and the CAS BACnet Stack's property profiles), plus the optional properties the example turns on. Served by says who answers a ReadProperty: the stack generates it, or the app serves it from a GetProperty* callback in main.cpp. A ⚠ row is a required property the app does not serve and the stack would fill with a default - that is a defect, not a feature.

Device 389018 "Chipkin Example B-RTR" - vendor 389 (Chipkin Automation Systems); instance configurable with --deviceID and the Object_Name with --deviceName (both at start-up; the heading shows the defaults). The stack rows are device-wide facts only the stack knows - the protocol version and revision it implements, the services and object types it was configured with, the live object list and address-binding table - and Database_Revision, which the stack starts at 0 and increments as the objects are added at start-up: it reads 10 and stays 10, because the router creates, deletes and renames nothing afterwards (forwarding, and editing Group 1's member list, change no object's existence or name). The accepted rows are the stack's configured defaults for APDU limits, segmentation and system status; an application that answered them from its own constants could contradict the stack, so this example does not

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
System_Status BACnetDeviceStatus stack default, accepted (Generic Enumerated default: 0) no
Vendor_Name CharacterString app no
Vendor_Identifier Unsigned16 app no
Model_Name CharacterString app no
Firmware_Revision CharacterString app no
Application_Software_Version CharacterString app no
Description (optional, enabled) CharacterString app no
Protocol_Version Unsigned stack no
Protocol_Revision Unsigned stack no
Protocol_Services_Supported BACnetServicesSupported stack no
Protocol_Object_Types_Supported BACnetObjectTypesSupported stack no
Object_List BACnetARRAY[N] of BACnetObjectIdentifier stack no
Max_APDU_Length_Accepted Unsigned stack default, accepted (CAS_BACNET_DEVICE_DEFAULT_MAX_APDU_LENGTH_ACCEPTED) no
Segmentation_Supported BACnetSegmentation stack default, accepted (BACnetSegmentation::segmentedBoth with `STACK_OPTION_SEGME) no
APDU_Timeout Unsigned stack default, accepted (CAS_BACNET_DEVICE_DEFAULT_APDU_TIMEOUT) no
Number_Of_APDU_Retries Unsigned stack default, accepted (CAS_BACNET_DEVICE_DEFAULT_NUMBER_OF_APDU_RETRIES) no
Device_Address_Binding BACnetLIST of BACnetAddressBinding stack no
Database_Revision Unsigned stack no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

Analog Input 1 "Bronze" - REAL, degrees Celsius; starts at 21.5; read-only

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Present_Value Real app no
Status_Flags BACnetStatusFlags stack no
Event_State BACnetEventState stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Units BACnetEngineeringUnits app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

Binary Input 1 "Emerald" - starts inactive; read-only

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Present_Value BACnetBinaryPV app no
Status_Flags BACnetStatusFlags stack no
Event_State BACnetEventState stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Polarity BACnetPolarity app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

Multi-state Input 1 "Hot Pink" - state 1 of 3: On, Off, Auto; read-only

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Present_Value Unsigned app no
Status_Flags BACnetStatusFlags stack no
Event_State BACnetEventState stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Number_Of_States Unsigned app no
State_Text (optional, enabled) BACnetARRAY[N] of CharacterString app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

Analog Output 1 "Chartreuse" - REAL setpoint, default 20.0 C; commandable via a 16-slot Priority_Array (WriteProperty, DS-WP-B) - Present_Value/Priority_Array/Current_Command_Priority are resolved by the stack from the slots the app serves through GetPropertyReal/GetPropertyBool

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Present_Value Real stack yes
Status_Flags BACnetStatusFlags stack no
Event_State BACnetEventState stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Units BACnetEngineeringUnits app no
Priority_Array BACnetARRAY[16] of BACnetOptionalReal stack no
Relinquish_Default Real app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no
Current_Command_Priority BACnetOptionalUnsigned stack no

Binary Output 1 "Fuchsia" - active/inactive, default inactive; commandable via a 16-slot Priority_Array (WriteProperty, DS-WP-B) - Present_Value/Priority_Array/Current_Command_Priority are resolved by the stack from the slots the app serves through GetPropertyEnumerated/GetPropertyBool

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Present_Value BACnetBinaryPV stack yes
Status_Flags BACnetStatusFlags stack no
Event_State BACnetEventState stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Polarity BACnetPolarity app no
Priority_Array BACnetARRAY[16] of BACnetOptionalBinaryPV stack no
Relinquish_Default BACnetBinaryPV app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no
Current_Command_Priority BACnetOptionalUnsigned stack no

Multi-state Output 1 "Indigo" - state 1 of 3, default state 1; commandable via a 16-slot Priority_Array (WriteProperty, DS-WP-B) - Present_Value/Priority_Array/Current_Command_Priority are resolved by the stack from the slots the app serves through GetPropertyUnsignedInteger/GetPropertyBool

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Present_Value Unsigned stack yes
Status_Flags BACnetStatusFlags stack no
Event_State BACnetEventState stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Number_Of_States Unsigned app no
Priority_Array BACnetARRAY[16] of BACnetOptionalUnsigned stack no
Relinquish_Default Unsigned app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no
Current_Command_Priority BACnetOptionalUnsigned stack no

Group 1 "Olive" - DM-LM-B. BACnetStack_AddGroupObject hands List_Of_Group_Members to the stack, which stores it, executes AddListElement/RemoveListElement on it (made writable with BACnetStack_SetPropertyWritable) and builds Present_Value from it - one ReadAccessResult per member. Starts with one member, Analog Input 1 (Present_Value); tests/list_element_test.py adds and removes a second.

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
List_Of_Group_Members BACnetLIST of ReadAccessSpecification stack yes
Present_Value BACnetLIST of ReadAccessResult stack no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

Network Port 1 "Vermilion" - BACnet/IP, network 1, configured (F-MULTIPORT/F-ROUTER port A). Network_Type/Protocol_Level are set from BACnetStack_AddNetworkPortObject()'s arguments at start-up, as are Network_Number = 1 and Network_Number_Quality = configured (read back on the wire by tests/router_discovery_test.py; not separate rows here because the stack's property-profile-reference.md does not carry them under the type-agnostic 'Network Port' heading this generator reads). Changes_Pending is likewise computed and answered natively. Reliability has no fault condition this example detects, so it is accepted at the generic default (normal). Routing_Table (cl. 12.56.62) is enabled and kept by the stack while routing is enabled - here an empty list, no router lies beyond this port; Network Port 2 lists network 3 (tests/routing_table_test.py). Not a row here, for the same reason as Network_Number.

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Status_Flags BACnetStatusFlags stack no
Reliability BACnetReliability stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Network_Type BACnetNetworkType app no
Protocol_Level BACnetProtocolLevel app no
Changes_Pending Boolean app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

Network Port 2 "Vermilion 2" - BACnet/IP, network 2, configured (F-MULTIPORT/F-ROUTER port B). Same notes as Network Port 1 (Vermilion) apply, with Network_Number = 2. Its own Network_Number gives it its own BACnet/IP datalink in the stack, which is what lets the router forward between the two ports: tests/routing_test.py reads a device on network 2 from a client on network 1.

Property Datatype Served by Writable
Object_Identifier BACnetObjectIdentifier stack no
Object_Name CharacterString app no
Object_Type BACnetObjectType stack no
Status_Flags BACnetStatusFlags stack no
Reliability BACnetReliability stack default, accepted (Generic Enumerated default: 0) no
Out_Of_Service Boolean app no
Network_Type BACnetNetworkType app no
Protocol_Level BACnetProtocolLevel app no
Changes_Pending Boolean app no
Property_List BACnetARRAY[N] of BACnetPropertyIdentifier stack no

12. References

  • ANSI/ASHRAE Standard 135-2024, Annex A (PICS template), Annex K (BIBBs), Annex L (device profiles), Clause 6.6 (routers), Clause 12 (object types).
  • README.md - what this example is and how to build it.
  • TUTORIAL.md - how to extend it, and how to keep this document honest when you do.
  • TODO.md - the remaining router gaps in detail, and where each one has to be fixed.
  • tests/README.md - the wire-level tests behind section 9.