MCPcopy Create free account
hub / github.com/bmorcelli/Launcher / beginUsb

Method beginUsb

src/massStorage.cpp:277–291  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

275}
276
277void MassStorage::beginUsb() {
278 drawUSBStickIcon(false);
279 Serial.flush();
280 Serial.end();
281#if CONFIG_IDF_TARGET_ESP32P4
282 usb_serial_jtag_ll_phy_enable_pad(false);
283 LP_SYS.usb_ctrl.sw_hw_usb_phy_sel = 1;
284 LP_SYS.usb_ctrl.sw_usb_phy_sel = 1; // USB_WRAP -> FSLS PHY0 (GPIO24/25 on Tab5 USB-C)
285 usb_wrap_ll_phy_set_defaults(&USB_WRAP);
286 usb_wrap_ll_phy_enable_pad(&USB_WRAP, true);
287 usb_wrap_ll_phy_set_pullup_strength(&USB_WRAP, true);
288#endif
289 s_usbMounted = false;
290 beginUsbRaw();
291}
292
293void MassStorage::displayMessage(String message) {
294 tft->drawRoundRect(5, 5, tftWidth - 10, tftHeight - 10, 5, ALCOLOR);

Callers

nothing calls this directly

Calls 3

drawUSBStickIconFunction · 0.85
beginUsbRawFunction · 0.85
endMethod · 0.45

Tested by

no test coverage detected