EventDistributor#
Modules#
zaf_event_distributor_cc_event_handler_map_v1_t
Enumerations#
Defines return values from EventDistributorConfigure.
Typedefs#
Redefine latest version to a common define called latest.
Defines return values from EventDistributorConfigure.
Defines callback pointer for Event handler.
EventDistributor object.
Functions#
Initializes the ZAF Event Distributor component.
Gets the events distributor.
Distributes events.
Used by the application to handle protocol received events.
Used by the application to handle protocol command status.
Used by the application to handle state changes in the NCP state machine.
Used by the application to handle serial data received.
Used by the application to handle serial timeout.
Used by the application to handle application/system received events.
Used by application to verify if it is a primary controller.
Enqueues an event in the application queue.
Enqueues an event in the application queue.
Enqueues an event in the command class event queue.
Enqueues an event in the command class event queue.
Configures the EventDistributor.
Waits for Task notification and calls event handlers matching the set notification bits.
Macros#
Section name.
Registers a custom event handler for a specific command class.
Enumeration Documentation#
EEventDistributorStatus#
EEventDistributorStatus
Defines return values from EventDistributorConfigure.
Enumerator | |
---|---|
EEVENTDISTRIBUTOR_STATUS_SUCCESS | |
EEVENTDISTRIBUTOR_STATUS_TABLE_TOO_LARGE |
59
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/Components/EventDistributor/EventDistributor.h
Typedef Documentation#
zaf_event_distributor_cc_event_handler_handler_v1_t#
typedef void(* zaf_event_distributor_cc_event_handler_handler_v1_t) (const uint8_t, const void *) )(const uint8_t, const void *)
20
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
zaf_event_distributor_cc_event_handler_map_latest_t#
typedef zaf_event_distributor_cc_event_handler_map_v1_t zaf_event_distributor_cc_event_handler_map_latest_t
Redefine latest version to a common define called latest.
40
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
EEventDistributorStatus#
typedef enum EEventDistributorStatus EEventDistributorStatus
Defines return values from EventDistributorConfigure.
63
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/Components/EventDistributor/EventDistributor.h
EventDistributorEventHandler#
typedef void(* EventDistributorEventHandler) (void) )(void)
Defines callback pointer for Event handler.
Typedef to simplify syntax.
70
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/Components/EventDistributor/EventDistributor.h
SEventDistributor#
typedef struct SEventDistributor SEventDistributor
EventDistributor object.
All content is private.
83
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/Components/EventDistributor/EventDistributor.h
Function Documentation#
zaf_event_distributor_init#
void zaf_event_distributor_init (void )
Initializes the ZAF Event Distributor component.
N/A |
This function invokes EventDistributorConfig().
26
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor.h
zaf_event_distributor_get#
const SEventDistributor * zaf_event_distributor_get (void )
Gets the events distributor.
N/A |
Each variation (NCP,SOC) must implement it's own event distributor table
Returns
const SEventDistributor
35
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor.h
zaf_event_distributor_distribute#
uint32_t zaf_event_distributor_distribute (void )
Distributes events.
N/A |
Wraps EventDistributorDistribute().
Returns
bitfield with unhandled events
44
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor.h
zaf_event_distributor_app_zw_rx#
void zaf_event_distributor_app_zw_rx (SZwaveReceivePackage * RxPackage)
Used by the application to handle protocol received events.
N/A | RxPackage | ZW Receive Package |
25
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_ncp.h
zaf_event_distributor_app_zw_command_status#
void zaf_event_distributor_app_zw_command_status (SZwaveCommandStatusPackage * Status)
Used by the application to handle protocol command status.
N/A | Status | ZW Command Status Package |
32
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_ncp.h
zaf_event_distributor_app_state_change#
void zaf_event_distributor_app_state_change (void )
Used by the application to handle state changes in the NCP state machine.
N/A |
39
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_ncp.h
zaf_event_distributor_app_serial_data_rx#
void zaf_event_distributor_app_serial_data_rx (void )
Used by the application to handle serial data received.
N/A |
45
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_ncp.h
zaf_event_distributor_app_serial_timeout#
void zaf_event_distributor_app_serial_timeout (void )
Used by the application to handle serial timeout.
N/A |
51
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_ncp.h
zaf_event_distributor_app_event_manager#
void zaf_event_distributor_app_event_manager (const uint8_t event)
Used by the application to handle application/system received events.
N/A | event | application/system received event |
77
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
zaf_event_distributor_is_primary_controller#
uint8_t zaf_event_distributor_is_primary_controller (void )
Used by application to verify if it is a primary controller.
N/A |
Returns
uint8_t 1 if it is primary controller else 0
84
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
zaf_event_distributor_enqueue_app_event#
bool zaf_event_distributor_enqueue_app_event (const uint8_t event)
Enqueues an event in the application queue.
N/A | event | The event to enqueue. |
Returns
Returns true if the event was enqueued and false otherwise.
91
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
zaf_event_distributor_enqueue_app_event_from_isr#
bool zaf_event_distributor_enqueue_app_event_from_isr (const uint8_t event)
Enqueues an event in the application queue.
N/A | event | The event to enqueue. |
Returns
Returns true if the event was enqueued and false otherwise.
98
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
zaf_event_distributor_enqueue_cc_event#
bool zaf_event_distributor_enqueue_cc_event (const uint16_t command_class, const uint8_t event, const void * data)
Enqueues an event in the command class event queue.
N/A | command_class | The command class to receive the event |
N/A | event | The event to enqueue. |
N/A | data | A data pointer. It must point to a global variable |
Returns
Returns true if the event was enqueued and false otherwise.
108
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
zaf_event_distributor_enqueue_cc_event_from_isr#
bool zaf_event_distributor_enqueue_cc_event_from_isr (const uint16_t command_class, const uint8_t event, const void * data)
Enqueues an event in the command class event queue.
N/A | command_class | The command class to receive the event |
N/A | event | The event to enqueue. |
N/A | data | A data pointer. It must point to a global variable |
Returns
Returns true if the event was enqueued and false otherwise.
120
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
EventDistributorConfig#
EEventDistributorStatus EventDistributorConfig (SEventDistributor * pThis, uint8_t iEventHandlerTableSize, const EventDistributorEventHandler * pEventHandlerTable, void(*)(void) pNoEvent)
Configures the EventDistributor.
[in] | pThis | Pointer to the EventDistributor object. |
[in] | iEventHandlerTableSize | Number of entries in EventHandlerTable pointed to by argument pEventHandlerTable Table size range is 0 - 32) |
[in] | pEventHandlerTable | Pointer to table of EventHandler function pointers |
[in] | pNoEvent | Function pointer that will be called on notifications without event or wait for event timeout |
Configure must be called before calling any other EventDistributor methods. EventDistributor supports reconfiguration at all times.
101
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/Components/EventDistributor/EventDistributor.h
EventDistributorDistribute#
uint32_t EventDistributorDistribute (const SEventDistributor * pThis, uint32_t iEventWait, uint32_t NotificationClearMask)
Waits for Task notification and calls event handlers matching the set notification bits.
[in] | pThis | Pointer to the EventDistributor object |
[in] | iEventWait | Timeout (in mS) when waiting for event. Value must NOT be zero. |
[in] | NotificationClearMask | Mask of additional notification bits to clear, which is not handled by EventDistributor. EventDistributor will always clear notification bits assigned to events. This mask is additional bits to clear. |
Method returns when a notification has arrived (or waiting timed out) and any pending events has been handled.
Returns
uint32_t Task notification value. All bits handled by EventDistributor are set to zero.
124
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/Components/EventDistributor/EventDistributor.h
Macro Definition Documentation#
ZAF_EVENT_DISTRIBUTOR_CC_EVENT_HANDLER_SECTION#
#define ZAF_EVENT_DISTRIBUTOR_CC_EVENT_HANDLER_SECTIONValue:
"zw_zaf_event_distributor_cc_event_handler"
Section name.
45
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h
ZAF_EVENT_DISTRIBUTOR_REGISTER_CC_EVENT_HANDLER#
#define ZAF_EVENT_DISTRIBUTOR_REGISTER_CC_EVENT_HANDLERValue:
Registers a custom event handler for a specific command class.
53
of file /mnt/raid/workspaces/ws.6QOxxjIBR/overlay/gsdk/protocol/z-wave/ZAF/ApplicationUtilities/EventHandling/zaf_event_distributor_soc.h