feat(usb/host): Add option to choose peripheral for USB host library

Starting with ESP32-P4 we can have targets that have more than 1 USB-OTG peripheral.
This commit adds an option to choose which peripherals will be used by USB Host lib.

Internally, we will still have only 1 Root HUB but with multiple Root ports.
This commit is contained in:
Tomas Rezucha
2024-12-03 08:52:48 +01:00
parent 66e5cc8801
commit b961f42e8b
14 changed files with 169 additions and 75 deletions

View File

@@ -4,10 +4,15 @@
* SPDX-License-Identifier: Apache-2.0
*/
#pragma once
#include "hal/usb_phy_types.h"
/**
* @brief Install USB PHY separately from the usb_host_install()
*
* @param[in] phy_target USB PHY target
*/
void test_setup_usb_phy(void);
void test_setup_usb_phy(usb_phy_target_t phy_target);
/**
* @brief Uninstall PHY