Sothiscouldbevaluablebecauseyoucanputthis, aren't weknow, youknow, withWiFionyournetwork, andthenyoucanhaveitpingdifferentserversordifferent I P addressestoseeiftheyarereachable.
I'llshowyouwhat's requiredforthisparticularproject, asfarasHardwareisconcernedthat I willshowyouthecodeandthenwe'llbringitalltogethertoshowyouhowthisworks.
Soifyou'regoingtobepinging a fullfledgeddomainnamessuchaswwwdotgoogledotcomwwwdotelithecomputerguydotcomwwwdotsalesforcedotcom.
Forthat, you'regoingtocallit a string.
Domakesureyouputthatuppercase s stringandthenyou'regoingtosaythenameforthevariable.
Soforme, I justputthisashostin a sostrangehostnameequals.
Rememberthedoublequotationmarks, a doublequotationmarksandthenpluginoneofthedomainnameishereandthenclosethedoublequotationmarks.
And, ofcourse, to a semicolon.
Thenwe'regonnagodown, andwe'realsogoingtobepinging a local I p address.
Somyparticularcomputerhere, I'm goingtohavetheArduino, youknow, pingingthisandthereasonwe'regonnadothisis I wasgoingtoactuallyshowyouwhen I turnoffthenetworkconnectiononthisparticularcomputer.
Soyoucanseewhattheresultsare.
Soopinionand I p addressYou'regoingtopluginthis, so I p a dress.
So I p addressspaceandthenwhateveryouwannacallthevariableforthe i p address.
Sothisissimplygoingto a localservernowrealizethereisnoequalhere, sobasicallyjustlocalserver.
Sothisisthisisthevariablenamedlocalserverandthenwe'regoingtoputinthe I p.
WhilestatusisdoesnotequalconnectedserialprintattemptingconnectornetworknamedtestandthenstatusequalsAndthewife I doubtbeginfunctionsofthisfunctionfeeds E s s I.
Is, andthenwe'llprintoutwhatthe i p addressesagain.
Thisisanimportantthingwhenyou'redoinganykindofworkwith, AreweknowwhoknowswithWiFioranykindofArduino, youknow, withsomekindofnetworkconnectionishavingitprintoutwiththehelpits I P addressescouldbe a valuablethingfortryingtodosometroubleshooting.
Andthenitsendsyouanemailnotificationsaying, Hey, youprobablywanttotake a lookatthisbecausepeopleareabouttostartcomplaining.
Soit's simpletoolslikethis, right?
Youcanuse a simplejustthatsimple.
Youknow, oldpingutilityusePing.
YouuseArduino.
Youknow, withthatwithWiFi, headds.
A melodyis, headds, somebellsandwhistles, andallof a suddenyoucanget a valuabletoolthatcouldjustmakesurethatyoursystemsareworking, howthey'resupposedtowork.