From 236f40d09de6212fb306b4417317f85fe7aea47e Mon Sep 17 00:00:00 2001 From: Daniel Campora Date: Wed, 4 Nov 2015 13:50:33 +0100 Subject: [PATCH] Add notes about WLAN and WDT constructor that can be used to retrieve the existing instance(s). --- Hardware-API.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Hardware-API.md b/Hardware-API.md index 0c1651c..dfd4ed9 100644 --- a/Hardware-API.md +++ b/Hardware-API.md @@ -371,6 +371,9 @@ Methods: - `wdt.feed()` feed the watchdog. - `wdt.deinit()` disable the WDT (again, might not be possible on some platforms, raise `OSError` in that case). +**Note:** +_danicampora_: Just as WLAN below, I think it should be possible to retrieve the existing WDT instance when calling the constructor with no params besides the id. + ## The WLAN class The WLAN class belongs to the network module. @@ -379,6 +382,10 @@ Constructor: `wlan = WLAN(id, mode=WLAN.STA, *, ssid='wlan', auth=None, channel=1, iface=None)` +**Note:** +Since WLAN might be a system feature of the platform (this is the case of the WiPy and the ESP8266), +calling the constructor without params (besides the id) will return the existing WLAN object. + Methods: - `wlan.init()` re-init.