forked from vedderb/nrf52_vesc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
esb_timeslot.h
executable file
·57 lines (35 loc) · 1.21 KB
/
esb_timeslot.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#ifndef TIMESLOT_H__
#define TIMESLOT_H__
#include <stdbool.h>
#include <stdint.h>
#include "app_error.h"
#include "boards.h"
#include "nrf_esb.h"
typedef void (*ut_data_handler_t)(void * p_data, uint16_t length);
/**@brief Radio event handler
*/
void RADIO_timeslot_IRQHandler(void);
/**@brief Request next timeslot event in earliest configuration
*/
uint32_t request_next_event_earliest(void);
/**@brief Configure next timeslot event in earliest configuration
*/
void configure_next_event_earliest(void);
/**@brief Timeslot signal handler
*/
void nrf_evt_signal_handler(uint32_t evt_id);
/**@brief Timeslot event handler
*/
nrf_radio_signal_callback_return_param_t * radio_callback(uint8_t signal_type);
/**@brief Function for initializing.
*/
uint32_t esb_timeslot_init(ut_data_handler_t evt_handler);
/**@brief Function for starting the timeslot API.
*/
uint32_t esb_timeslot_sd_start(void);
/**@brief Function for stopping the timeslot API.
*/
uint32_t esb_timeslot_sd_stop(void);
void esb_timeslot_set_next_packet(uint8_t *data, unsigned int len);
void esb_timeslot_set_ch_addr(uint8_t ch, uint8_t b0, uint8_t b1, uint8_t b2);
#endif // TIMESLOT_H__