jantje / hardware

Arduino eclipse plugin hardware support folders
6 stars 24 forks source link

V4 ESP8266 Hardware Debug Works for 'Huzzah Breakout' board, but not for 'Huzzah Feather' board #6

Closed mrwgx3 closed 6 years ago

mrwgx3 commented 7 years ago

Per Janjte's request, the following issue was closed in 'Sloeber/arduino-eclipse-plugin' and recreated here (san's Janjte's comments):

V4 ESP8266 Hardware Debug Works for 'Huzzah Breakout' board, but not for 'Huzzah Feather' board, #752

See https://github.com/Sloeber/arduino-eclipse-plugin/issues/752

1st Comment

Basic Infos

Hardware

Hardware:     ESP12, Adafruit Huzzah Breakout and Feather Boards  
Core Version: 2.3.0
Computer:     Dell, Intel Core i7 CPU, 870 @ 2.93Ghz,  16.0 GB RAM

OS, IDE

OS:   Windows 10 Professional   
IDE:  Sloeber   4.0.1.201705071425

Description

Per your Youtube video on how to setup Sloeber for hardware debugging of the ESP8266, I successfully got debugging to work for the Adafruit Huzzah Breakout Board. The Huzzah Feather Board, however, seems to have timing issues with both the uploading of the debug sketch and initiating a debugger dialog.

Discussion

To facilitate testing, (2) 'blink' example projects were created:

   Debug Config.               Release Config.                 Serial     Project Title
A) Debug Board with 1.65 SDK   Huzzah Feather  with 1.65 SDK   COM4       blink_wtdelay_gdbA_r1p65
B) Debug Board with 1.65 SDK   Huzzah Breakout with 1.65 SDK   COM6       blink_wtdelay_gdbB_r1p65

Initially, only project A existed; project B was created after project A's debug sketch wouldn't upload. Project B's debug sketch did upload, and invoking the Debug perspective resulted in a successful debug session. Project A's debug sketch was then uploaded using the admin. command prompt to run a different 'esptool', but switching to the Debug perspective only resulted in a partial load and the following timeout message:

Error in final launch sequence
Failed to execute MI command:
-target-select remote /./COM4
Error message from debugger back end:
Bogus trace status reply from target: timeout
Bogus trace status reply from target: timeout

Hence it was concluded that the Huzzah Feather Board likely has some software/hardware timing issues.

Messages of Interest

Project B Compiler/Upload Messages, Successful Debug Session

'Create eeprom image'
"C:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/esptool/0.4.5/esptool.exe" -eo "C:\SloeberBeR1\/arduinoPlugin/packages/esp8266/hardware/esp8266/1.6.5-947-g39819f0/bootloaders/eboot/eboot.elf" -bo "C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbB_r1p65/debug/blink_wtdelay_gdbB_r1p65.bin" -bm qio -bf 40 -bz 4M -bs .text -bp 4096 -ec -eo "C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbB_r1p65/debug/blink_wtdelay_gdbB_r1p65.elf" -bs .irom0.text -bs .text -bs .data -bs .rodata -bc -ec
'Finished building: blink_wtdelay_gdbB_r1p65.hex'
' '
'Building target: blink_wtdelay_gdbB_r1p65'
'Printing size:'
"C:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/xtensa-lx106-elf-size" -A "C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbB_r1p65/debug/blink_wtdelay_gdbB_r1p65.elf"
C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbB_r1p65/debug/blink_wtdelay_gdbB_r1p65.elf  :
section                           size         addr
.data                             1496   1073643520
.rodata                           1716   1073645024
.bss                             42192   1073646744
.irom0.text                     178504   1075843088
.text                            30240   1074790400
.debug_frame                      4520            0
.debug_info                      43855            0
.debug_abbrev                     9320            0
.debug_aranges                    1600            0
.debug_ranges                      784            0
.debug_line                      30937            0
.debug_str                       12145            0
.comment                          6680            0
.xtensa.info                        56            0
.xt.lit                           4824            0
.xt.prop                        160620            0
.xt.prop._ZTV6Stream                12            0
.xt.prop._ZTV14HardwareSerial       12            0
.xt.prop._ZTV5Print                 12            0
.debug_loc                       18402            0
Total                           547927

