ESP32 programming solution

Deepak
Posts: 12
Joined: Sat Jul 01, 2017 10:01 am

ESP32 programming solution

Postby Deepak » Wed Oct 18, 2017 1:51 pm

Hie,

I am developing a product based on ESP32. For development purpose I am using ESP32 doit kit and in this I don't need to do anything for programming. I just need to connect it to PC and start flashing and program gets loaded into it. But I want to know how it can be programmed if I am using only ESP32 IC for my production i.e. I wont be using development board. I want to know which pins of the IC should be used for programming externally may b using other esp32 board. Also guide me with the procedure to program it externally.

Regards
Deepak Patel

SoftwareSamurai
Posts: 17
Joined: Wed Sep 13, 2017 11:51 pm

Re: ESP32 programming solution

Postby SoftwareSamurai » Wed Oct 18, 2017 6:06 pm

I would recommend using the WROOM module, not just the IC. To program WROOM modules, search eBay for "ESP32 test board" and get one. They're designed to slot in a WROOM module for programming.

Deepak
Posts: 12
Joined: Sat Jul 01, 2017 10:01 am

Re: ESP32 programming solution

Postby Deepak » Tue Dec 12, 2017 10:04 am

Hi,
I am trying to program by esp32 dev kit using make flash or using flash download tool and it is getting downloaded properly on my desktop but if I try to download the same in other computer flash download fail showing error as "timed out waiting for packet header"
and also want to know Is flashing dependent on debug or release optimization level that can be set from make menuconfig? I have kept optimization level to "DEBUG"
Please help me out with this

Thank You.
Deepak Patel

User avatar
Vader_Mester
Posts: 300
Joined: Tue Dec 05, 2017 8:28 pm
Location: Hungary
Contact:

Re: ESP32 programming solution

Postby Vader_Mester » Tue Dec 12, 2017 1:07 pm

You can make a small jig or fixture with contact probes to contact the appriate pads of your board. By using a USB-Uart interface board inside the fixture (or like the configuration on the devboard), you can quickly program the modules before soldering, using just Uart as you normally would.
If you want to go pro, you can use a modified version of your circuit inside the Jig, so you can test if the programming was successfull, before soldering the module to your board.

If you program the boards after soldering, it is wise to make test points on the PCB or a programming connector to use the UART interface, and the strapping pins (which are the following):
MTDI
GPIO0
GPIO2
MTDO
GPIO5

Controlling these pins can set the boot modes for flashing and debug. Thereby you can program and debug-functionally test your board in one workstation/ work step 8-)

Info about this is in the ESP32 datasheet, page 10-11, Section 2.4 Strapping pins.

Also if you are using it as a product also consider using flash encryption, secure boot, and OTA update only, so the end users will have hard time messing with the module after it is shipped. More about this here:
http://esp-idf.readthedocs.io/en/latest ... ption.html

Code: Select all

task_t coffeeTask()
{
	while(atWork){
		if(!xStreamBufferIsEmpty(mug)){
			coffeeDrink(mug);
		} else {
			xTaskCreate(sBrew, "brew", 9000, &mug, 1, NULL);
			xSemaphoreTake(sCoffeeRdy, portMAX_DELAY);
		}
	}
	vTaskDelete(NULL);
}

Who is online

Users browsing this forum: Majestic-12 [Bot] and 97 guests