Files
bacnet_stack/bacnet-stack/include/timestamp.h
T
minack 60ac0d0f8a Added:
-context specific decoders for all of the primitive times to go with the context specific encoders
-unconfirmed/confirmed EventNotificationRequest structure/encoder/decoder
-BACnetTimestamp structure/encoder/decoder
-BACnetPropertyStates structure/encoder/decoder
-BACnetDeviceObjectPropertyReference structure/encoder/decoder

Changes:
-decode_context_object_id::object_type changed to uint16_t
-explicit casts have been added to some functions to remove compiler warnings
-encode_bacnet_date::year behaviour has been changed slightly
2008-10-14 04:02:34 +00:00

45 lines
785 B
C

#ifndef _TIMESTAMP_H_
#define _TIMESTAMP_H_
#include "bacdcode.h"
typedef enum {
TIME_STAMP_TIME = 0,
TIME_STAMP_SEQUENCE = 1,
TIME_STAMP_DATETIME = 2,
} BACNET_TIMESTAMP_TAG;
typedef uint8_t TYPE_BACNET_TIMESTAMP_TYPE;
typedef struct {
TYPE_BACNET_TIMESTAMP_TYPE tag;
union {
BACNET_TIME time;
uint16_t sequenceNum;
BACNET_DATE_TIME dateTime;
} value;
} BACNET_TIMESTAMP;
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
int bacapp_encode_context_timestamp(
uint8_t * apdu,
uint8_t tag_number,
BACNET_TIMESTAMP * value);
int bacapp_decode_context_timestamp(
uint8_t * apdu,
uint8_t tag_number,
BACNET_TIMESTAMP * value);
#ifdef __cplusplus
}
#endif /* __cplusplus */
#endif