bacpypes3 DailySchedule, TimeValue, AnyAtomic: Source and Usage

Tools & Librariesbacpypes3Schedule objectDailyScheduleTimeValue
May 24, 2026|8 min read

In bacpypes3, DailySchedule, TimeValue, and AnyAtomic are Python implementations of the BACnet construct types defined in ASHRAE 135. DailySchedule and TimeValue live in the library's bacpypes3.basetypes module; AnyAtomic lives in bacpypes3.constructeddata. The canonical source is the bacpypes3 repository linked from its PyPI project page. A Schedule object's Weekly_Schedule is an array of seven DailySchedule entries; each DailySchedule carries a sequence of TimeValue entries; each TimeValue pairs a BACnet Time with an AnyAtomic value (Boolean, Unsigned, Real, Enumerated, etc.). Most of the type errors builders hit come from passing a raw Python value where a BACnet primitive (or an AnyAtomic wrapping one) is required.

Scenario: Building a Schedule Object in bacpypes3

You are writing a Python service against bacpypes3 — a custom application, a test harness, or a small supervisor — and you need to either build a BACnet Schedule object locally or write a new Weekly_Schedule to a remote device. The BACnet spec describes the structure in plain English, but as soon as you try to instantiate the Python classes, you get errors that look like:

The fix is almost always a type-correctness problem, not a bug in bacpypes3. To resolve it cleanly, it helps to read the actual class definitions in the source — which is what the search query that brought most readers here is really asking for.

The ASHRAE 135 Types Behind the Python Classes

The bacpypes3 classes are direct Python translations of the constructed and primitive types defined in ASHRAE Standard 135. Treat the spec as the source of truth for shape and constraints, and the Python library as the encoder/decoder.

The schedule's List_Of_Object_Property_References property is what determines which atomic property on which device gets written when a TimeValue fires. The AnyAtomic in the TimeValue must be type-compatible with that target property — sending a Boolean to a Real-typed Present_Value is a common cause of post-write rejection.

Where the Source Lives

bacpypes3 is the Python 3 / asyncio-based rewrite of the original bacpypes library. The authoritative places to look for the type definitions:

Constructing a Weekly_Schedule Without Type Errors

The pattern that works across recent bacpypes3 releases:

  1. Build BACnet primitives, not Python primitives. Wrap your scheduled value in the matching bacpypes3 primitive class (Real, Boolean, Unsigned, Enumerated) before constructing the TimeValue. The exact constructor for AnyAtomic — whether it auto-coerces a primitive or requires an explicit cast — varies by version; consult the installed source.
  2. Use the BACnet Time type for the time field. Pass a bacpypes3.primitivedata.Time (or whatever path the installed version exposes), not a datetime.time. Hours run 0–23, minutes and seconds 0–59, and hundredths can be wildcarded with 0xFF per ASHRAE 135 if you want "unspecified."
  3. Keep TimeValue entries in ascending time order within each DailySchedule. The standard requires it, and several BAS supervisors will silently re-sort or reject lists that arrive out of order.
  4. Make sure all seven days are present. Weekly_Schedule is a fixed array of seven DailySchedules, one per day. An empty DailySchedule is fine for "no transitions today," but you cannot omit the day entirely.
  5. Verify the type match against the target. If your schedule drives a Real-typed point, every TimeValue.value must be a Real (wrapped appropriately). Mixing types within a single schedule is legal in the spec but is rejected by many controllers in practice.

Common Pitfalls

When to Escalate

If the types match the spec and a peer device still rejects the schedule, the problem is usually on the remote side: a controller that does not fully implement Schedule object writes, a vendor-specific restriction on which atomic types are accepted, or a missing Out_Of_Service handling. Escalate by:

Related KB Entries

Source Attribution

Additional testing and field validation by SiteConduit.

bacpypes3Schedule objectDailyScheduleTimeValueAnyAtomic

Was this article helpful?

Related Articles

Need to do this remotely? SiteConduit provides Layer 2 access that preserves BACnet broadcasts — no BBMD needed for remote sessions. Join the waitlist.

SC

SiteConduit Technical Team

Idea Networks Inc.

SiteConduit builds managed remote access for building automation. Our knowledge base is maintained by BAS professionals with hands-on experience deploying and troubleshooting BACnet, Niagara, Modbus, and Facility Explorer systems.