Matrix Voice keep getting disconnected from WIFI

hi
I recently got MV ESP32 and were able to setup the everloop program using instructions online on https://matrix-io.github.io/matrix-documentation/matrix-voice/esp32/.

When I disconnect the MV from my raspberry and run it in standalone mode using usb power it connects to the wifi and i can see it on my network. however after sometime it gets disconnected from my wifi network and I am not able to see it on network either by IP or LAN name “MVESP”. And hence when i try to do OTA for some minor changes in everloop program for testing… it is not able to upload the changes. i have tried both LAN name and initial IP that it has shown on network. In FING app as well is shows offline on my wifi network.

I’m using google wifi which supports both 2.4 and 5GHz channels and rest of my mixed devices are made for only 2.4GHz are able to work on this wifi network.

I’m using windows 10 as my host computer to do the setup and able to flash the code if MV is connected to raspberry.

below are detailed logs for details:

C:\Users\lalit\esp32-platformio>pio run --target upload
Processing esp32dev (platform: espressif32; board: esp32dev; framework: arduino)
------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32dev.html
PLATFORM: Espressif 32 1.9.0 > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES: toolchain-xtensa32 2.50200.80 (5.2.0), framework-arduinoespressif32 2.10002.190628 (1.0.2), tool-esptoolpy 1.20600.0 (2.6.0), tool-openocd-esp32 1.1000.20190708 (10.0), tool-mkspiffs 2.230.0 (2.30)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 28 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <MATRIXVoiceESP32HAL> 0.77.0 #320c897
|-- <MATRIXVoiceESP32ArduinoOTA> 0.15.0 #6ce87f9
|   |-- <ArduinoOTA> 1.0
|   |   |-- <Update> 1.0
|   |   |-- <WiFi> 1.0
|   |   |-- <ESPmDNS> 1.0
|   |   |   |-- <WiFi> 1.0
|   |-- <ESPmDNS> 1.0
|   |   |-- <WiFi> 1.0
|   |-- <WiFi> 1.0
Retrieving maximum program size .pio\build\esp32dev\firmware.elf
Checking size .pio\build\esp32dev\firmware.elf
Memory Usage -> http://bit.ly/pio-memory-usage
DATA:    [==        ]  17.2% (used 56352 bytes from 327680 bytes)
PROGRAM: [=======   ]  73.6% (used 964836 bytes from 1310720 bytes)
Configuring upload protocol...
AVAILABLE: esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa
CURRENT: upload_protocol = espota
Uploading .pio\build\esp32dev\firmware.bin
00:20:58 [DEBUG]: Options: {'esp_ip': "'192.168.1.245'", 'host_ip': '0.0.0.0', 'esp_port': 3232, 'host_port': 26700, 'auth': 'voice', 'image': '.pio\\build\\esp32dev\\firmware.bin', 'spiffs': False, 'debug': True, 'progress': True, 'timeout': 10}
00:20:58 [INFO]: Starting on 0.0.0.0:26700
00:20:58 [INFO]: Upload size: 964944
Sending invitation to '192.168.1.245' failed
00:20:58 [ERROR]: Host '192.168.1.245' Not Found
*** [upload] Error 1
============================================== [FAILED] Took 2.36 seconds ==============================================

C:\Users\lalit\esp32-platformio>ping 192.168.1.245

Pinging 192.168.1.245 with 32 bytes of data:
Request timed out.

Ping statistics for 192.168.1.245:
    Packets: Sent = 1, Received = 0, Lost = 1 (100% loss),
Control-C
^C
C:\Users\lalit\esp32-platformio>ping MVESP
Ping request could not find host MVESP. Please check the name and try again.

C:\Users\lalit\esp32-platformio>ping MVESP.local
Ping request could not find host MVESP.local. Please check the name and try again.

C:\Users\lalit\esp32-platformio>

