I wanted to create my own custom board with Arduino on-board. So I bought an ATmega328P-AU (the SMD 32pin version) and I soldered it in place with a 16Mhz Crystal and 2x 22pF caps.
There really isn't anything else connected. All power pins are connected too.
My target was to first upload a bootloader, than use tx/rx to upload sketches. I connected my uC to a USBtinyISP programmer but I was getting problems such as invalid identifier etc..
I then scrapped the thing, and programmed an Arduino Uno as an ISP Programmer. I connected my board to the arduino following this tutorial Installing an Arduino Bootloader - SparkFun Learn
The first thing that the tutorial asks is to actually program the fuses using AVRDude using the following command WHICH WAS A SUCCESS (finally).
Then I continued by opening the Arduino IDE, selecting port/programmer/board and clicked on Upload Bootloader and it also worked.
But when I tried to upload bootloader the second time, I started getting the same original error. i.e. Yikes! Invalid Device Signature.
So I said, let me try to run the same identical Fuses code just as I did, and I got device signature 0x00000000
I thought that this might have burnt the chip, so I removed it, soldered a new chip and I tried programming the fuses again and it worked.
But this time I cannot upload the bootloader.
Yes, the atmega328p chip is empty. Which means that the fuses are probably set to the internal oscillator (1/8MHz). So by setting the fuses you can use your external crystal (16MHz).
What am I doing wrong?
Let us find out... Begin by trying the following line for me. With "ARDUINO AS ISP"
During the soldering process, I actually used flux to assist and it works like a charm. I can solder anything with that. I also used a multimetre to test each individual pin for shortages and all is perfect.
I programmed the fuses as I said and it worked the first time only and stopped... To my surprise, I refreshed the soldering and it worked!
I mean I can understand that this might have been a dry joint, but this was freshly soldered, and it worked once and not 30 seconds later!
I cannot understand or explain but basically I managed to put ADABoot on the chip.
Now I am trying to use the FT232R Beakout, Connected the ATmega328p to GND/3.3v and connected RX chip to TX breakout and TX chip to RX breakout.
I keep getting out of sync...
Yes, I mean AFTER you've programmed the bare chip, using ArduinoISP, with Adaboot, and you're trying to upload sketches after serial rx/tx, you should identify the board as a duemilanove. The board type is determined more by the bootloader that is running than by the actual hardware, and running Adaboot makes the target a duemilanove rather than an Uno.
Thanks buddy for that! I was getting to it. In fact I got there and I got this
avrdude: stk500_getsync(): not in sync: resp=0x00
Im trying to understand what's missing.
I have GND, RX, TX, VCC all connected to FT232RL and I have a resistor/capacitor connected from FT232 to Reset as in this image