StandAlone Arduino to arduino .HEX uploader

Hi there.
Let me tell what I wish to do:
1St:
Have an any arduino (ex. MINI), connected with an SD Card containing a .HEX file, a code of course.

Let's connect this one to an another board , like UNO (just for a difference), via native SERIAL (Rx, Tx).

Here is my question:
can I use this setup to UPLOAD to the UNO that .HEX file from NANO's SD Card ??? (of course by hitting a button on the NANO). ???

Basically I am asking if if possible to use a board as a portable standalone uploader ???

Thanks for any advice, Peter.

Sure all you have to do is replicate the code that the IDE uses to upload the code. Note this is a non trivial project.

I think you missing my question... (sorry) What I am asking is if I can make a BOARD wich have an SD attached with a .HEX on it, (not an isp, computer, etc) to act as a STANDALONE programmer for other boards, just via serial protocol... Ex I have the NANO with CARD, going to my neighbor, plug a Rx-Tx to his UNO (for ex,) and by hitting a button on my "DEVICE" just upload that .HEX to my neighbor's board...

This might help: Gammon Forum : Electronics : Microprocessors : Atmega chip stand-alone programmer to upload .hex files

@sterretje, Interesting, (took a look there) thank you. but I'll wait for other suggestions, kuz I am VERY interested in the SERIAL variant...

@oldcurmudgeon why what IDE does? avrdude uploads the hex, not the IDE

The IDE talks to the boot loader via a serial protocol. This need to be replicated. I don't know if the IDE does this directly or via Avrdude. I thought Avrdude only did ISP, parallel and HV serial (not boot loader).

Other than occasional ISP use I just use the boot loader upload and don't worry about how it works.

That is especially what I want to know... HOW they communicate, I am plenty of knowledge to use avrdude, but I wish to pass to simply what I need, so get a NANO with me and program an another.... WITHOUT a laptop or desk computer... just a "STICK" dedicated to do the job

..and PLEASE, DO NOT make personal talkshows in the topic, I don/t wish do deviate my topic on discussions between people, hope you get it... personal stuff in private please !

THANKS IN ADVANCE !!!!

That is fully described in the avrdude documentation. Plenty of literature from Atmel (now Microchip), too. The protocol has been standard for a couple of decades.

No it's not. Avrdude is a huge program supporting several dozen different programming protocols, all of which are described in separate documents.

The serial protocol used for uploading AVR Arduinos is a subset of STK500v1.
You can find more details here: HowOptibootWorks · Optiboot/optiboot Wiki · GitHub
(and related pages)

(What you want to do is possible. I don' t think it has been done yet, mostly because once you have an Arduino-class device "local" to the target to be programmed, it's just as easy (and more powerful) to use the real ISP programming protocol.

You're right, I should have added "and referenced documentation".

There is no excuse for the OP not to do their own research.

Think again :wink: If you enable verbose output during upload you can see the command issued when you do a normal upload.

The bootloader(s) use the same communications protocol as various device programmers; avrdude doesn't actually know that it's talking to a bootloader.

"Several Dozen" was an understatement, BTW. I counted, and there are 113 options for the "-c" avrdude option. (some are similar to one another, like the same comm protocol with a different USB id.)

this could help
https://github.com/ciminaghi/libdfu

as Arduino library:
dfu.zip (57.9 KB)

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.