Navigation

    全志在线开发者论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • 在线文档
    • 社区主页

    V853 的 USB 如何设置成开机默认 Host 模式?

    V Series
    5
    6
    2782
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • N
      netube LV 2 last edited by

      如题,每次开机都要输入一次 cat /sys/devices/platform/soc/usbc0/usb_host 实在是太麻烦了

      N 1 Reply Last reply Reply Quote Share 0
      • N
        NULL037 LV 7 @netube last edited by NULL037

        @netube 在开机自启脚本中增加命令

        F 1 Reply Last reply Reply Quote Share 0
        • F
          fawen LV 5 @NULL037 last edited by

          @null037 我试过弄成开机设置,感觉切换不了。

          whycan 1 Reply Last reply Reply Quote Share 0
          • whycan
            whycan晕哥 LV 9 @fawen last edited by

            @fawen
            board.dts 可以修改

            1 Reply Last reply Reply Quote Share 0
            • F
              fawen LV 5 last edited by awwwwa

              @whycan

              &usbc0 {
              	device_type = "usbc0";
              	usb_port_type = <0x2>;
              	usb_detect_type = <0x1>;
              	usb_detect_mode = <0x0>;
              	usb_id_gpio     = <&pio PH 14 0 1 0xffffffff 0xffffffff>;
              	/*usb_det_vbus_gpio   = <&pio PH 3 0 1 0xffffffff 0xffffffff>;*/
              	usb_det_vbus_gpio = "axp_ctrl";
              	det_vbus_supply = <&gpio_charger>;
              	usb_regulator_io = "nocare";
              	usb_wakeup_suspend = <0x0>;
              	usb_luns = <0x3>;
              	usb_serial_unique = <0x0>;
              	usb_serial_number = "20080411";
              	status = "okay";
              };
              

              是改这里吗?whycan晕哥!需要改哪个参数。

              A 1 Reply Last reply Reply Quote Share 0
              • A
                awwwwa LV 8 @fawen last edited by awwwwa

                @fawen

                /*
                 *usb_port_type: usb mode. 0-device, 1-host, 2-otg.
                 *usb_detect_type: usb hotplug detect mode. 0-none, 1-vbus/id detect, 2-id/dpdm detect.
                 *usb_detect_mode: 0-thread scan, 1-id gpio interrupt.
                 *usb_id_gpio: gpio for id detect.
                 *usb_det_vbus_gpio: gpio for id detect. gpio or "axp_ctrl";
                 *usb_wakeup_suspend:0-SUPER_STANDBY, 1-USB_STANDBY.
                 */
                

                usb_port_type改成1就可以

                1 Reply Last reply Reply Quote Share 0
                • 1 / 1
                • First post
                  Last post

                Copyright © 2024 深圳全志在线有限公司 粤ICP备2021084185号 粤公网安备44030502007680号

                行为准则 | 用户协议 | 隐私权政策