'Finished building target: blink_wtdelay_gdbB_r1p65'

Starting upload
using arduino loader
Starting reset using DTR toggle process
Toggling DTR
Continuing to useCOM6
Ending reset

LaunchingC:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/esptool/0.4.9/esptool.exe -cd ck -cb 115200 -cp COM6 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbB_r1p65/debug/blink_wtdelay_gdbB_r1p65.bin 
Output:
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbB_r1p65/debug/blink_wtdelay_gdbB_r1p65.bin to flash at 0x00000000
................................................................................ [ 37% ]
................................................................................ [ 75% ]
....................................................                             [ 100% ]
/arduinoPlugin/packages/esp8266/tools/esptool/0.4.9/esptool.exe finished
upload done

Project A Compiler/Upload Messages, Failed Upload

'Create eeprom image'
"C:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/esptool/0.4.5/esptool.exe" -eo "C:\SloeberBeR1\/arduinoPlugin/packages/esp8266/hardware/esp8266/1.6.5-947-g39819f0/bootloaders/eboot/eboot.elf" -bo "C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.bin" -bm qio -bf 40 -bz 4M -bs .text -bp 4096 -ec -eo "C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.elf" -bs .irom0.text -bs .text -bs .data -bs .rodata -bc -ec
'Finished building: blink_wtdelay_gdbA_r1p65.hex'
' '
'Building target: blink_wtdelay_gdbA_r1p65'
'Printing size:'
"C:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/xtensa-lx106-elf-size" -A "C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.elf"
C:/Users/DELL/SloeberWork/Wksr1/blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.elf  :
section                           size         addr
.data                             1496   1073643520
.rodata                           1716   1073645024
.bss                             42192   1073646744
.irom0.text                     178504   1075843088
.text                            30240   1074790400
.debug_frame                      4520            0
.debug_info                      43855            0
.debug_abbrev                     9320            0
.debug_aranges                    1600            0
.debug_ranges                      784            0
.debug_line                      30937            0
.debug_str                       12145            0
.comment                          6680            0
.xtensa.info                        56            0
.xt.lit                           4824            0
.xt.prop                        160620            0
.xt.prop._ZTV6Stream                12            0
.xt.prop._ZTV14HardwareSerial       12            0
.xt.prop._ZTV5Print                 12            0
.debug_loc                       18402            0
Total                           547927

'Finished building target: blink_wtdelay_gdbA_r1p65'

Starting upload
using arduino loader
Starting reset using DTR toggle process
Toggling DTR
Continuing to useCOM4
Ending reset

LaunchingC:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/esptool/0.4.9/esptool.exe -cd ck -cb 921600 -cp COM4 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.bin 
Output:
warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed

/arduinoPlugin/packages/esp8266/tools/esptool/0.4.9/esptool.exe finished
upload done

Command Line Used to Succesfully Upload Project A's Debug Sketch (use version 0.4.5 rather than 0.4.9)

C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.5\esptool.exe -cd ck -cb 921600 -cp COM4 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.bin

