Zephyr API Documentation 4.2.99
A Scalable Open Source RTOS
 4.2.99
latmon.h
Go to the documentation of this file.
1
4
5/*
6 * Copyright (c) 2025 Jorge A. Ramirez Ortiz <jorge.ramirez@oss.qualcomm.com>
7 *
8 * SPDX-License-Identifier: Apache-2.0
9 */
10
11#ifndef ZEPHYR_INCLUDE_NET_LATMON_H_
12#define ZEPHYR_INCLUDE_NET_LATMON_H_
13
14#include <zephyr/kernel.h>
15#include <zephyr/net/net_ip.h>
16
17#ifdef __cplusplus
18extern "C" {
19#endif
20
27
35typedef int (*net_latmon_measure_t)(uint32_t *delta);
36
47void net_latmon_start(int latmus, net_latmon_measure_t measure_func);
48
62int net_latmon_connect(int socket, struct in_addr *ip);
63
76int net_latmon_get_socket(struct sockaddr *bind_addr);
77
88
92
93#ifdef __cplusplus
94}
95#endif
96
97#endif /* ZEPHYR_INCLUDE_NET_LATMON_H_ */
int(* net_latmon_measure_t)(uint32_t *delta)
Callback function type for retrieving latency deltas.
Definition latmon.h:35
int net_latmon_get_socket(struct sockaddr *bind_addr)
Get a socket for the Latmus service.
void net_latmon_start(int latmus, net_latmon_measure_t measure_func)
Start the latency monitor.
bool net_latmon_running(void)
Check if the latency monitor is running.
int net_latmon_connect(int socket, struct in_addr *ip)
Wait for a connection from a Latmus client.
Public kernel APIs.
IPv6 and IPv4 definitions.
int socket(int family, int type, int proto)
__UINT32_TYPE__ uint32_t
Definition stdint.h:90
IPv4 address struct.
Definition net_ip.h:155
Generic sockaddr struct.
Definition net_ip.h:410