Expand description
Clause 21 codecs for the Schedule object’s constructed properties (Clause 12.24): Weekly_Schedule and Exception_Schedule.
BACnetTimeValueis a SEQUENCE of two untagged members, so it is an application-tagged Time followed by one application-tagged primitive value, with no frame.BACnetTimeValue::valueholds that value typed.BACnetDailyScheduleis a SEQUENCE with one member, day-schedule[0], a SEQUENCE OFBACnetTimeValue: an opening/closing[0]pair around the time-values. Weekly_Schedule is a BACnetARRAY[7] of them, Monday first.BACnetSpecialEventis three members with no outer frame:
| Member | Tag | Encoding |
|---|---|---|
| period | (untagged) | CHOICE: calendar-entry [0] or calendar-reference [1] |
| list-of-time-values | [2] | opening/closing pair around the time-values |
| event-priority | [3] | primitive Unsigned, 1 through 16 when valid |
The calendar-entry alternative wraps a BACnetCalendarEntry, itself a
CHOICE, so it is an opening/closing [0] pair around the entry’s own
tagged encoding (see super::calendar). The calendar-reference
alternative is a primitive [1] Calendar object identifier.
Exception_Schedule is a BACnetARRAY of special events, concatenated when
read whole.
These codecs check structure only, like the calendar-entry codec: a well-formed event with a priority outside 1 through 16 decodes, and the consumer range-checks it (#1087).
Functions§
- decode_
daily_ schedule - Decode one
BACnetDailyScheduleatoffset; returns its time-values and the offset just past the closing[0]. - decode_
exception_ schedule - Decode a whole Exception_Schedule: zero or more special events, back to
back, with every byte belonging to one. Like
decode_special_event, it leaves each event-priority’s range to the caller. - decode_
special_ event - Decode one
BACnetSpecialEventatoffset; returns the event and the offset just past it. - decode_
special_ event_ period - Decode the period CHOICE of a
BACnetSpecialEventatoffset. - decode_
time_ value - Decode one
BACnetTimeValueatoffset. - decode_
weekly_ schedule - Decode a whole Weekly_Schedule.
- encode_
daily_ schedule - Encode one
BACnetDailySchedule: its time-values inside[0]. Fails only on a time-value thatencode_time_valuerefuses. - encode_
exception_ schedule - Encode a whole Exception_Schedule: the special events, concatenated.
- encode_
special_ event - Encode one
BACnetSpecialEvent; fails only on a time-value thatencode_time_valuerefuses. The event-priority goes out as held, in or out of its range. - encode_
special_ event_ period - Encode the period CHOICE of a
BACnetSpecialEvent. - encode_
time_ value - Encode one
BACnetTimeValue: the application-tagged Time, then the application-tagged value. - encode_
weekly_ schedule - Encode a whole Weekly_Schedule: seven daily schedules, Monday first.