Loading...
Searching...
No Matches
skald.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2018 Freie Universit├Ąt Berlin
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
44#ifndef NET_SKALD_H
45#define NET_SKALD_H
46
47#include <stdint.h>
48
49#include "ztimer.h"
50#include "net/ble.h"
51#include "net/netdev/ble.h"
52
53#ifdef __cplusplus
54extern "C" {
55#endif
56
60#ifndef SKALD_ADV_CHAN
61#define SKALD_ADV_CHAN { 37, 38, 39 }
62#endif
63
67typedef struct {
68 uint8_t u8[16];
70
81
85void skald_init(void);
86
96
103
111void skald_generate_random_addr(uint8_t *buf);
112
113#ifdef __cplusplus
114}
115#endif
116
117#endif /* NET_SKALD_H */
BLE specific adaption for the Netdev API.
void skald_adv_start(skald_ctx_t *ctx)
Start advertising the given packet.
void skald_init(void)
Initialize Skald and the underlying radio.
void skald_generate_random_addr(uint8_t *buf)
Generate a random public address.
void skald_adv_stop(skald_ctx_t *ctx)
Stop the ongoing advertisement.
uint32_t ztimer_now_t
type for ztimer_now() result
Definition ztimer.h:323
BLE packet structure (as defined by the BLE standard)
Definition ble.h:104
Advertising context holding the advertising data and state.
Definition skald.h:74
ztimer_t timer
timer for scheduling advertising events
Definition skald.h:76
uint32_t adv_itvl_ms
advertising interval [ms]
Definition skald.h:79
uint8_t cur_chan
keep track of advertising channels
Definition skald.h:78
netdev_ble_pkt_t pkt
packet holding the advertisement (GAP) data
Definition skald.h:75
ztimer_now_t last
last timer trigger (for offset compensation)
Definition skald.h:77
UUID representation format used by Skald.
Definition skald.h:67
ztimer structure
Definition ztimer.h:332
General BLE values as defined by the BT standard.
ztimer API