i have been searching about how we can use the arduion IDE (0019) to program and compile to a .hex file. Then upload this .hex file to a brand new virgin atmega328p in AVR Studio (4.18) through an AVRISP mkII. Many topics were about how to use Arduino board as ISP. But i want the other way around. The closest topic about what i want is:
http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1264365471/7
p.s.
-
the atmega328p-au (not the DIP one) is fresh, no arduino bootloader, only programmed for a few times with the AVR Studio and AVRISP mkII for some simple ADC and USART programs.
-
assuming the atmega328p-au has the same fuse bits (attached with a 16Mhz crystal) and lock bits setting as the atmega328p-pu on the arduino duemilanove board.
Extra question:
if i change the crystal to 20Mhz, which is supported by the atmega328p-au by the way, does it mean i can't use the arduino IDE to write and compile my desired program any more, or i just need simply to redefine the F_CPU to be 20000000UL ??
if this method really works, then i can just work with arduino sketch, which i m more familiar with. LOL
thank you in advance!! ;D ;D