Requested Install Information

  C/C++ Autotools support   9.2.1.201703062208  org.eclipse.cdt.autotools.feature.group Eclipse CDT
  C/C++ Common GDB Support  9.2.1.201703062208  org.eclipse.cdt.gdb.feature.group   Eclipse CDT
  C/C++ Development Platform    9.2.1.201703062208  org.eclipse.cdt.platform.feature.group  Eclipse CDT
  C/C++ Development Tools   9.2.1.201703062208  org.eclipse.cdt.feature.group   Eclipse CDT
  C/C++ DSF GDB Debugger Integration    9.2.1.201703062208  org.eclipse.cdt.gnu.dsf.feature.group   Eclipse CDT
  C/C++ GNU Toolchain Build Support 9.2.1.201703062208  org.eclipse.cdt.gnu.build.feature.group Eclipse CDT
  C/C++ GNU Toolchain Debug Support 9.2.1.201703062208  org.eclipse.cdt.gnu.debug.feature.group Eclipse CDT
  ECF Core Feature  1.3.0.v20160823-2221    org.eclipse.ecf.core.feature.feature.group  Eclipse.org - ECF
  ECF Core SSL Feature  1.1.0.v20160823-2221    org.eclipse.ecf.core.ssl.feature.feature.group  Eclipse.org - ECF
  ECF Filetransfer Feature  3.13.2.v20160823-2221   org.eclipse.ecf.filetransfer.feature.feature.group  Eclipse.org
  ECF Filetransfer SSL Feature  1.1.0.v20160823-2221    org.eclipse.ecf.filetransfer.ssl.feature.feature.group  Eclipse.org - ECF
  ECF Httpclient4 Filetransfer Provider 3.13.2.v20160823-2221   org.eclipse.ecf.filetransfer.httpclient4.feature.feature.group  Eclipse.org - ECF
  ECF Httpclient4 Filetransfer SSL Provider 1.1.0.v20160823-2221    org.eclipse.ecf.filetransfer.httpclient4.ssl.feature.feature.group  Eclipse.org - ECF
  Eclipse 4 Rich Client Platform    1.5.3.v20170228-0512    org.eclipse.e4.rcp.feature.group    Eclipse.org
  Eclipse Help System   2.2.2.v20170301-0400    org.eclipse.help.feature.group  Eclipse.org
  Eclipse Platform  4.6.3.v20170301-0400    org.eclipse.platform.feature.group  Eclipse.org
  Eclipse RCP   4.6.3.v20170301-0400    org.eclipse.rcp.feature.group   Eclipse.org
  EMF - Eclipse Modeling Framework Core Runtime 2.12.0.v20160420-0247   org.eclipse.emf.ecore.feature.group Eclipse Modeling Project
  EMF Common    2.12.0.v20160420-0247   org.eclipse.emf.common.feature.group    Eclipse Modeling Project
  Equinox p2, backward compatibility support    1.2.203.v20170131-1444  org.eclipse.equinox.p2.extras.feature.feature.group Eclipse.org - Equinox
  Equinox p2, Discovery UI support  1.0.401.v20160901-1335  org.eclipse.equinox.p2.discovery.feature.feature.group  Eclipse.org - Equinox
  Equinox p2, headless functionalities  1.3.203.v20170131-1444  org.eclipse.equinox.p2.core.feature.feature.group   Eclipse.org - Equinox
  Equinox p2, minimal support for RCP applications  1.2.203.v20170131-1444  org.eclipse.equinox.p2.rcp.feature.feature.group    Eclipse.org - Equinox
  Equinox p2, Provisioning for IDEs.    2.2.203.v20170131-1444  org.eclipse.equinox.p2.user.ui.feature.group    Eclipse.org - Equinox
  Git integration for Eclipse   4.6.1.201703071140-r    org.eclipse.egit.feature.group  Eclipse EGit
  Java implementation of Git    4.6.1.201703071140-r    org.eclipse.jgit.feature.group  Eclipse JGit
  Marketplace Client    1.5.4.v20170222-1941    org.eclipse.epp.mpc.feature.group   Eclipse Marketplace Client
  Mylyn Commons 3.21.0.v20160707-1856   org.eclipse.mylyn.commons.feature.group Eclipse Mylyn
  Mylyn Commons Connector: Discovery    3.21.0.v20160729-1739   org.eclipse.mylyn.discovery.feature.group   Eclipse Mylyn
  Mylyn Commons Connector: Monitor  3.21.0.v20160630-1702   org.eclipse.mylyn.monitor.feature.group Eclipse Mylyn
  Mylyn Commons Identity    1.13.0.v20160630-1702   org.eclipse.mylyn.commons.identity.feature.group    Eclipse Mylyn
  Mylyn Commons Notifications   1.13.0.v20160721-2347   org.eclipse.mylyn.commons.notifications.feature.group   Eclipse Mylyn
  Mylyn Commons Repositories    1.13.0.v20160630-1702   org.eclipse.mylyn.commons.repositories.feature.group    Eclipse Mylyn
  Mylyn Context Connector: Eclipse IDE  3.21.0.v20160912-1820   org.eclipse.mylyn.ide_feature.feature.group Eclipse Mylyn
  Mylyn Context Connector: Team Support 3.21.0.v20160701-1337   org.eclipse.mylyn.team_feature.feature.group    Eclipse Mylyn
  Mylyn Task List   3.21.0.v20160914-0252   org.eclipse.mylyn_feature.feature.group Eclipse Mylyn
  Mylyn Task-Focused Interface  3.21.0.v20160815-2336   org.eclipse.mylyn.context_feature.feature.group Eclipse Mylyn
  Mylyn Tasks Connector: Bugzilla   3.21.0.v20160909-1813   org.eclipse.mylyn.bugzilla_feature.feature.group    Eclipse Mylyn
  Mylyn WikiText    2.10.1.v20161129-1925   org.eclipse.mylyn.wikitext_feature.feature.group    Eclipse Mylyn
  Nebula Oscilloscope Widget    1.2.0.201704251513  org.eclipse.nebula.widgets.oscilloscope.feature.feature.group   Eclipse Nebula
  Remote System Explorer End-User Runtime   3.7.2.201610260947  org.eclipse.rse.feature.group   Eclipse TM Project
  Sloeber   4.0.1.201705071425  io.sloeber.feature.feature.group    Jan Baeyens and Others
  Sloeber, the Eclipse Arduino IDE  4.0.0.201705071425  io.sloeber.product  null

