diff options
Diffstat (limited to 'docs/library')
-rw-r--r-- | docs/library/pyb.USB_VCP.rst | 4 | ||||
-rw-r--r-- | docs/library/pyb.rst | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/docs/library/pyb.USB_VCP.rst b/docs/library/pyb.USB_VCP.rst index 4d87be4a3..be1316432 100644 --- a/docs/library/pyb.USB_VCP.rst +++ b/docs/library/pyb.USB_VCP.rst @@ -26,6 +26,10 @@ Methods Set to -1 to disable this interrupt feature. This is useful when you want to send raw bytes over the USB VCP port. +.. method:: usb_vcp.isconnected() + + Return ``True`` if USB is connected as a serial device, else ``False``. + .. method:: usb_vcp.any() Return ``True`` if any characters waiting, else ``False``. diff --git a/docs/library/pyb.rst b/docs/library/pyb.rst index 79caa67d2..f93b884ab 100644 --- a/docs/library/pyb.rst +++ b/docs/library/pyb.rst @@ -149,11 +149,15 @@ Miscellaneous functions Return True if USB is connected as a serial device, False otherwise. + .. note:: This function is deprecated. Use pyb.USB_VCP().isconnected() instead. + .. function:: hid((buttons, x, y, z)) Takes a 4-tuple (or list) and sends it to the USB host (the PC) to signal a HID mouse-motion event. + .. note:: This function is deprecated. Use pyb.USB_HID().send(...) instead. + .. function:: info([dump_alloc_table]) Print out lots of information about the board. |