From 35c885898abb866256bfcc5e62f13913f89e4e25 Mon Sep 17 00:00:00 2001 From: Florent Duchon Date: Tue, 23 Apr 2013 16:45:01 +0200 Subject: digital/zigbit/common: rework of UID definition --- digital/zigbit/common/uid.h | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'digital/zigbit/common/uid.h') diff --git a/digital/zigbit/common/uid.h b/digital/zigbit/common/uid.h index c5a5c8f4..f3969b2e 100644 --- a/digital/zigbit/common/uid.h +++ b/digital/zigbit/common/uid.h @@ -23,11 +23,32 @@ * * }}} */ -#define APBTEAM_MAX_ZIGBIT_DEVICES 3 +#ifndef _UID_H +#define _UID_H +#define APBTEAM_MAX_ZIGBIT_DEVICES 16 + +typedef enum +{ + ZIGBIT_NOT_DEFINED, + ZIGBIT_BEACON, + ZIGBIT_DONGLE, +} TFunctionnality; + +typedef struct +{ + uint16_t uid; + DeviceType_t type; + TFunctionnality func; +} zigbit_definition_s; /* This function returns the UID of the device according to the mapping of F5 F6 F7 F8*/ uint16_t get_uid(void); /* This function returns the device type */ DeviceType_t get_device_type(uint16_t uid); + +/* This function returns the device functionnaly */ +TFunctionnality get_device_functionnality(uint16_t uid); + +#endif -- cgit v1.2.3