2nd Comment

jantje commented 9 hours ago

This is actually a issue for https://github.com/jantje/hardware repository and not for sloeber.
Do I understand correctly that the esp tool used is a wrong version?

Yes, that is correct; I've verified this for (2) separate installations. You did comment in the video that both the 1.65 and 2.30 SDK's were needed for debugging; I thought perhaps this was the reason.

To explore what 'esptool' version would upload Project A's debug sketch, I did some experimentation using the command prompt for:

a) My original Feather board, with peripherals attached (I2C bus, SD card, and interrupt lines; pretty full plate)
b) Another Feather board, no peripherals attached
c) My Breakout board, also sans peripherals

Test case B was added as a cross-check, as my original circuit needs all the lines controlling the ESP-12 boot mode for I/O. During reset, external logic fixes these line states to insure proper booting, then connects them to where they're needed.

Included below are excerpts from my notes recording the command prompt results for various esptool uploads:

================================

Test upload which failed using admin. command prompt:

Huzzah Feather Board, on protoboard with peripherals
C:\Users\DELL>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd ck -cb 921600 -cp COM4 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed

Huzzah Feather Board, stand-alone
C:\Users\DELL>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd ck -cb 921600 -cp COM8 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed

NOTE: The 'esptool' makes (3) attempts at connection before generating failure messages; the RED led followed BLUE led flash for each attempt.

Huzzah Breakout Board, stand-alone, expect this to work
C:\WINDOWS\system32>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd ck -cb 115200 -cp COM6 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Access is denied.

Big Surprise!
When I used the above command, got a pop-up window stating:
  "This app can't run on your PC
   To find a version for your PC, check with the software publisher."

Futhermore, the following 'esptool' will not run now either on command line or through the Sloeber IDE
C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe

Now try 'esptool' from another install...

Huzzah Breakout Board, stand-alone
NOTE THAT THIS WORKS, IDENTICAL WITH PRIOR COMMANDS EXCEPT FOR COMPORT AND BAUDRATE SELECTION

C:\WINDOWS\system32>C:\SloeberBeR2\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd ck -cb 115200 -cp COM6 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
................................................................................ [ 37% ]
................................................................................ [ 75% ]
....................................................

