Chat here is you are connecting ESP-xx type modules to existing AVR based Arduino

Moderator: igrr

User avatar
By NailBuster
#38152 Hey, I've connected pro-mini (3.3v 8mhz) to nodemcu and everything is working well....

I'm trying to figure out solution to flash the AVR through ESP. (using spi).

I've figured out how to flash the pro-mini already via esp12 spi and using the AVRISP sample from esp8266github.....

issue is that still requires AVRDUDE.exe (which works but only for linux via tcpip connection). I actually got it working in windows using a virtual com2tcp software but its too complicated to setup just to flash promini...

I'd like to be able just to provide a HEX file via upload or within spiffs and have it program the promini easily....

I've searched and examined other projects but couldn't find something i could compile easily within arduinoIDE....

any ideas or code/projects that may work.....
User avatar
By NailBuster
#38245 yes, I've looked through that but the optiboot programming seemed too tied to the environment....looking for something that is more "flash_avrfile("xxx.hex")" type independent code....

I've found some old files from Nick Gammon, maybe will have to port that over to esp....
User avatar
By bjpirt
#38277 There's also this:

https://github.com/mirobot/mirobot-wifi ... /arduino.c

Which I use to reflash an Arduino using the bootloader protocol over serial. It caches a copy in flash first before writing it to the Arduino and has been pretty reliable. In any case you could use this lib as the basis of what you want to do

Ben