Doly C++ SDK v1.00
Loading...
Searching...
No Matches
ServoEvent.h
Go to the documentation of this file.
1#pragma once
2#include <stdint.h>
4
5namespace ServoEvent
6{
7 // Add listener class
8 void AddListener(ServoEventListener* observer, bool priority = false);
9
10 // Remove listener class
12
13 // Add static event fuction to complete event queue
14 void AddListenerOnComplete(void(*onEvent)(uint16_t id, ServoId channel));
15
16 // Remove static event fuction from complete event queue
17 void RemoveListenerOnComplete(void(*onEvent)(uint16_t id, ServoId channel));
18
19 // Add static event fuction to error event queue
20 void AddListenerOnAbort(void(*onEvent)(uint16_t id, ServoId channel));
21
22 // Remove static event fuction from error event queue
23 void RemoveListenerOnAbort(void(*onEvent)(uint16_t id, ServoId channel));
24
25 // Add static event fuction to error event queue
26 void AddListenerOnError(void(*onEvent)(uint16_t id, ServoId channel));
27
28 // Remove static event fuction from error event queue
29 void RemoveListenerOnError(void(*onEvent)(uint16_t id, ServoId channel));
30
31 // Call complete event listeners
32 void ServoComplete(uint16_t id, ServoId channel);
33
34 // Call abort event listeners
35 void ServoAbort(uint16_t id, ServoId channel);
36
37 // Call error event listeners
38 void ServoError(uint16_t id, ServoId channel);
39
40};
41
42
Listener interface and data types for servo control events.
Observer interface for receiving servo completion/abort/error events.
Definition ServoEventListener.h:38
ServoId
Servo channel identifiers.
Definition ServoEventListener.h:25
Definition ServoEvent.h:6
void RemoveListenerOnError(void(*onEvent)(uint16_t id, ServoId channel))
void AddListenerOnError(void(*onEvent)(uint16_t id, ServoId channel))
void AddListenerOnComplete(void(*onEvent)(uint16_t id, ServoId channel))
void AddListener(ServoEventListener *observer, bool priority=false)
void ServoComplete(uint16_t id, ServoId channel)
void ServoAbort(uint16_t id, ServoId channel)
void ServoError(uint16_t id, ServoId channel)
void RemoveListenerOnAbort(void(*onEvent)(uint16_t id, ServoId channel))
void RemoveListenerOnComplete(void(*onEvent)(uint16_t id, ServoId channel))
void AddListenerOnAbort(void(*onEvent)(uint16_t id, ServoId channel))
void RemoveListener(ServoEventListener *observer)