Alix Germany / Mbed OS Coursework_Version_8

Dependencies:   BMP280 ELEC350-Practicals-FZ429 TextLCD BME280 ntp-client

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers Initialization.hpp Source File

Initialization.hpp

00001 #ifndef __Initialization__
00002 #define __Initialization__
00003 
00004 #include "mbed.h"
00005 #include "EthernetInterface.h"
00006 #include "ntp-client/NTPClient.h"
00007 
00008 
00009 #define IP        "10.0.0.10" 
00010 
00011 #define NETMASK   "255.0.0.0" 
00012 
00013 #define GATEWAY   "10.0.0.2" 
00014 
00015 
00016 EthernetInterface eth; 
00017 
00018 eth.set_network(IP, NETMASK, GATEWAY); 
00019 
00020 eth.connect(); 
00021     
00022 NTPClient ntp(&eth);
00023 
00024 
00025 
00026 #endif