Sysprogs forums › Forums › VisualGDB › Altera Bus Blaster to program ESP8266?
Tagged: bus blaster, swd
- This topic has 6 replies, 3 voices, and was last updated 2 years, 2 months ago by fatalfeel.
-
AuthorPosts
-
January 13, 2017 at 20:08 #10073gojimmypiParticipant
I’m still on day one of my evaluation… 🙂
I understand in concept how VisualGDB works, as I’ve been able to single-step on my MSP430.
My real interest is the ESP8266, but I don’t have any of the listed programming interfaces (I’m considering the Segger J-Link) – but in the meantime I am selecting “interface/altera-bus-blaster.cfg”
When pressing the “Test Settings”, I see this error:
C:\SysGCC\esp8266\esp8266-bsp\OpenOCD\bin\openocd.exe -f interface/altera-usb-blaster.cfg -f target/esp8266.cfg
Open On-Chip Debugger 0.9.0 (2015-11-04-20:38)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Warn : Adapter driver ‘usb_blaster’ did not declare which transports it allows; assuming legacy JTAG-only
Info : only one transport option; autoselect ‘jtag’
Warn : Transport “jtag” was already selected
trst_and_srst separate srst_gates_jtag trst_push_pull srst_open_drain connect_deassert_srst
adapter speed: 1000 kHz
stop_wdt
Info : No lowlevel driver configured, will try them all
Error: Altera USB-Blaster II not foundI’m certain that it is there, as not only is it listed in Device Manager, but the VisualGDB USB Driver Tool shows it with the matching Vendor ID and Device from the config file. I also tried creating a custom file with explicit settings, but same result.
fwiw – I also tried my Bus Pirate, also not working:
C:\SysGCC\esp8266\esp8266-bsp\OpenOCD\bin\openocd.exe -f interface/buspirate.cfg -f target/esp8266.cfg
Open On-Chip Debugger 0.9.0 (2015-11-04-20:38)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Error: The specified debug interface was not found (buspirate)
The following debug interfaces are available:
1: ft2232
2: ftdi
3: usb_blaster
4: usbprog
5: jlink
6: vsllink
7: rlink
8: ulink
9: arm-jtag-ew
10: hla
11: osbdm
12: opendous
13: aice
14: cmsis-dapI realize the Bus Pirate and USB Blaster are not really mainstream debuggers, but since they are listed as options, I was hoping to get them to work – at least the USB Blaster. Is this possible?
Thanks
January 14, 2017 at 02:00 #10074supportKeymasterHi,
We have never tested OpenOCD with any of those, so their support may be outdated or they may not be compatible with ESP8266. We would recommend trying it with Olimex ARM-USB-OCD-H; it is fairly inexpensive and works very well.
January 14, 2017 at 12:41 #10075gojimmypiParticipantThanks for your reply. I’m looking at the ESP8266 tutorial here:
http://visualgdb.com/tutorials/esp8266/
I was about to order an Olimex ARM-USB-OCD-H per your suggestion, however:
The end of Step 1 says:
Note that we use the Olimex USB-OCD-H as a USB-to-COM adapter only as the Xtensa JTAG software does not support it (supported devices are listed below).
Which sounds like the OCD-H is *not* being used as JTAG, rather a simple USB-to-TTL (Rx/Tx) port?
Further down in Step 7 there’s a note:
VisualGDB supports 3 debug methods for ESP8266 devices:
- A special OpenOCD port that supports all JTAG programmers supported by the original OpenOCD
- Xtensa OCD Daemon (xt-ocd) that supports ML605, Flyswatter 1/2/3, Jtagkey 2, Olimex tiny-h, Segger J-link, ByteTools Catapult, RVI JTAG and Macraigor probes
- GDB stub from Espressif that does not requre a separate JTAG connection
Note it specifies a *different* Olimex device, the  “Olimex tiny-h” – which is listed as a USB JTAG device here: https://www.olimex.com/Products/ARM/JTAG/ARM-USB-TINY-H/
The ARM-USB-OCD-H is listed as a “3-IN-1 fast USB ARM JTAG, USB-to-RS232 virtual port and power supply 5VDC device” here:
https://www.olimex.com/Products/ARM/JTAG/ARM-USB-OCD-H/
and both of the products say “supported by OpenOCD arm debugger”
Am I misreading the tutorial? Could you please confirm the recommendation for ARM-USB-OCD-H despite what Steps 1 & 7Â say? (I think they may actually be essentially the same device; the more expensive one including the Tx/Rx & power, eh?)
As I have no experience with these Olimex devices, any suggestions or clarifications will be greatly appreciated before I place an order. 🙂
Thanks
January 14, 2017 at 18:01 #10076supportKeymasterHi,
Sorry about the confusion. The tutorial mentions that Olimex ARM-USB-OCD-H is not supported by the Xtens JTAG software that is deprecated in favor of OpenOCD. If you are using OpenOCD (see the link from the original tutorial), you can use it. We have explicitly tested it with ARM-USB-OCD-H and have feedback from other users that the Tiny version works as well.
Hence we would recommend using ARM-USB-OCD-H, although the Tiny version is most likely OK as well.
February 4, 2017 at 23:18 #10308gojimmypiParticipantJust closing up this issue for anyone else that comes looking: Don’t even bother trying to get the Altera Bus Blaster programming an ESP8266 from VisualGDB. It won’t work. For one – there’s no reset control line.
I did end up buying an Olimex ARM-USB-OCD-H from Mouser Electronics for about $60. Debugging is not very intuitive. The result of single-stepping is a bit unexpected and even unpredictable. It works, you just need to know the tricks. I have a video that demonstrates this: https://youtu.be/9Hid7ixEigM
There’s a longer thread over on the Olimex forum, as I originally thought there was a problem with their device (but not):Â https://www.olimex.com/forum/index.php?topic=5676
Bottom line is many errors can (apparently) be ignored; Debugging may be actually working, even though it looks like it is not.
February 5, 2017 at 03:59 #10311supportKeymasterHi,
Thanks for confirming this. ESP8266 and ESP32 devices are relatively new and the debugging experience is often unreliable. Knowing the limitations, it is usually possible to get meaningful debug sessions, but the usability is unfortunately never near the ARM-based devices. VisualGDB tries to address some of the issues like disabling watchdogs and programming SPI FLASH, but there are unfortunately still many missing pieces.
October 10, 2022 at 15:01 #33297fatalfeelParticipanthere is teaching you use openocd flash bus blaster v3 or v4 to swd mode
https://fatalfeel.blogspot.com/2013/09/bus-blaster-flash-to-swd-mode-in-openocd.htm -
AuthorPosts
- You must be logged in to reply to this topic.