I had an interesting idea recently, but don't have all the knowledge needed to make it work. I know that several people have made Arduino programmers with an esp8266, allowing them to program the Arduino over WiFi.
However, I am interested in being able to program the raw chips (attiny84 or atmega328p) via the ICSP method, since they don't normally have a bootloader.
But the application I think would be really useful is the ability to upload a HEX file to the internal filesystem and use the esp8266 as a batch programmer (no need to have the computer recompile and upload each time; the file would be ready to go at the push of a button).
The issue is that I have no information as to how to actually build the programmer portion of this. I can set up a web UI, file upload, menu system, and even find the hex file, but all the current solutions merely act as an interface for Avrdude. I don't know how that issues commands or provides the programming file.
I need a method to issue the programming commands over (presumably) SPI and transfer the file from SPIFFS, rather than have it fed piecewise from the computer. Ideally I need some way to burn fuses too, and a configurable SPI speed (since the chips have the slow clock initially).
Can anyone help me with this or point me to a code library? Note: I am aware of (and inspired by) the ISPNub, but I am unsure of how to port it to the esp8266 (it doesn't use the SPI library, but a custom implementation that won't port easily), or how its method of reading the firmware from flash would differ from the need to parse the hex file.