Skip to content

Commit 2c83465

Browse files
authored
add more usage info
1 parent f69774d commit 2c83465

File tree

1 file changed

+22
-4
lines changed

1 file changed

+22
-4
lines changed

README.md

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,19 +51,26 @@ The examples below demonstrate how to switch between platforms.
5151

5252
### WiFi (ESP8266, M0 WINC1500, WICED)
5353

54+
If you are using the included examples, you do not need to change anything for the Adafruit WiFi Feathers. All WiFi based Feathers (ESP8266, M0 WiFi, WICED) will work with the examples out of the box.
55+
56+
### Cellular (32u4 FONA)
57+
58+
For FONA, you will only need to change from the default WiFi constructor to the FONA specific constructor. The rest of the sketch remains the same.
59+
60+
You will need to change these lines:
61+
5462
```ino
5563
#include "AdafruitIO_WiFi.h"
56-
AdafruitIO_WiFi io(IO_USERNAME, IO_KEY, "your_wifi_ssid", "your_wifi_pass");
64+
AdafruitIO_WiFi io(IO_USERNAME, IO_KEY, WIFI_SSID, WIFI_PASS);
5765
```
58-
59-
### Cellular (32u4 FONA)
66+
to this:
6067
6168
```ino
6269
#include "AdafruitIO_FONA.h"
6370
AdafruitIO_FONA io(IO_USERNAME, IO_KEY);
6471
```
6572

66-
If you need to set APN info, you can do so by adding a call to `io.setAPN()` after `io.connect()` in the `setup()` function.
73+
If your carrier requires APN info, you can set it by adding a call to `io.setAPN()` after `io.connect()` in the `setup()` function of the sketch.
6774

6875
```ino
6976
void setup() {
@@ -81,6 +88,17 @@ void setup() {
8188

8289
### Ethernet (Ethernet FeatherWing)
8390

91+
For Ethernet, you will only need to change from the default WiFi constructor to the Ethernet specific constructor. The rest of the sketch remains the same.
92+
93+
You will need to change these lines:
94+
95+
```ino
96+
#include "AdafruitIO_WiFi.h"
97+
AdafruitIO_WiFi io(IO_USERNAME, IO_KEY, WIFI_SSID, WIFI_PASS);
98+
```
99+
100+
to this:
101+
84102
```ino
85103
#include "AdafruitIO_Ethernet.h"
86104
AdafruitIO_Ethernet io(IO_USERNAME, IO_KEY);

0 commit comments

Comments
 (0)