To Be Determined. Not yet support RTC of HAL for W7500. Programs using NTPClient as like SMTP have some bug. We will update RTC APIs for HAL.

Dependencies:   WIZnetInterface mbed

Fork of NTPClient_HelloWorld by Donatien Garnier

Files at this revision

API Documentation at this revision

Comitter:
embeddist
Date:
Mon Jun 15 06:27:30 2015 +0000
Parent:
2:bf7dc5f5bca9
Child:
4:b7cbb0d0410c
Commit message:
On testing Beta mode. To Be Determined. Not yet support RTC of HAL for W7500. Programs using NTPClient as like SMTP have some bug. We will update RTC APIs for HAL.

Changed in this revision

EthernetInterface.lib Show diff for this revision Revisions of this file
NTPClient.lib Show annotated file Show diff for this revision Revisions of this file
WIZnetInterface.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed-rtos.lib Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
--- a/EthernetInterface.lib	Sun Aug 05 16:17:31 2012 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-http://mbed.org/users/mbed_official/code/EthernetInterface/#2a797ba9babe
--- a/NTPClient.lib	Sun Aug 05 16:17:31 2012 +0000
+++ b/NTPClient.lib	Mon Jun 15 06:27:30 2015 +0000
@@ -1,1 +1,1 @@
-http://mbed.org/users/donatien/code/NTPClient/#881559865a93
+http://developer.mbed.org/users/embeddist/code/NTPClient/#ebbc7816cfd9
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/WIZnetInterface.lib	Mon Jun 15 06:27:30 2015 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/embeddist/code/WIZnetInterface/#26df0dc6e227
--- a/main.cpp	Sun Aug 05 16:17:31 2012 +0000
+++ b/main.cpp	Mon Jun 15 06:27:30 2015 +0000
@@ -7,12 +7,16 @@
 
 int main() 
 {
-    eth.init(); //Use DHCP
+    uint8_t mac_addr[6] = {0x00, 0x08, 0xDC, 0x1D, 0x62, 0x11};
+    
+    //eth.init(); //Use DHCP
+    eth.init(mac_addr); //Use DHCP
 
     eth.connect();
-   
+    printf("IP Address is %s\n", eth.getIPAddress());
+    
     printf("Trying to update time...\r\n");
-    if (ntp.setTime("0.pool.ntp.org") == 0)
+    if (ntp.setTime("jp.pool.ntp.org") == 0)
     {
       printf("Set time successfully\r\n");
       time_t ctTime;
--- a/mbed-rtos.lib	Sun Aug 05 16:17:31 2012 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-http://mbed.org/users/mbed_official/code/mbed-rtos/#9654a71f5a90
--- a/mbed.bld	Sun Aug 05 16:17:31 2012 +0000
+++ b/mbed.bld	Mon Jun 15 06:27:30 2015 +0000
@@ -1,1 +1,1 @@
-http://mbed.org/users/mbed_official/code/mbed/builds/976df7c37ad5
\ No newline at end of file
+http://mbed.org/users/mbed_official/code/mbed/builds/7cff1c4259d7
\ No newline at end of file