Niagara Tip: Stop Typing Enum Facets by Hand:
A Faster Way to Handle BACnet Alarm and Fault Codes
Anyone who has integrated boilers, chillers, AHUs, heat pumps, or packaged plant into Niagara has probably encountered the same frustration: A BACnet point exposes an alarm or fault code as a simple numeric value, while the manufacturer's fault table contains dozens or even hundreds of descriptive entries.
Manually creating Enum Facets in Niagara for every possible fault code is tedious, error-prone, and can easily consume hours of engineering time.
Fortunately, there is a much faster approach.
The Challenge
A typical BACnet device may expose a point such as:
|
Value |
Meaning |
|---|---|
|
0 |
No Fault |
|
1 |
Sensor Failure |
|
2 |
High Temperature |
|
3 |
Communication Error |
|
100+ |
Additional Manufacturer-Specific Faults |
By default, Niagara will only display the raw numeric value. To present meaningful alarms and diagnostics to operators, these values normally need to be converted into Enum Facets.
For small fault tables this can be done manually, but for larger systems the process quickly becomes impractical.
The Solution
A clever workaround shared by the Niagara community uses a simple text or CSV file combined with a Program Object to automatically generate the Enum Facets.
Step 1: Create a Text File
Create a file within your station containing the fault codes and descriptions.
Example:
0;Fan not available
1;Alarm stop
2;Manual total stop (on hand terminal)
3;External total stop (digital input)
4;Communication total stop
The format is:
<value><delimiter><description>
Most engineers use a semicolon (;) as the delimiter, but any unique character can be used.
Step 2: Reference the File
Within the Program Object:
-
Configure the File ORD to point to your text file.
-
Configure the Delimiter slot to match the character used in the file.
Example:
file:FaultCodes.txt
delimiter: ;
Step 3: Execute the Program
When the program runs, it parses each line and automatically generates Enum Facets from the data.
The resulting facet appears as if it had been manually created in Niagara, but is generated in seconds rather than hours.
Why This Is Useful
This technique is particularly valuable when integrating:
-
BACnet boilers
-
Chillers
-
Air Handling Units (AHUs)
-
Heat pumps
-
Power meters
-
VSDs and inverters
-
Generator controllers
-
Packaged plant equipment
Many manufacturers provide fault lists ranging from 50 to 300+ codes, making manual entry unrealistic during commissioning.
Key Benefits
✅ Significant time savings
✅ Reduced risk of typing errors
✅ Consistent naming conventions
✅ Easier fault diagnosis for operators
✅ Reusable across multiple projects
Pro Tip
Once the Enum Facets have been generated, open the facet editor and save the facet as a reusable template in your station database. This allows the same fault table to be quickly applied to multiple points or future projects without repeating the import process.
Real-World Example
Recently, while integrating a boiler controller with a fault table containing over 100 manufacturer-specific error codes, manually creating Enum Facets would have taken well over an hour.
Using the text-file import approach, the entire fault table was converted into a Niagara Enum Facet in just a few minutes, dramatically reducing engineering effort and improving the end-user experience.
Forest Rock Tips & Tricks
Small workflow improvements can save significant engineering time over the life of a project.
If you're routinely integrating BACnet equipment with extensive fault tables, building Enum Facets from a file is a simple but powerful technique worth adding to your Niagara toolkit.
Have your own Niagara productivity tip? We'd love to hear it and feature it in a future Forest Rock Knowledge Base article.