aboutsummaryrefslogtreecommitdiff
path: root/stmhal/moduos.c
AgeCommit message (Collapse)Author
2017-09-06ports: Make new ports/ sub-directory and move all ports there.Damien George
This is to keep the top-level directory clean, to make it clear what is core and what is a port, and to allow the repository to grow with new ports in a sustainable way.
2017-08-30all: Convert remaining "mp_uint_t n_args" to "size_t n_args".Damien George
This is to have consistency across the whole repository.
2017-08-13all: Raise exceptions via mp_raise_XXXJavier Candeira
- Changed: ValueError, TypeError, NotImplementedError - OSError invocations unchanged, because the corresponding utility function takes ints, not strings like the long form invocation. - OverflowError, IndexError and RuntimeError etc. not changed for now until we decide whether to add new utility functions.
2017-07-31all: Use the name MicroPython consistently in commentsAlexander Steffen
There were several different spellings of MicroPython present in comments, when there should be only one.
2017-05-10ports: Add ilistdir in uos module.Damien George
2017-05-06stmhal: Convert all module and method tables to use MP_ROM macros.Damien George
2017-03-31all: Use full path name when including mp-readline/timeutils/netutils.Damien George
This follows the pattern of how all other headers are now included, and makes it explicit where the header file comes from. This patch also removes -I options from Makefile's that specify the mp-readline/timeutils/ netutils directories, which are no longer needed.
2017-01-29stmhal/moduos: Remove duplicated chdir.Damien George
2017-01-27stmhal: Convert to use VFS sub-system and new ooFatFs component.Damien George
This patch makes the following configuration changes: - MICROPY_FSUSERMOUNT is disabled, removing old mounting infrastructure - MICROPY_VFS is enabled, giving new VFS sub-system - MICROPY_VFS_FAT is enabled, giving uos.VfsFat type - MICROPY_FATFS_OO is enabled, to use new ooFatFs lib, R0.12b User facing API should be almost unchanged. Most notable changes are removal of os.mkfs (use os.VfsFat.mkfs instead) and pyb.mount doesn't allow unmounting by passing None as the device.
2017-01-27extmod: Rename vfs_fat_file.h to vfs_fat.h.Damien George
And move declaration of mp_fat_vfs_type to this file.
2016-12-02stmhal/moduos: Implement POSIX behaviour of rename, allow to overwrite.Damien George
2016-10-07stmhal: Use mp_raise_OSError helper function.Damien George
2016-10-05stmhal/moduos: Implement total-number-of-blocks field in statvfs.Damien George
2016-09-22all: Remove 'name' member from mp_obj_module_t struct.Damien George
One can instead lookup __name__ in the modules dict to get the value.
2016-05-29stmhal/moduos: getcwd(): Use mp_obj_new_exception_arg1().Paul Sokolovsky
Argument types were converted, but old function call of mp_obj_new_exception_msg_varg() remained.
2016-02-28extmod/vfs_fat: Move listdir() method from stmhal for reuse.Paul Sokolovsky
2016-02-15extmod/vfs_fat_file: Reusable FatFs module, move from stmhal/file.Paul Sokolovsky
2016-02-10extmod/fsusermount: Support mounting of multiple block devices.Damien George
This patch adds support to fsusermount for multiple block devices (instead of just one). The maximum allowed is fixed at compile time by the size of the fs_user_mount array accessed via MP_STATE_PORT, which in turn is set by MICROPY_FATFS_VOLUMES. With this patch, stmhal (which is still tightly coupled to fsusermount) is also modified to support mounting multiple devices And the flash and SD card are now just two block devices that are mounted at start up if they exist (and they have special native code to make them more efficient).
2016-02-10stmhal: Add mount/umount/mkfs to os module.Damien George
2016-01-19stmhal: Add os.statvfsDave Hylands
Implement enough of statvfs to determine the amount of free space on a volume.
2015-11-25extmod: Move fsusermount.c from stmhal for cross-port reuse.Paul Sokolovsky
2015-10-19stmhal: Implement os.dupterm (was pyb.repl_uart).Damien George
pyb.repl_uart still exists but points to os.dupterm.
2015-07-27stmhal: Put fs_user_mount pointer in root ptr section of global state.Damien George
Should fix issue #1393.
2015-05-13lib: Move time utility functions to common library.Josef Gajdusek
2015-05-12stmhal: Add os.rename function.Steve Zatz
2015-04-28py: Replace py-version.sh with makeversionhdr.py, written in Python.Damien George
Also rename py-version.h to mpversion.h for consistency with mpconfig.h.
2015-04-21stmhal: Implement os.uname() to get details of OS and hardware.Damien George
2015-03-04stmhal: Make os.sync use disk_ioctl exclusively; reuse os.sync in pyb.Damien George
2015-03-04stmhal: Include fatfs headers using lib/fatfs prefix.Damien George
This helps make files reusable across other ports.
2015-01-21py: Remove mp_obj_str_builder and use vstr instead.Damien George
With this patch str/bytes construction is streamlined. Always use a vstr to build a str/bytes object. If the size is known beforehand then use vstr_init_len to allocate only required memory. Otherwise use vstr_init and the vstr will grow as needed. Then use mp_obj_new_str_from_vstr to create a str/bytes object using the vstr memory. Saves code ROM: 68 bytes on stmhal, 108 bytes on bare-arm, and 336 bytes on unix x64.
2015-01-01stmhal: Prefix includes with py/; remove need for -I../py.Damien George
2014-12-27stmhal: Add ability to mount custom block device.Damien George
2014-11-29Use MP_DEFINE_CONST_DICT macro to define module dicts.Damien George
This is just a clean-up of the code. Generated code is exactly the same.
2014-10-12stmhal: Rename module files to keep consistency with module name.Damien George