I was able to use the MIT HLT ATtiny85 tutorial to program the 85 on a breadboard without any problems using Arduino as an ISP. I can’t figure out how to do the same with the 328. But, of course I am able to program the 328 (since it has the bootloader) by placing it in the Arduino socket.
Search "Circuit (targeting an AVR on a breadboard)"...http://arduino.cc/en/Tutorial/ArduinoISP
Step 1.5 is missing from the instructions at the top.
I want to have standard 2x3 headers on my projects so that an end user can plug in (USB) and upload new firmware that I post or email to them.
If you use a Teensy, the end user will only need a USB cable.
i. can buy a bootloaded chip or bootload it with my hardware programmer and then routine firmware updates can be done without the programmer using serial programming.
No. The problem with your statement is terminology. "Serial programming", in AVR vernacular, is what you did with the ATtiny85. This is a more accurate statement...
i. can buy a bootloaded chip or bootload it with my hardware programmer and then routine firmware updates can be done without the programmer using TTL
ii. I was able to program the ATtiny85 because the Arduino as ISP sketch made the Arduino function as a hardware programmer.
USB to serial converter to establish hardware link to the boot loaded chip. ... i. This is built into the Arduino board
Yes. Either as an FTDI chip or as an Atmega8U2 processor.
ii. It can be a separate piece plugged between a boot loaded chip and the PC.
Yes. Typically called a USB-to-serial converter. Sometimes "TTL" is included in the name.
It can cost as much as a hardware programmer
Only if you are not shopping in the right places.
but it should be “safer” and simpler for end user.
No way to respond. You have not defined "end-user". My typical end-user builds air conditioner controllers using AVR processors so they would prefer to use their own programmer.
iii. There are many available and they seem to support different subsets of the AVR family. Which ones are inexpensive (for end user) and will work with 85
None. The ATtiny85 processor does not have a serial port and really does not have enough memory or support for a bootloader.
and 328 chips?
retrolefty likes this one...http://arduino.cc/forum/index.php/topic,69933.msg534733.html#msg534733
Software to load hex file to chip. ... i. avrdude
You want confirmation that AVRDUDE can be used to upload hex files? If that is the case, the answer is "yes".
ii. I assume one could right a “batch” file (Windows) with avrdude command lines to automate this for the end user.
Probably not. There is no way to know when the batch file is written what serial port is assigned to the USB-to-serial converter.
They would need to install winavr
No. AVRDUDE does not need the full WinAVR install to function.
download the hex file and batch file, plug in their USB to serial adapter, and execute the batch to program the chip.
Yes. With the caveat that the user will need to provide the serial port.
iii. Could it be done from the Arduino IDE by plugging directly from PC to serial converter to project ISP?
By "ISP" do you mean the six pin connector?
I assume I would need to develop the Arduino suport files so that my project (chip, clock speed, etc.) would appear as a menu choice on the boards menu.
If you use the 328 processor and an Arduino bootloader (like Optiboot), one of the existing choices will work just fine.
A chip specific “core”? ... i. I don’t know what this is unless it is a port of Arduino commands to make them work on different AVR’s.
ii. Is it used by the compiler?
iii. Are they specific for different compilers or different IDE’s or different programming (as in chip uploading) methods or just different chips?
For the most part, just different processors.
iv. Was this part of the HLT files I downloaded to program the ATtiny using Arduino as ISP?
v. Is this what the Arduino Tiny project is?
Yes. Arduino Tiny is meant to be more than a core but time has prevented it from evolving very far past that.
vi. When I compile a sketch in Arduino IDE does it use this core to create the appropriate hex file for the target chip?
vii. Would I then need to edit board.txt and other files for each chip I want to create hex files for?
Maybe. For the 328 processor, you can very likely use an existing entry.
Is this what HLT did for the 85?
Sort of. The Arduino IDE supports multiple boards.txt (and programmers.txt) files. I believe Alessandro Saporetti's core (the one available from HLT) includes a board.txt file. In other words, there was no need to edit the boards.txt file that is included with the Arduino IDE.
Can it be done for the 328 to generate hex files for ISP loading into stand alone 328’s?