Welcome, Guest. Please Login or Register
Arduino IDE for Visual Studio
 
 
When Logging a Support Issue in the Forum, please ensure you have also:-
  • Enabled vMicro > Compiler > Show Build Properties and Verbose
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
  HomeSearch Tutorials & Wiki visualmicro.com LoginHelpRegister  
 
Page Index Toggle Pages: 1
Send Topic Print
esp8266/esp12x wifi debugging (Read 358 times)
GeirG
Newbies
*
Offline



Posts: 3
esp8266/esp12x wifi debugging
Jul 1st, 2020 at 7:01pm
 
I have been trying to get debugging over wifi to
work on my esp12x(esp8266) chip.
But i am not able to get this working.
Is it possible to do this on this chip?
and how do i solve this?

Hope someone can help me on this one.
Just started with Visual Micro.

Back to top
« Last Edit: Jul 1st, 2020 at 7:02pm by GeirG »  
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 537
Re: esp8266/esp12x wifi debugging
Reply #1 - Jul 2nd, 2020 at 7:22pm
 
Thanks for the report.  We have identified the issue with the ESP8266 and UDP debugging, which we will resolve in an upcoming release, and update this thread when it is available.

When the update is available, the setup instructions are the same as for the ESP32, which can be seen in this video, and we will publish further separate instructions in the coming days for ESP8266 specifically so it is clear.
Back to top
 
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 537
Re: esp8266/esp12x wifi debugging
Reply #2 - Jul 2nd, 2020 at 8:53pm
 
The latest release 20.06.30.1 contains the update to resolve the issue, which is the latest release at the top of the below board:
https://www.visualmicro.com/forums/YaBB.pl?board=VS_ARDUINO_EXT_RELEASES

If you have trouble installing this release please see this Video Guide for this process.

Back to top
 
 
IP Logged
 
GeirG
Newbies
*
Offline



Posts: 3
Re: esp8266/esp12x wifi debugging
Reply #3 - Jul 2nd, 2020 at 9:39pm
 
"sweet dreams are made of this"
Back to top
 
 
IP Logged
 
CSC
Junior Member
**
Offline



Posts: 16
Panama
Re: esp8266/esp12x wifi debugging
Reply #4 - Nov 11th, 2020 at 12:16pm
 
Essentially the same problem. I am unable to OTA upload or debug on an ESP-12E.

I have updated to the latest vMicro release (2020.910.14).

I am testing using the example code from the link below:

https://www.visualmicro.com/page/esp8266.aspx

I have bonjour installed on Windows 10 and the IP of the chip shows up in Visual Studio.

I also have a local boards.txt file. Initially I was having authentication issues so added authentication to boards.txt and set OTA password in the example code. Contents of boards.txt:

# local project board.txt overrides
network.password=123
network.auth_upload=yes
  network.port=8266


That got me past the auth issue, but now I get the following output:

Compiling debug version of 'OTAdebugTest' for 'NodeMCU 1.0 (ESP-12E Module)'
Creating BIN file "C:\Users\admin\AppData\Local\Temp\VMBuilds\OTAdebugTest\esp8266_nodemcuv2\Debug
/OTAdebugTest.ino.bin" using "C:\Users\admin\AppData\Local\arduino15\packages\esp8266\hardware\esp8266\2.7.4/
bootloaders/eboot/eboot.elf" and "C:\Users\admin\AppData\Local\Temp\VMBuilds\OTAdebugTest\esp8266_nodemcuv2\Debug
/OTAdebugTest.ino.elf"
   Executable segment sizes
IROM   *: 286588          - code in flash         (default or ICACHE_FLASH_ATTR)
IRAM   *: 28664   \ 32768 - code in IRAM          (ICACHE_RAM_ATTR, ISRs...)
DATA   *: 1276  )         - initialized variables (global, static) in RAM\HEAP
RODATA *: 1516  ) \ 81920 - constants             (global, static) in RAM\HEAP
BSS    *: 25880 )         - zeroed variables      (global, static) in RAM\HEAP
Program size: 318,044 bytes (used 30% of a 1,044,464 byte maximum) (16.23 secs)
Minimum Memory Usage: 28672 bytes (35% of a 81920 byte maximum)

Uploading 'OTAdebugTest' to 'NodeMCU 1.0 (ESP-12E Module)' using '192.168.1.108'
Authenticating...OK
The uploader process failed
07:04:48 [ERROR]: No response from device


I can successfully upload and debug over serial interface. I uploaded the example app initially over serial before attempting other OTA operations.

Shot of my project properties page attached.

Back to top
« Last Edit: Nov 11th, 2020 at 12:17pm by CSC »  

Please Register or Login to the Forum to see File Attachments
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 537
Re: esp8266/esp12x wifi debugging
Reply #5 - Nov 11th, 2020 at 1:07pm
 
Thanks for the report, and the detailed information.

There may be additional information on the failure in the Serial Monitor:
1) Re-upload the sketch via Serial, and ensure no breakpoints are set.
2) Then open the Serial Port in Visual Micro from the General > Monitor Alternative, at 115200 baud.
3) Then re-try the OTA Upload, and abserve the Serial Monitor

Back to top
 
 
IP Logged
 
