A stack which works with or without an Mbed os library. Provides IPv4 or IPv6 with a full 1500 byte buffer.

Dependents:   heating gps

Files at this revision

API Documentation at this revision

Comitter:
andrewboyson
Date:
Fri Jan 11 16:06:08 2019 +0000
Parent:
105:ef2dd21d808c
Child:
107:cc58b4c2090b
Commit message:
Copied VN and poll from request to reply in NTP message handle

Changed in this revision

udp/ntp.c Show annotated file Show diff for this revision Revisions of this file
--- a/udp/ntp.c	Fri Jan 11 14:41:50 2019 +0000
+++ b/udp/ntp.c	Fri Jan 11 16:06:08 2019 +0000
@@ -112,10 +112,10 @@
     int      precision = NtpFunctionGetClockPrecision();
 
     pHeaderTx->Mode             = SERVER;
-    pHeaderTx->VN               = 3;
+    pHeaderTx->VN               = pHeaderRx->VN;
     pHeaderTx->LI               = li;
     pHeaderTx->Stratum          = stratum;
-    pHeaderTx->Poll             = 0;
+    pHeaderTx->Poll             = pHeaderRx->Poll;
     pHeaderTx->Precision        = precision;
     pHeaderTx->RootDelay        = 0;
     pHeaderTx->Dispersion       = 0;