Success! what just got changed!?
Go inspect file, found, but reported to be '0 bytes' in size.
Move to 'DamagedEsptool' folder
Copy 'esptool.exe' from 'SloeberBeR2' install to repair, test again...
THINGS SEEM BACK TO NORMAL
Suspect I damaged the file myself with a bad paste to the command line.

================================

Given the upload failures for both Feather boards, I conclude my peripheral hardware is not affecting the outcome. A successful upload to the Breakout board indicates the Feather board may be a key variable.

================================

1st test of alternate upload(s):
  Older 'esptool' version, with args identical those just used with the 'newer' tool that failed.

Huzzah Feather Board, on protoboard with peripherals
C:\Users\DELL>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.5\esptool.exe -cd ck -cb 921600 -cp COM4 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
....................................................................................................................................................................................................................

Huzzah Feather Board, stand-alone
C:\Users\DELL>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.5\esptool.exe -cd ck -cb 921600 -cp COM8 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
....................................................................................................................................................................................................................

Huzzah Breakout Board, stand-alone, expect this to work
C:\WINDOWS\system32>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.5\esptool.exe -cd ck -cb 115200 -cp COM6 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
....................................................................................................................................................................................................................

Given all uploads worked using the 'older' esptool with identical args, it would seem the 'newer' esptool needs a different set of arguments. Hence its likely the invocation of the 'newer' tool here is most likely an error.

================================

2nd test of alternate upload(s):
  Newer 'esptool' version works with change of reset method, all cases.

C:\Users\DELL>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd nodemcu -cb 921600 -cp COM4 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
................................................................................ [ 37% ]
................................................................................ [ 75% ]
....................................................                             [ 100% ]

C:\Users\DELL>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd nodemcu -cb 921600 -cp COM8 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
................................................................................ [ 37% ]
................................................................................ [ 75% ]
....................................................                             [ 100% ]

Huzzah Breakout Board, stand-alone, expect this to work
C:\Users\DELL>C:\WINDOWS\system32>C:\SloeberBeR1\arduinoPlugin\packages\esp8266\tools\esptool\0.4.9\esptool.exe -cd nodemcu -cb 115200 -cp COM6 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin
Uploading 216096 bytes from C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65\debug\blink_wtdelay_gdbA_r1p65.bin to flash at 0x00000000
................................................................................ [ 37% ]
................................................................................ [ 75% ]
....................................................                             [ 100% ]

================================

This last test would indicate that the 'newer' esptool doesn't have an intrisic fault; it just needs different args.

Given this additional testing, its likely that

a) Preventing the 'newer' esptool from being invoked when the 'older' esptool is needed, and
b) Using a modified set of arguments when the 'newer' esptool is needed

would correct the problems seen the Huzzah Feather board.

jantje commented 7 years ago

I propose to give it a try by using the old esp tool for all boards. That is "how it should be" anyway. Can you change in the platform.txt the line tools.esptool.path={runtime.tools.esptool-0.4.9.path} to tools.esptool.path={packages}/esp8266/tools/esptool/0.4.5 And test with both boards you have?

mrwgx3 commented 7 years ago

Made the requested change to 'platform.txt' and didn't see any change in 'esptool' arguments:

LaunchingC:\SloeberBeR1\/arduinoPlugin/packages/esp8266/tools/esptool/0.4.9/esptool.exe -cd ck -cb 921600 -cp COM4 -ca 0x00000 -cf C:\Users\DELL\SloeberWork\Wksr1\blink_wtdelay_gdbA_r1p65/debug/blink_wtdelay_gdbA_r1p65.bin 
Output:
warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed
/arduinoPlugin/packages/esp8266/tools/esptool/0.4.9/esptool.exe finished
upload done

To be sure we're both on the same page regarding file location and syntax...

I changed file 'C:\SloeberHrdw\jantje\ESP8266\platform.txt', where 'C:\SloeberHrdw' is where I unzipped your hardware install.

Here are the changes I've made so far to 'platform.txt'.

# ------------------------------

tools.esptool.cmd=esptool
tools.esptool.cmd.windows=esptool.exe