CSC
Junior Member
**
Offline



Posts: 16
Panama
Re: esp8266/esp12x wifi debugging
Reply #6 - Nov 11th, 2020 at 2:24pm
 
Thanks for the quick response. Will do.

Back to top
 
 
IP Logged
 
CSC
Junior Member
**
Offline



Posts: 16
Panama
Re: esp8266/esp12x wifi debugging
Reply #7 - Nov 11th, 2020 at 2:48pm
 
I set Monitor Alternative to "COM3" (the com for the board), then set the BPS rate to 115200 using the serial window menu item (I did not see any way to set that under General). IP Address in tool bar set to IP for the board. Below are the results:

Build and attempted upload over OTA:

Compiling debug version of 'OTAdebugTest' for 'NodeMCU 1.0 (ESP-12E Module)'
Creating BIN file "C:\Users\admin\AppData\Local\Temp\VMBuilds\OTAdebugTest\esp8266_nodemcuv2\Debug
/OTAdebugTest.ino.bin" using "C:\Users\admin\AppData\Local\arduino15\packages\esp8266\hardware\esp8266\2.7.4/
bootloaders/eboot/eboot.elf" and "C:\Users\admin\AppData\Local\Temp\VMBuilds\OTAdebugTest\esp8266_nodemcuv2\Debug
/OTAdebugTest.ino.elf"
   Executable segment sizes
IROM   *: 286108          - code in flash         (default or ICACHE_FLASH_ATTR)
IRAM   *: 28664   \ 32768 - code in IRAM          (ICACHE_RAM_ATTR, ISRs...)
DATA   *: 1276  )         - initialized variables (global, static) in RAM\HEAP
RODATA *: 1516  ) \ 81920 - constants             (global, static) in RAM\HEAP
Program size: 317,564 bytes (used 30% of a 1,044,464 byte maximum) (15.86 secs)
Minimum Memory Usage: 28672 bytes (35% of a 81920 byte maximum)
BSS    *: 25880 )         - zeroed variables      (global, static) in RAM\HEAP

Uploading 'OTAdebugTest' to 'NodeMCU 1.0 (ESP-12E Module)' using '192.168.1.108'
Authenticating...OK
The uploader process failed
09:30:32 [ERROR]: No response from device


COM3 output:

Opening port
Port open
sleep disable
OTA Start
Progress: 0%
Error[2]: Connect Failed
Error[4]: End Failed

Back to top
 
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 537
Re: esp8266/esp12x wifi debugging
Reply #8 - Nov 11th, 2020 at 3:12pm
 
Thanks for the detail.

Do you have a firewall enabled on your machine, and if so have you added the port as an exception to the list?

If its the standard Windows Defender Firewall, you can add an exception for Python3 on your Private Networks to resolve this.
(The path to the Python3.exe can be grabbed from the output, if you enable vMicro > Uploader > Verbose and try the upload again)

Back to top
 
 
IP Logged
 
CSC
Junior Member
**
Offline



Posts: 16
Panama
Re: esp8266/esp12x wifi debugging
Reply #9 - Nov 11th, 2020 at 6:27pm
 
I dont think a firewall is enabled on this machine, but will check...and retry upload.
Back to top
« Last Edit: Nov 11th, 2020 at 6:28pm by CSC »  
 
IP Logged
 
GeirG
Newbies
*
Offline



Posts: 3
Re: esp8266/esp12x wifi debugging
Reply #10 - Nov 11th, 2020 at 6:55pm
 
Hi.
Make sure you have "Erase Flash: All flash contents",
so you don't have any "left overs".
Did not change anything else in project properties.
I tested on a ESP12(ESP8266).
pc og ESP12 on same network.
this sketch worked for me:

#include <ESP8266WiFi.h>
#include <ESP8266mDNS.h>
#include <WiFiUdp.h>
#include <ArduinoOTA.h>
const char* ssid = "SSID";
const char* password = "PASSWORD";
void setup()
{
    Serial.begin(115200);
    Serial.println();
    Serial.println("Booting");   
    WiFi.begin(ssid, password);
    while (WiFi.waitForConnectResult() != WL_CONNECTED)
    {
        Serial.println("Connection Failed! Rebooting...");
        delay(5000);
        ESP.restart();
    }       
    ArduinoOTA.begin();
    Serial.println("Ready");
    Serial.print("IP address: ");
    Serial.println(WiFi.localIP());
}
void loop()
{
    ArduinoOTA.handle();
}
Back to top
« Last Edit: Nov 11th, 2020 at 7:14pm by GeirG »  
 
IP Logged
 
CSC
Junior Member
**
Offline



Posts: 16
Panama
Re: esp8266/esp12x wifi debugging
Reply #11 - Nov 11th, 2020 at 8:37pm
 
Turns out Windows Defender was enabled on this new-to-me machine.

I added port 8266 and python3.exe program exceptions and now OTA Upload works!

I also enabled blocking notifications on Windows Defender so next time I should know what its up to.

Next up...test OTA debugging...

Thanks much for the help! Smiley

Back to top
« Last Edit: Nov 11th, 2020 at 8:39pm by CSC »  
 
IP Logged
 
Page Index Toggle Pages: 1
Send Topic Print