-->
Page 1 of 1

Retrieving uploaded hex

PostPosted: Tue Dec 06, 2016 8:08 am
by mconsidine
Hi,
I am trying to get a script like the one found here
http://electronics.stackexchange.com/qu ... th-avrdude
to work. The issue I have is with two parameters on this line
Code: Select allavrdude -p $avr -c stk500v1 -P $port -b $baud -U $memory:r:/dev/stdout:i > ./$dst.$memory.hex ||
                rm ./$dst.$memory.hex

namely "-p" and "-c".

I understand that the ESP8266 is a different architecture than Arduino and was wondering if anyone knew if a) avrdude could be used in this fashion with the ESP or b) is there a different program that accomplishes the same thing for the ESP? If "a" does anyone know what the parameters for "p" and "c" should be? In the example "p" is for a part number (e.g. a version of the ATMega) and "c" is for the compiler. In experimenting with "-p m328" and "-c avrispmkII" I get a connection and some timeouts, but no data.

(FWIW, I already know how to save the .hex that is uploaded from the Arduino IDE. What I want to understand is exactly what-is-where in an ESP once I program it, so that I can understand any potential for data being left over from a prior project, as well as to the extent that code is not obfuscated.)

Thanks,
mconsidine

Re: Retrieving uploaded hex

PostPosted: Tue Dec 06, 2016 9:37 am
by martinayotte
avrdude is not aware of ESP. So, it is not useful at all.
if you wish to read flash from ESP to save it's current firmware from flash into a file, simply use esptool.py.
https://github.com/espressif/esptool

Re: Retrieving uploaded hex

PostPosted: Thu Dec 08, 2016 10:26 am
by mconsidine
Hi,
Thanks for the reply and the pointer. That is in fact exactly what I should have been looking for! Sorry for the bandwidth waste.
mconsidine