NimBLE-Arduino 2.1.2
Loading...
Searching...
No Matches
heartbeat.h
Go to the documentation of this file.
1
5/*
6 * Copyright (c) 2020 Nordic Semiconductor ASA
7 *
8 * SPDX-License-Identifier: Apache-2.0
9 */
10#ifndef _BLUETOOTH_MESH_HEARTBEAT_H_
11#define _BLUETOOTH_MESH_HEARTBEAT_H_
12
20#ifdef __cplusplus
21extern "C" {
22#endif
23
27 uint16_t dst;
29 uint16_t count;
31 uint8_t ttl;
38 uint16_t feat;
40 uint16_t net_idx;
42 uint32_t period;
43};
44
48 uint32_t period;
50 uint32_t remaining;
52 uint16_t src;
54 uint16_t dst;
56 uint16_t count;
63 uint8_t min_hops;
70 uint8_t max_hops;
71};
72
89 void (*recv)(const struct bt_mesh_hb_sub *sub, uint8_t hops,
90 uint16_t feat);
91
99 void (*sub_end)(const struct bt_mesh_hb_sub *sub);
100};
101
107
113
114extern struct bt_mesh_hb_cb hb_cb;
115
116#ifdef __cplusplus
117}
118#endif
123#endif /* _BLUETOOTH_MESH_HEARTBEAT_H_ */
void bt_mesh_hb_pub_get(struct bt_mesh_hb_pub *get)
Get the current Heartbeat publication parameters.
void bt_mesh_hb_sub_get(struct bt_mesh_hb_sub *get)
Get the current Heartbeat subscription parameters.
Definition heartbeat.h:74
void(* recv)(const struct bt_mesh_hb_sub *sub, uint8_t hops, uint16_t feat)
Receive callback for heartbeats.
Definition heartbeat.h:89
void(* sub_end)(const struct bt_mesh_hb_sub *sub)
Subscription end callback for heartbeats.
Definition heartbeat.h:99
Definition heartbeat.h:25
uint16_t feat
Definition heartbeat.h:38
uint32_t period
Definition heartbeat.h:42
uint16_t count
Definition heartbeat.h:29
uint8_t ttl
Definition heartbeat.h:31
uint16_t dst
Definition heartbeat.h:27
uint16_t net_idx
Definition heartbeat.h:40
Definition heartbeat.h:46
uint8_t max_hops
Definition heartbeat.h:70
uint16_t count
Definition heartbeat.h:56
uint8_t min_hops
Definition heartbeat.h:63
uint16_t dst
Definition heartbeat.h:54
uint32_t remaining
Definition heartbeat.h:50
uint32_t period
Definition heartbeat.h:48
uint16_t src
Definition heartbeat.h:52