C:\Users\lalit\esp32-platformio>pio run --target upload
Processing esp32dev (platform: espressif32; board: esp32dev; framework: arduino)
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32dev.html
PLATFORM: Espressif 32 1.9.0 > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES: toolchain-xtensa32 2.50200.80 (5.2.0), framework-arduinoespressif32 2.10002.190628 (1.0.2), tool-esptoolpy 1.20600.0 (2.6.0), tool-openocd-esp32 1.1000.20190708 (10.0), tool-mkspiffs 2.230.0 (2.30)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 28 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <MATRIXVoiceESP32HAL> 0.77.0 #320c897
|-- <MATRIXVoiceESP32ArduinoOTA> 0.15.0 #6ce87f9
|   |-- <ArduinoOTA> 1.0
|   |   |-- <Update> 1.0
|   |   |-- <WiFi> 1.0
|   |   |-- <ESPmDNS> 1.0
|   |   |   |-- <WiFi> 1.0
|   |-- <ESPmDNS> 1.0
|   |   |-- <WiFi> 1.0
|   |-- <WiFi> 1.0
Retrieving maximum program size .pio\build\esp32dev\firmware.elf
Checking size .pio\build\esp32dev\firmware.elf
Memory Usage -> http://bit.ly/pio-memory-usage
DATA:    [==        ]  17.2% (used 56352 bytes from 327680 bytes)
PROGRAM: [=======   ]  73.6% (used 964836 bytes from 1310720 bytes)
Configuring upload protocol...
AVAILABLE: esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa
CURRENT: upload_protocol = espota
Uploading .pio\build\esp32dev\firmware.bin
00:38:32 [DEBUG]: Options: {'esp_ip': "'MVESP'", 'host_ip': '0.0.0.0', 'esp_port': 3232, 'host_port': 53780, 'auth': 'voice', 'image': '.pio\\build\\esp32dev\\firmware.bin', 'spiffs': False, 'debug': True, 'progress': True, 'timeout': 10}
00:38:32 [INFO]: Starting on 0.0.0.0:53780
00:38:32 [INFO]: Upload size: 964944
Sending invitation to 'MVESP' failed
00:38:32 [ERROR]: Host 'MVESP' Not Found
*** [upload] Error 1
=========================================================================================== [FAILED] Took 2.60 seconds ===========================================================================================

C:\Users\lalit\esp32-platformio>

@Samreen could you please advise. Below reply seema to be a spam.

@dearlk,

Yes thank you, we took appropriate action for the spam message.

Regarding your PlatformIO ESP32 post, I will have to do some testing to see if I can replicate your issue. I have some questions to understand the situation better:

  • How long before the standalone MATRIX Voice ESP32 disappears from your network?
  • When the MATRIX Voice ESP32 IP disappears, is the original program you flashed on it still running or has it stopped?
  • What happens if you power cycle the MATRIX Voice ESP32 once it disappears from the WiFi network? Does it reappear?
  • Did you implement the following instructions for Windows users?

If you are using Windows, replace the upload_port parameter inside platformio.ini with the IP of your MATRIX VOICE ESP32.

For example, if your IP is 192.168.1.1 then change

upload_port = 'MVESP.local'

to

upload_port = 192.168.1.1

Looking forward to figuring this out together!

Best,
Samreen

hi @Samreen ,
thank you so much for your time to take a look at this issue.

below are details as requested.

  • How long before the standalone MATRIX Voice ESP32 disappears from your network?

Not exactly that I know but hardly few minutes

  • When the MATRIX Voice ESP32 IP disappears, is the original program you flashed on it still running or has it stopped?

Yes, for testing I flashed the everloop program that keeps running.

  • What happens if you power cycle the MATRIX Voice ESP32 once it disappears from the WiFi network? Does it reappear?

I can again see the device on network for sometime and again disappears.

  • Did you implement the following instructions for Windows users?

Yes, I tried both options
option1 - changing the upload_port to the IP of my raspberry pi when MV is docked on PI.
However please note that i have noticed that deploy/upload from VSCOde/PlatformIO tool doesn’t work at all and fails citing host not found.
I was only able to flash the programe using install.sh script in OTA folder and providing the IP of Raspebrry on commandline. The reason i understand is, that it’s trying to login to the PI and if password for user pi is not provided it fails. That’s the reason VSCode doesn’t work with PlatformIO. I believe docs need to be updated accordingly unless I’m missing anything here.
option2 - keep the upload_port still as MVESP and running the install script with raspberry pi IP.

so I’m not able to use it without RP. I tried using MV for SnipsAudioStreamer with PlatformIO and my snips audio-server keeps crashing since it’s not able to read anything from MV since it’s going off the network.

please let me know if you want me to provide any other details to troubleshoot this issue.

overall i liked the device and it’s capabilities and plan to get few more if my project of using it in standalone mode as audiostreamer for snips works without any issues.

Hi @Samreen
Do you have any updates on this?

@dearlk,

I have not been able to replicate the issue so far. I will try the ESP32 setup on Windows 10 to be closer to your conditions and let you know if I find anything.

Best,
Samreen