- 21 Apr, 2016 1 commit
-
-
Damien George authored
Use the machine.deepsleep() function to enter the sleep mode. Use the RTC to configure the alarm to wake the device. Basic use is the following: import machine # configure RTC's ALARM0 to wake device from deep sleep rtc = machine.RTC() rtc.irq(trigger=rtc.ALARM0, wake=machine.DEEPSLEEP) # do other things # ... # set ALARM0's alarm to wake after 10 seconds rtc.alarm(rtc.ALARM0, 10000) # enter deep-sleep state (system is reset upon waking) machine.deepsleep() To detect if the system woke from a deep sleep use: if machine.reset_cause() == machine.DEEPSLEEP_RESET: print('woke from deep sleep')
-
- 20 Apr, 2016 3 commits
-
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
Flash size as seen by vendor SDK doesn't depend on real size, but rather on a particular value in firmware header, as put there by flash tool. That means it's user responsibility to know what flash size a particular device has, and specify correct parameters during flashing. That's not end user friendly however, so we try to make it "flash and play" by detecting real size vs from-header size mismatch, and correct the header accordingly.
-
Paul Sokolovsky authored
-
- 19 Apr, 2016 2 commits
-
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
-
- 18 Apr, 2016 2 commits
-
-
Paul Sokolovsky authored
There's no space for it.
-
Paul Sokolovsky authored
Returns FlashROM size in bytes from vendor SDK's point of view, not physical size.
-
- 17 Apr, 2016 6 commits
-
-
Paul Sokolovsky authored
-
Damien George authored
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
Should be called to notify that current dupterm object has more input data to read.
-
- 16 Apr, 2016 1 commit
-
-
Damien George authored
-
- 15 Apr, 2016 1 commit
-
-
Paul Sokolovsky authored
-
- 14 Apr, 2016 11 commits
-
-
Damien George authored
-
Damien George authored
"" is the correct name of the root directory when mounting a device there (as opposed to "/"). One can now do os.listdir('/') and open('/abc'), as well as os.listdir() and open('abc').
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
These are *defined* per-port, but why redeclare them again and again.
-
Paul Sokolovsky authored
A shortcut for users to provide background diagnostic info for bug reports.
-
Paul Sokolovsky authored
-
Damien George authored
esponewire.c contains low-level timing-critical functions that go in iRAM. modonewire.c contains Python wrapper code.
-
Damien George authored
-
Damien George authored
Now pins can be easily looked up in the table using the pin number as the index and vice versa.
-
Damien George authored
This field is the same as phys_port and not needed.
-
- 13 Apr, 2016 4 commits
-
-
Damien George authored
The config variable MICROPY_MODULE_FROZEN is now made of two separate parts: MICROPY_MODULE_FROZEN_STR and MICROPY_MODULE_FROZEN_MPY. This allows to have none, either or both of frozen strings and frozen mpy files (aka frozen bytecode).
-
Paul Sokolovsky authored
First deactivate, then print diagnostic message.
-
Paul Sokolovsky authored
The idea is that if dupterm object can handle exceptions, it will handle them itself. Otherwise, object state can be compromised and it's better to terminate dupterm session. For example, disconnected socket will keep throwing exceptions and dump messages about that.
-
Paul Sokolovsky authored
By default it uses mp_plat_print, but a port may override it to another value with MICROPY_DEBUG_PRINTER_DEST.
-
- 12 Apr, 2016 5 commits
-
-
Damien George authored
nlr_pop must be called if no exception was raised. Also, return value of these callback helpers is made void because ther is (currently) no use for it.
-
Damien George authored
-
Damien George authored
-
Damien George authored
-
Damien George authored
Also include py/obj.h so the header is self contained.
-
- 11 Apr, 2016 4 commits
-
-
Damien George authored
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
Main entry point is _boot.py which checks whether FAT FS in flash mountable, and if so, mounts it. Otherwise, it checks if flash is empty, and if so, performs initial module setup: makes FAT FS, configures default AP name, etc. As a last option, if flash is not empty, and could not be mounted, it means filesystem corruption, and warning message with instructions is printed in an infinite loop.
-
Paul Sokolovsky authored
-