Update docstrings

This commit is contained in:
George Waters 2020-09-09 10:34:05 -04:00
parent aef2e8115f
commit b756ef243e
No known key found for this signature in database
GPG key ID: D993F8B1CC21DB25

View file

@ -201,7 +201,7 @@ class PN532:
raise NotImplementedError raise NotImplementedError
def reset(self): def reset(self):
"""Perform a hardware reset toggle""" """Perform a hardware reset toggle and then wake up the PN532"""
if self._reset_pin: if self._reset_pin:
if self.debug: if self.debug:
print("Resetting") print("Resetting")
@ -339,6 +339,10 @@ class PN532:
return response[2:] return response[2:]
def power_down(self): def power_down(self):
"""Put the PN532 into a low power state. If the reset pin is connected a
hard power down is performed, if not, a soft power down is performed
instead. Returns True if the PN532 was powered down successfully or
False if not."""
if self._reset_pin: # Hard Power Down if the reset pin is connected if self._reset_pin: # Hard Power Down if the reset pin is connected
self._reset_pin.value = False self._reset_pin.value = False
self.low_power = True self.low_power = True