-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Programming ESP32-C3-MINI-1 module using JTAG (OCD-390) #168
Comments
@Wasabinary aside from programming the application binary, have you also programmed the 2nd stage bootloader and the partition table binaries? |
Oh so I definitely missed a step somewhere... Indeed, I only compiled the hello-world example and tried to flash the binary into my ESP32-C3, and I'm completely unaware of the steps you are referring to... Where can I find the resources about these in order to properly prepare the chip to host my firmware ? |
I think I got it, building the app also creates a bootloader folder and a partition_table folder into the build folder of my projet. Do I need to use JTAG the same way in order to upload bootloader.bin and partition-table.bin into my chip ? |
@Wasabinary yes you can with -c "program_esp_bins build flasher_args.json verify reset exit": |
Yaaay it works now! The command given by @erhankur did the trick:
It uploaded partition-table.bin, bootloader.bin and hello-world.bin one after the other, and now my application is running fine: no more flash mapping error and no more invalid header error. Once again, thanks a lot! |
I use a esp32dev and it works perfectly not using SPIFFS - the "Hello" project |
Hi, I can't find the file "target\esp32dev.cfg" you are refering to in my own openocd-esp32 folder. But may be you should try with "target\esp32", that should be fine |
Hi - thanks for your reply. I have trying to get it to work - I ran into other problems and have not been able to get back yo you. Now I am simply not able to execute the command: "openocd" from my project directory but have to change to the tool-openocd-esp32" directory and then I execute this: The result is this: I am pretty sure that it could be my setup - wrong path - but I don't know how to fix it. Some os us needs more... :-) |
I think the best way to make sure you don't have path related problems is to use absolute path for everything (including openocd.exe, which is in .espressif\tools\openocd-esp32\v0.10.0-esp32-20211111\openocd-esp32\bin fodler in my case. Same thing for .cfg files and flasher_args.json, use absolute paths so you will not have any problem linked to that. On the other hand, I remember having problems with program_esp_bins command, and I managed to flash my ESP32 by flashing build/bootloader/bootloader.bin, build/partition_table/partition-table.bin and build/application.bin one by one with the corresponding offsets. These offsets can be found in build/flasher_args.json |
To make this working you either need to invoke this command from your project dir (implying that |
Thanks Guys.... :-) I'm sure I can make this work for me. Else "I'll be back" as Sshwarzenegger says.... |
Hi,
Continuing my journey trying to use JTAG on ESP32-C3, I am now trying to flash an ESP32-C3-MINI-1, which is connected following the reference design of this module.
After successfully burning the JTAG_SEL_ENABLE efuse, and pulling it to 3.3V in order to enable JTAG over GPIOs, I'm now trying to flash the "Hello World" ESP-IDF example using a JLINK and the latest openocd-esp32 version.
Unfortunately, I get stuck with error messages that I did not encountered using an ESP32-C3 devkit when running openocd -f interface\jlink.cfg -f target\esp32c3.cfg -c "program_esp hello-world.bin 0x10000 verify reset exit":
Even if it seems like programming succeed, I'm confused by this error message:
Moreover, after connecting an FTDI cable to RXD and TXD pins, all I this error printing again and again:
Obviously, I did something wrong to my chip...
I thought using JTAG would be very straight forward after burning the efuse, but I'm really struggling to finally succeed at programming ESP32 modules for custom PCB...
Any help would be very welcomed...
The text was updated successfully, but these errors were encountered: