Skip to content

Commit c2b359d

Browse files
committed
add io.disconnect()
just calls the network _disconnect()
1 parent 6201370 commit c2b359d

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

src/AdafruitIO.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,21 @@ void AdafruitIO::connect()
160160

161161
}
162162

163+
/**************************************************************************/
164+
/*!
165+
@brief Disconnects from AIO.
166+
@return none
167+
*/
168+
/**************************************************************************/
169+
void AdafruitIO::disconnect()
170+
{
171+
172+
AIO_DEBUG_PRINTLN("AdafruitIO::disconnect()");
173+
174+
_disconnect();
175+
176+
}
177+
163178

164179
/**************************************************************************/
165180
/*!

src/AdafruitIO.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ class AdafruitIO {
5353
virtual ~AdafruitIO();
5454

5555
void connect();
56+
void disconnect();
5657
aio_status_t run(uint16_t busywait_ms = 0, bool fail_fast = false);
5758

5859
AdafruitIO_Feed* feed(const char *name);

0 commit comments

Comments
 (0)