# Attempts to solve Huzzah Feather upload problem

#   Jantje's suggestion
tools.esptool.path={packages}/esp8266/tools/esptool/0.4.5

#   My attempt(s)
# tools.esptool.path={runtime.tools.esptool.path} 

# Original, comment out when testing alternate
# tools.esptool.path={runtime.tools.esptool-0.4.9.path}

tools.esptool.network_cmd=python
tools.esptool.network_cmd.windows=python.exe

Before doing a test, I close and clean all projects, exit Sloeber, then restart it.

I too did a correction attempt on this file by doing a file search on '0.4.9' to locate the file, but got the same result. Since it didn't work, I assumed I entered an incorrect path specification and got a default invocation for 'esptool'. If there is such a check, could it be failing due to a corrupt string? Erroneous conditional compile? Just tossing out ideas...

jantje commented 7 years ago

have you done project properties->arduino->apply->ok?

mrwgx3 commented 7 years ago
 jantje commented 3 hours ago

 have you done project properties->arduino->apply->ok?

Didn't know that I needed to. Seems that I have to do this everytime I switch to a different project within the same workspace. Any way to do this automatically upon startup and/or change-of-sketch?

Progress has been made; I now see the expected 'esptool' version (old) and arguments, and the upload now occurs for the Huzzah Feather board. I still don't get a proper debug launch:

Error in final launch sequence
Failed to execute MI command:
-target-select remote /./COM4
Error message from debugger back end:
Bogus trace status reply from target: timeout
Bogus trace status reply from target: timeout

Note also that the blink LED turns on upon debugger launch, and turns off when the 'Problem Occured' message appears.

The Huzzah breakout board still works fine, good upload and debugger launch.

jantje commented 7 years ago

You only need to do project properties->arduino->apply->ok when you changed one of the underlying files. Note that V4.1 is better at noticing change and doing this for you. Did you see the comment of Paul van Veen?

Use \.\COMX instead of /./ !

mrwgx3 commented 7 years ago

No, I hadn't. No difference between Use ' .\COM4 instead of /./COM4', still getting 'Error in final launch sequence'. Thanks for your help!

jantje commented 7 years ago

We are way out of my comfort zone here. So I don't think I can help any further. Someone more experienced in the whole gdb remote debugging will be more helpful. If you find a solution please feed back so I can modify Sloeber or the documentation.

mrwgx3 commented 7 years ago

I've had a partial success, meaning that I've seen the debugger start correctly, but not consistently.

The whole problem to me seemed to be one of timing, i.e., things were just on the verge of working, but just not quite. I decided to do some baudrate tests, as this being the only timing parameter than be changed easily. To my surprise, I can get enter debugging mode if:

a) The upload baudrate is 115200 or below.
b) The debugger baudrate is also 115200 or below.

It's surprising that the upload baudrate is a variable here; I suspect it might have something to do with the reset function. If you have any information on adjusting serial timing in Eclipse/Sloeber, it would be useful.

Ultimately, I'll probably need a logic analyzer to resolve the issue, a task for a later day.

jantje commented 7 years ago

You know far more about this than I do. Good :-) this way it can get fixed. The debug launcher is from gnuarm https://github.com/gnuarmeclipse the gnuarm documentation http://gnuarmeclipse.github.io/ or @ilg-ul can help you with " information on adjusting serial timing in Eclipse/Sloeber,"

jantje commented 6 years ago

Is this still a issue? Did you fix it? Can you contribute the fix to the repository?

mrwgx3 commented 6 years ago

Hi @jantje

Yes, I believe its still an issue, but I haven't had the tools or time to look into it properly. Given my chedule, I'd mark this issue as 'needs to be looked into' and give it a low priority, or even close it. Best regards, mrwgx3

jantje commented 6 years ago

I'm seriously out of my depth here so I propose to close it and we can always reopen.

mrwgx3 commented 6 years ago

I'm seriously out of my depth here so I propose to close it and we can always reopen. I concur, close the issue.