diff options
author | Peter Hinch <peter@hinch.me.uk> | 2018-09-16 11:56:57 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2018-09-20 16:31:36 +1000 |
commit | 927a5d1dfddf958607e008f6181b45469ceafa6e (patch) | |
tree | e2af522adfe8e571e93cb4140c52a14d73d66030 | |
parent | 1628cd0e5920c52564e443d067d404b88704bd29 (diff) |
docs/library/pyb: Add deprecation warning for mount and old block proto.
pyb.mount(None, mountpoint) functionality is also removed and replaced by
uos.umount.
-rw-r--r-- | docs/library/pyb.rst | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/docs/library/pyb.rst b/docs/library/pyb.rst index 2ceed2396..1e1e9ffaa 100644 --- a/docs/library/pyb.rst +++ b/docs/library/pyb.rst @@ -212,8 +212,13 @@ Miscellaneous functions .. function:: mount(device, mountpoint, \*, readonly=False, mkfs=False) + .. note:: This function is deprecated. Mounting and unmounting devices should + be performed by :meth:`uos.mount` and :meth:`uos.umount` instead. + Mount a block device and make it available as part of the filesystem. - ``device`` must be an object that provides the block protocol: + ``device`` must be an object that provides the block protocol. (The + following is also deprecated. See :class:`uos.AbstractBlockDev` for the + correct way to create a block device.) - ``readblocks(self, blocknum, buf)`` - ``writeblocks(self, blocknum, buf)`` (optional) @@ -238,9 +243,6 @@ Miscellaneous functions If ``mkfs`` is ``True``, then a new filesystem is created if one does not already exist. - To unmount a device, pass ``None`` as the device and the mount location - as ``mountpoint``. - .. function:: repl_uart(uart) Get or set the UART object where the REPL is repeated on. |