nRF WiFi
Toggle main menu visibility
Loading...
Searching...
No Matches
util.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2024 Nordic Semiconductor ASA
3
*
4
* SPDX-License-Identifier: BSD-3-Clause
5
*/
6
11
12
#ifndef __UTIL_H__
13
#define __UTIL_H__
14
15
#include "
osal_api.h
"
16
17
#include "
host_rpu_umac_if.h
"
18
19
#ifndef ARRAY_SIZE
20
#define ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0]))
21
#endif
22
23
/* Convert power from mBm to dBm */
24
#define MBM_TO_DBM(gain) ((gain) / 100)
25
26
int
nrf_wifi_utils_hex_str_to_val
(
unsigned
char
*hex_arr,
27
unsigned
int
hex_arr_sz,
28
unsigned
char
*str);
29
30
bool
nrf_wifi_utils_is_mac_addr_valid
(
const
char
*
mac_addr
);
31
32
int
nrf_wifi_utils_chan_to_freq
(
enum
nrf_wifi_band
band
,
33
unsigned
short
chan
);
34
#endif
/* __UTIL_H__ */
nrf_wifi_band
nrf_wifi_band
Represents the values that can be used to specify the frequency band.
Definition
host_rpu_umac_if.h:261
mac_addr
unsigned char mac_addr[6]
Definition
host_rpu_data_if.h:7
chan
struct chan_params chan
Definition
host_rpu_sys_if.h:5
band
signed int band
Definition
host_rpu_umac_if.h:3
host_rpu_umac_if.h
osal_api.h
nrf_wifi_utils_hex_str_to_val
int nrf_wifi_utils_hex_str_to_val(unsigned char *hex_arr, unsigned int hex_arr_sz, unsigned char *str)
nrf_wifi_utils_is_mac_addr_valid
bool nrf_wifi_utils_is_mac_addr_valid(const char *mac_addr)
nrf_wifi_utils_chan_to_freq
int nrf_wifi_utils_chan_to_freq(enum nrf_wifi_band band, unsigned short chan)
utils
inc
util.h
Generated on
for nRF WiFi by
1.17.0