SNTP
[User Protocols]

Simple network time protocol. More...

Collaboration diagram for SNTP:

Defines

#define NTP_PORT   123
#define SNTP_PORT   NTP_PORT

Functions

void SNTP_resync (void *arg)
int NutSNTPGetTime (uint32_t *server_adr, time_t *t)
int NutSNTPStartThread (uint32_t server_addr, uint32_t interval)

Detailed Description

Simple network time protocol.

Todo:
Enhance documentation.

Define Documentation

#define NTP_PORT   123

Definition at line 126 of file sntp.c.

#define SNTP_PORT   NTP_PORT

Definition at line 127 of file sntp.c.

Referenced by NutSNTPGetTime().


Function Documentation

void SNTP_resync ( void *  arg  ) 

Definition at line 134 of file sntp.c.

References free, NutSleep(), NutSNTPGetTime(), NutThreadSetPriority(), and stime().

Referenced by NutSNTPStartThread().

int NutSNTPGetTime ( uint32_t server_adr,
time_t t 
)
int NutSNTPStartThread ( uint32_t  server_addr,
uint32_t  interval 
)

Definition at line 221 of file sntp.c.

References free, malloc, NUT_THREAD_STACK_ADD, NutThreadCreate(), and SNTP_resync().


© 2000-2007 by egnite Software GmbH - visit http://www.ethernut.de/