summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-04-03esp8266: Switch back to flashing combined firmware (single file).Paul Sokolovsky
With gap between segments minimized, there's not much padding to flash, so no big speed overhead.
2016-04-03esp8266: Minimize gap between Inst/DataRAM segments and FlashROM segment.Paul Sokolovsky
With .rodata being in FlashROM now, gap can be much smaller now. InstRAM can be max 32K, and with segment headers, that already makes it more than 32K. Then there's some .data still, and the next Flash page boundary is 0x9000. That figure should be more or less future-proof. TODO: Refactor makeimg to take FlashROM segment offset from file name.
2016-04-03esp8266/ets_alt_task: Comment out debug output.Paul Sokolovsky
2016-04-03esp8266: Bump iROM size to 512k.Paul Sokolovsky
Needed for frozen scripts, and for future growth of binary.
2016-04-03esp8266: Move .rodata where it belongs with -mforce-l32 help.Paul Sokolovsky
2016-04-03docs: Update copyright notice.Paul Sokolovsky
2016-04-03esp8266/README: Add link to docs.Paul Sokolovsky
2016-04-02examples/http_client_ssl.py: HTTPS client example.Paul Sokolovsky
2016-04-02examples/http_server.py: Bind to 0.0.0.0, to be accessible from other hosts.Paul Sokolovsky
This is helpful when running on deeply embedded targets, but may be "security risk". Caveat emptor.
2016-04-02examples/http_server.py: Introduce main() function.Paul Sokolovsky
Allows to re-run code if it was imported as a module (e.g., on bare-metal ports).
2016-04-02examples/http_server.py: Refactor/simplify for Python 3.5.Paul Sokolovsky
2016-04-02examples/http_client.py: Introduce main() function.Paul Sokolovsky
Allows to re-run code if it was imported as a module (e.g., on bare-metal ports).
2016-04-02examples/http_client.py: Improve CPython compatibility in stream mode.Paul Sokolovsky
2016-04-02unix/file: "encoding" arg to open() isn't kw-only.Paul Sokolovsky
And with "buffering" arg introduced, it's non possible to make it non-kwonly.
2016-04-02unix/file: Parse "buffering" argument of open() builtin.Paul Sokolovsky
It's ignored (unbuffered, raw I/O is used), but least makes it compatible with CPython.
2016-04-02esp8266: Use VM_HOOK to call ets_loop_iter within the VM.Damien George
Starting with a divisor of 10, pystone_lowmem gives a score of 256.
2016-04-01example/http_client.py: Remove unused code.Paul Sokolovsky
2016-04-01examples: http_client.py, http_server.py aren't just unix, move to network/.Paul Sokolovsky
2016-04-01py/map: Prevent map resize failure from destroying map.Stephen Kyle
2016-04-01esp8266/uart: Get ctrl-C working now that event-based REPL is disabled.Damien George
2016-04-01esp8266/uart: Comment out old, unused rx buffering code.Damien George
This was originally used for non-event based REPL processing. Then it was unused when event-based processing was activated. But now that event based is disabled, and non-event based is back, there has been new ring buffer code to process the chars.
2016-04-01esp8266: Switch to non event-driven REPL to support paste mode.Paul Sokolovsky
2016-04-01esp8266: Support dedicated REPL loop (aka pull-style).Paul Sokolovsky
Event-driven loop (push-style) is still supported and default (controlled by MICROPY_REPL_EVENT_DRIVEN setting, as expected). Dedicated loop worked even without adding ets_loop_iter(), though that needs to be revisited later.
2016-04-01esp8266: Disallow recursive calls to REPL.Paul Sokolovsky
Before this change, if REPL blocked executing some code, it was possible to still input new statememts and excuting them, all leading to weird, and portentially dangerous interaction. TODO: Current implementation may have issues processing input accumulated while REPL was blocked.
2016-04-01unix: implement -i option (inspect - start REPL after script is finished)Pavol Rusnak
2016-04-01esp8266: Move PHY mode constants from modesp to modnetwork.Paul Sokolovsky
2016-03-31esp8266: Reset term_obj on reboot.Damien George
Also, term_obj can be NULL if socket enables REPL duplication signalling before os.dupterm is called, so it should be checked.
2016-03-31esp8266: Implement input part of dupterm handling.Paul Sokolovsky
The idea is following: underlying interrupt-driven or push-style data source signals that more data is available for dupterm processing via call to mp_hal_signal_dupterm_input(). This triggers a task which pumps data between actual dupterm object (which may perform additional processing on data from low-level data source) and input ring buffer.
2016-03-30esp8266: Switch back to accumulating input data via ring buffer.Paul Sokolovsky
But now it's generic ring buffer implemented via ringbuf.h, and is intended for any type of input, including dupterm's, not just UART. The general process work like this: an interrupt-driven input source puts data into input_buf, and then signals new data available via call to mp_hal_signal_input().
2016-03-30esp8266: Fix issue when current repl line was garbage-collected.Paul Sokolovsky
Reference it from root pointers section.
2016-03-30py/ringbuf.h: Add reusable ring buffer class.Paul Sokolovsky
Features inline get/put operations for the highest performance. Locking is not part of implementation, operation should be wrapped with locking externally as needed.
2016-03-30docs: network: esp8266: .scan() is now synchronous and returns result list.Paul Sokolovsky
2016-03-30docs: network: esp8266: status is WLAN object method.Paul Sokolovsky
2016-03-30esp8266: Support synchronous wifi scanning.Damien George
That is: aps = if0.scan() TODO: make sure that returned list has tuple with values in "standard" order (whatever that standard is).
2016-03-29py/parsenum: Use pow function to apply exponent to decimal number.Damien George
Pow is already a dependency when compiling with floats, so may as well use it here to reduce code size and speed up the conversion for most cases.
2016-03-29py/formatfloat: Fix further cases of buffer overflow in formatting.Damien George
Includes extensive test cases to catch hopefully all cases where buffer might overflow.
2016-03-29py/formatfloat: Fix case of float format where leading digit was "10".Damien George
When taking the logarithm of the float to determine the exponent, there are some edge cases that finish the log loop too large. Eg for an input value of 1e32-epsilon, this is actually less than 1e32 from the log-loop table and finishes as 10.0e31 when it should be 1.0e32. It is thus rendered as :e32 (: comes after 9 in ascii). There was the same problem with numbers less than 1.
2016-03-29esp8266: Reduce heap size for now to avoid random segfaults on WiFi connect.Paul Sokolovsky
2016-03-29esp8266: Let esp8266 "os" messages go to standard (REPL) UART.Paul Sokolovsky
That's definitely helpful for debugging.
2016-03-29esp8266/esp_mphal: Add support for debug UART-only output.Paul Sokolovsky
Helpful when debugging dupterm support (because otherwise all output is spooled to dupterm too). To use: mp_printf(&mp_debug_print, "...");
2016-03-29esp8266: Enable uos.dupterm() method.Paul Sokolovsky
2016-03-29esp8266: Add basic support for duplicating REPL output.Paul Sokolovsky
2016-03-29esp8266: Implement os.urandom function.Damien George
Uses what is suspected to be a hardware random number generator.
2016-03-28esp8266: Allow to build without FatFs support again.Paul Sokolovsky
2016-03-28esp8266: Support importing modules from filesystem.Paul Sokolovsky
2016-03-28docs: Correct pin interrupt example code for the WiPy.danicampora
2016-03-28esp8266: Zero out fs_user_mount state on (soft) reset.Damien George
Otherwise device stays mounted on soft reset and leads to corruption (since block device object is now gone).
2016-03-28esp8266/moduos: Add os.remove(), proxying to VFS object.Paul Sokolovsky
2016-03-28esp8266/moduos: Factor out VFS method proxy helper.Paul Sokolovsky
2016-03-28esp8266/moduos: Add listdir() proxy for MP_STATE_PORT(fs_user_mount)[0].Paul Sokolovsky
I.e. os.listdir(...) will redirect to MP_STATE_PORT(fs_user_mount)[0].listdir(...).