platypush/plugins/esp/__init__.py
def deep_sleep(self, seconds: Optional[float] = None, **kwargs):
        """
        Stops execution in an attempt to enter a low power state.
        A deepsleep may not retain RAM or any other state of the system (for example peripherals or network interfaces).
        Upon wake execution is resumed from the main script, similar to a hard or power-on reset.

        :param seconds: Sleep seconds (default: sleep until there are some PIN/RTC events to process)
        :param kwargs: Parameters to pass to :meth:`platypush.plugins.esp.EspPlugin.execute`.
        """
        code = '''
import machine
machine.deepsleep({msec})
'''.format(msec=int(seconds * 1000) if seconds else '')

        return self.execute(code, wait_response=False, **kwargs).output

        Stops execution in an attempt to enter a low power state.
        A deepsleep may not retain RAM or any other state of the system (for example peripherals or network interfaces).
        Upon wake execution is resumed from the main script, similar to a hard or power-on reset.

        :param seconds: Sleep seconds (default: sleep until there are some PIN/RTC events to process)
        :param kwargs: Parameters to pass to :meth:`platypush.plugins.esp.EspPlugin.execute`.
        
Stops execution in an attempt to enter a low power state.
A deepsleep may not retain RAM or any other state of the system (for example peripherals or network interfaces).
Upon wake execution is resumed from the main script, similar to a hard or power-on reset.
Stops execution in an attempt to enter a low power state . A deepsleep may not retain RAM or any other state of the system ( for example peripherals or network interfaces ) . Upon wake execution is resumed from the main script similar to a hard or power - on reset .
def deep_sleep(self, seconds: Optional[float] = None, **kwargs):
        code = '''
import machine
machine.deepsleep({msec})
'''.format(msec=int(seconds * 1000) if seconds else '')
        return self.execute(code, wait_response=False, **kwargs).output
def deep_sleep ( self , seconds : Optional [ float ] = None , ** kwargs ) : code = '''
import machine
machine.deepsleep({msec})
''' . format ( msec = int ( seconds * 1000 ) if seconds else '' ) return self . execute ( code , wait_response = False , ** kwargs ) . output
Stops execution in an attempt to enter a low power state.
Stops execution in an attempt to enter a low power state .
"""
        Stops execution in an attempt to enter a low power state.
        A deepsleep may not retain RAM or any other state of the system (for example peripherals or network interfaces).
        Upon wake execution is resumed from the main script, similar to a hard or power-on reset.

        :param seconds: Sleep seconds (default: sleep until there are some PIN/RTC events to process)
        :param kwargs: Parameters to pass to :meth:`platypush.plugins.esp.EspPlugin.execute`.
        """
self
seconds
Optional[float]
Sleep seconds (default: sleep until there are some PIN/RTC events to process)
Sleep seconds ( default : sleep until there are some PIN / RTC events to process )
kwargs
Parameters to pass to :meth:`platypush.plugins.esp.EspPlugin.execute`.
Parameters to pass to : meth : ` platypush . plugins . esp . EspPlugin . execute ` .