Home
last modified time | relevance | path

Searched refs:sntp_ctx (Results 1 – 4 of 4) sorted by relevance

/Zephyr-latest/include/zephyr/net/
Dsntp.h43 struct sntp_ctx { struct
69 int sntp_init(struct sntp_ctx *ctx, struct sockaddr *addr, argument
82 int sntp_query(struct sntp_ctx *ctx, uint32_t timeout, struct sntp_time *ts);
94 int sntp_recv_response(struct sntp_ctx *ctx, uint32_t timeout, struct sntp_time *ts);
101 void sntp_close(struct sntp_ctx *ctx);
115 int sntp_init_async(struct sntp_ctx *ctx, struct sockaddr *addr, socklen_t addr_len,
125 int sntp_send_async(struct sntp_ctx *ctx);
/Zephyr-latest/subsys/net/lib/sntp/
Dsntp_simple.c16 struct sntp_ctx sntp_ctx; in sntp_simple_helper() local
21 res = sntp_init(&sntp_ctx, addr, addr_len); in sntp_simple_helper()
37 res = sntp_query(&sntp_ctx, iter_timeout, ts); in sntp_simple_helper()
48 res = sntp_recv_response(&sntp_ctx, iter_timeout, ts); in sntp_simple_helper()
69 sntp_close(&sntp_ctx); in sntp_simple_helper()
Dsntp.c155 int sntp_init(struct sntp_ctx *ctx, struct sockaddr *addr, socklen_t addr_len) in sntp_init()
163 memset(ctx, 0, sizeof(struct sntp_ctx)); in sntp_init()
185 static int sntp_query_send(struct sntp_ctx *ctx) in sntp_query_send()
203 int sntp_query(struct sntp_ctx *ctx, uint32_t timeout, struct sntp_time *ts) in sntp_query()
220 int sntp_recv_response(struct sntp_ctx *ctx, uint32_t timeout, in sntp_recv_response()
252 void sntp_close(struct sntp_ctx *ctx) in sntp_close()
261 int sntp_init_async(struct sntp_ctx *ctx, struct sockaddr *addr, socklen_t addr_len, in sntp_init_async()
285 int sntp_send_async(struct sntp_ctx *ctx) in sntp_send_async()
303 struct sntp_ctx *ctx = event->user_data; in sntp_read_async()
321 struct sntp_ctx *ctx = service->pev->user_data; in sntp_close_async()
/Zephyr-latest/samples/net/sockets/sntp_client/src/
Dmain.c78 struct sntp_ctx ctx; in do_sntp()