pulkin / micropython

MicroPython implementation on Ai-Thinker GPRS module A9 (RDA8955)
https://micropython.org
MIT License
103 stars 30 forks source link

machine.set_idle() argument #98

Closed marcosasilvalepe closed 3 years ago

marcosasilvalepe commented 3 years ago

Hi! I tried to put the module to sleep using machine.idle() but it throws "the object has no attribute idle" error.

Checking the attributes of machine, the method listed is machine.set_idle(). It takes an argument but no idea the type of argument it should be.

Supplying an int or boolean doesn't throw any errors.

Are there any examples on how to use this method and checking the status of cpu frequency being used ?

bokolob commented 3 years ago

It’s true/false argument - to enable/disable idle mode respectively

marcosasilvalepe commented 3 years ago

Thanks!!