summaryrefslogtreecommitdiff
path: root/doc/usage
diff options
context:
space:
mode:
authorTom Rini <[email protected]>2024-10-16 21:45:21 -0600
committerTom Rini <[email protected]>2024-10-16 21:45:21 -0600
commit9e1cd2f2cb86865bbc002ed961a095c7a8bcc989 (patch)
tree276fd4061b5e58a4bfc692c2ac6412efc4c891fa /doc/usage
parent98a36deb9ab7aaea70b0b0db47718100e08cf3e8 (diff)
parent6852a2c82e695c418c744b0fcb4298bc0e759842 (diff)
Merge https://source.denx.de/u-boot/custodians/u-boot-usb
Diffstat (limited to 'doc/usage')
-rw-r--r--doc/usage/cmd/tcpm.rst66
-rw-r--r--doc/usage/index.rst1
2 files changed, 67 insertions, 0 deletions
diff --git a/doc/usage/cmd/tcpm.rst b/doc/usage/cmd/tcpm.rst
new file mode 100644
index 00000000000..eb2c69d0bdb
--- /dev/null
+++ b/doc/usage/cmd/tcpm.rst
@@ -0,0 +1,66 @@
+.. SPDX-License-Identifier: GPL-2.0+:
+
+.. index::
+ single: tcpm (command)
+
+tcpm command
+============
+
+Synopsis
+--------
+
+::
+
+ tcpm dev [devnum]
+ tcpm info
+ tcpm list
+
+Description
+-----------
+
+The tcpm command is used to control USB-PD controllers, also known as TypeC Port Manager (TCPM).
+
+The 'tcpm dev' command shows or set current TCPM device.
+
+ devnum
+ device number to change
+
+The 'tcpm info' command displays the current state of the device
+
+The 'tcpm list' command displays the list available devices.
+
+Examples
+--------
+
+The 'tcpm info' command displays device's status:
+::
+
+ => tcpm info
+ Orientation: normal
+ PD Revision: rev3
+ Power Role: sink
+ Data Role: device
+ Voltage: 20.000 V
+ Current: 2.250 A
+
+The current device can be shown or set via 'tcpm dev' command:
+::
+
+ => tcpm dev
+ TCPM device is not set!
+ => tcpm dev 0
+ dev: 0 @ usb-typec@22
+ => tcpm dev
+ dev: 0 @ usb-typec@22
+
+The list of available devices can be shown via 'tcpm list' command:
+::
+
+ => tcpm list
+ | ID | Name | Parent name | Parent uclass @ seq
+ | 0 | usb-typec@22 | i2c@feac0000 | i2c @ 4 | status: 0
+
+Configuration
+-------------
+
+The tcpm command is only available if CONFIG_CMD_TCPM=y.
diff --git a/doc/usage/index.rst b/doc/usage/index.rst
index 70563374899..fcce125a611 100644
--- a/doc/usage/index.rst
+++ b/doc/usage/index.rst
@@ -112,6 +112,7 @@ Shell commands
cmd/smbios
cmd/sound
cmd/source
+ cmd/tcpm
cmd/temperature
cmd/tftpput
cmd/trace