refactor(ext_port): Changed the mechanism for hub class request

Merged all Hub Class specific request to one function.
Added a callback for the External Port Driver to break the dependency from ext_hub.h
This commit is contained in:
Roman Leonov
2025-02-19 14:05:24 +01:00
parent 9c98a17a0d
commit c391c835c2
6 changed files with 96 additions and 128 deletions

View File

@@ -536,6 +536,7 @@ esp_err_t hub_install(hub_config_t *hub_config, void **client_ret)
ext_port_driver_config_t ext_port_config = {
.proc_req_cb = ext_port_callback,
.event_cb = ext_port_event_callback,
.hub_request_cb = ext_hub_class_request,
};
ret = ext_port_install(&ext_port_config);
if (ret != ESP_OK) {