| b.liu | e958203 | 2025-04-17 19:18:16 +0800 | [diff] [blame] | 1 | USB GPIO Based Connection Detection |
| 2 | |
| 3 | This is typically used to switch dual role mode from the USB ID pin connected |
| 4 | to an input GPIO, and also used to enable/disable device mode from the USB |
| 5 | Vbus pin connected to an input GPIO. |
| 6 | |
| 7 | Required properties: |
| 8 | - compatible : should include "gpio-usb-b-connector" and "usb-b-connector". |
| 9 | - id-gpios, vbus-gpios : input gpios, either one of them must be present, |
| 10 | and both can be present as well. |
| 11 | see connector/usb-connector.txt |
| 12 | |
| 13 | Optional properties: |
| 14 | - vbus-supply : can be present if needed when supports dual role mode. |
| 15 | see connector/usb-connector.txt |
| 16 | |
| 17 | - Sub-nodes: |
| 18 | - port : can be present. |
| 19 | see graph.txt |
| 20 | |
| 21 | Example: |
| 22 | |
| 23 | &mtu3 { |
| 24 | connector { |
| 25 | compatible = "gpio-usb-b-connector", "usb-b-connector"; |
| 26 | type = "micro"; |
| 27 | id-gpios = <&pio 12 GPIO_ACTIVE_HIGH>; |
| 28 | vbus-supply = <&usb_p0_vbus>; |
| 29 | }; |
| 30 | }; |