Seeed-Solution / SenseCAP_Indicator_ESP32

SenseCAP Indicator SDK.
https://wiki.seeedstudio.com/SenseCAP_Indicator_How_To_Flash_The_Default_Firmware/#ESP-IDF
Apache License 2.0
32 stars 22 forks source link

Re-programming SenseCAP: not showing up as /dev/cu.usbserial-xxxx anymore #23

Closed ooktown closed 9 months ago

ooktown commented 10 months ago

Greetings!

I've previously programmed my SenseCAP Indicator D1 with the ESP-IDF and the example Home Assistant program. It is working fine and is connected to my home network and HA via MQTT.

However, I now want to re-program the unit, but when I plug the unit into my computer using the USB-C connector (I've tried both connectors), the SenseCAP no longer appears as a USB serial device (FYI: When I first programmed the SenseCAP, it appeared as /dev/cu.usbserial-4013110).

Any ideas what I'm doing wrong? How can I reset the device so that I can reprogram it with new firmware?

ooktown commented 10 months ago

If this helps, I'm on a Mac and ran a dmesg command. It looks like there’s a USB failure to create a device, but I’m not sure what I’m looking at…

Here's the output:

[15250.454597]: AppleUSB20HubPort@40134141: AppleUSBHostPort::disconnect: persistent enumeration failures
[15250.570742]: com.apple.p2p: isInfraRealtimePacketThresholdAllowed allowed:1 option:32 threshold:50 noRegistrations:1 cachedPeerCount:0 fastDiscoveryInactive:1 fastDiscoveryOnSince:15250570
[15250.570768]: com.apple.p2p: currentInfraTrafficType:8087 checking if realtime upgrade required with inputPackets:2 outputPackets:0 packetThreshold:50
[15250.792864]: AppleUSB20HubPort@40134141: AppleUSBHostPort::disconnect: persistent enumeration failures
[15251.074077]: AppleUSBEHCIPI7C9X440SL@40000000: AppleUSBHostController::abortPipe: pipe <ptr> withError 0xe00002eb forClient <ptr> completed with 0xe00002f0
[15251.074102]: AppleUSB20HubPort@40134141: AppleUSBHostPort::createDevice: failed to create device (0xe00002bc)
[15251.074106]: AppleUSB20HubPort@40134141: AppleUSB20HubPort::resetAndCreateDevice: failed to create device, disabling port
[15251.074337]: AppleUSB20HubPort@40134141: AppleUSBHostPort::disconnect: persistent enumeration failures
[15251.412941]: AppleUSB20HubPort@40134141: AppleUSBHostPort::disconnect: persistent enumeration failures
[15251.595396]: com.apple.p2p: isInfraRealtimePacketThresholdAllowed allowed:1 option:32 threshold:50 noRegistrations:1 cachedPeerCount:0 fastDiscoveryInactive:1 fastDiscoveryOnSince:15251595
[15251.595420]: com.apple.p2p: currentInfraTrafficType:8087 checking if realtime upgrade required with inputPackets:1 outputPackets:0 packetThreshold:50
[15251.747595]: AppleUSB20HubPort@40134141: AppleUSBHostPort::disconnect: persistent enumeration failures

Let me know if you have ideas on what to do to reprogram the SenseCAP Indicator. Thanks!

Wvirgil123 commented 9 months ago

This is a very strange phenomenon. It seems that the USB enumeration failed.

ooktown commented 9 months ago

Thanks for your response!

Is there anything I can try to help debug the cause of the failure?

Love4yzp commented 9 months ago

@ooktown Thank you for providing the additional debugging information on the USB enumeration failure with your SenseCAP. I have looked into the details you provided but unfortunately we are still unable to determine the specific cause of the behavior.

If you are no longer experiencing this problem when trying to reprogram the SenseCAP, or you do not require further troubleshooting, I will go ahead and close out this issue for now. Please feel free to reopen if you run into this again in the future, and can provide new logs or debugging steps that may help track down the problem.