|
1 | | -/* |
2 | | - * hackAIR Arduino Library |
3 | | - * Copyright © 2016-2017 hackAir Consortium |
4 | | - * |
5 | | - * This program is free software: you can redistribute it and/or modify |
6 | | - * it under the terms of the GNU Lesser General Public License as published |
7 | | - * by the Free Software Foundation, either version 3 of the License, or |
8 | | - * (at your option) any later version. |
9 | | - * |
10 | | - * This program is distributed in the hope that it will be useful, |
11 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | | - * GNU Lesser General Public License for more details. |
14 | | - * |
15 | | - * You should have received a copy of the GNU Lesser General Public License |
16 | | - * along with this program. If not, see <http://www.gnu.org/licenses/>. |
17 | | - */ |
18 | | - |
19 | 1 | /** |
20 | | - * @file Ethernet node example sketch |
| 2 | + * @file Ethernet - Simple Example |
| 3 | + * This example sets up the Ethernet shield and sends data to the hackAIR |
| 4 | + * platform every one minute. |
| 5 | + * |
21 | 6 | * @author Thanasis Georgiou |
| 7 | + * |
| 8 | + * This example is part of the hackAIR Arduino Library and is available |
| 9 | + * in the Public Domain. |
22 | 10 | */ |
23 | 11 |
|
24 | 12 | #include <Ethernet.h> |
25 | 13 | #include "hackair.h" |
26 | 14 | #include "hackair_ethernet.h" |
27 | 15 |
|
28 | 16 | // MAC Address of the Ethernet Shield |
29 | | -// Nnewer shields should have a MAC address printed on a sticker |
| 17 | +// Shields have a MAC address printed on a sticker |
30 | 18 | byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED }; |
31 | 19 |
|
32 | 20 | // Initialize the Ethernet client library and the hackAir helper class |
@@ -56,6 +44,7 @@ void setup() { |
56 | 44 |
|
57 | 45 | void loop() { |
58 | 46 | // Check DHCP lease |
| 47 | + // This is required to maintain the internet connection for long periods of time |
59 | 48 | Ethernet.maintain(); |
60 | 49 |
|
61 | 50 | // Collect data |
|
0 commit comments