Tell me more ×
Electrical Engineering Stack Exchange is a question and answer site for electronics and electrical engineering professionals, students, and enthusiasts. It's 100% free, no registration required.

I'm trying to build this Ambient lighting for PC. This worked flawlessly on my Arduino Uno. My next step was to make it using "Arduino on a breadboard". So I bought a blank ATmega328 chip and burned the Arduino bootloader (for the board "Arduino Duemilanove w/ ATmega328") onto it using the Arduino IDE and USBasp; and I know this has been loaded properly as this ATmega chip works fine on the Uno.

Then I made the USB-to-serial converter using FT232RL ; but its drivers didn't install on my PC (Windows 7 x64). I suspect I overheated the surface-mount FTDI chip and killed it while hand-soldering it.

So, I've kept it aside, and got this USB-to-serial converter bridge: (Sorry for the crappy pics) I used an additional ST232CN on my breadboard, to convert the voltage levels from RS232 to TTL, as shown in this page. And this works fine, as I verified from a loopback test. And I've connected pin 9 of ST232 to pin 2 of ATmega, and pin 10 to pin 3.

When I tried to upload a blink example from Arduino IDE, I get this error:

Binary sketch size: 1026 bytes (of a 30720 byte maximum)
avrdude: stk500_getsync(): not in sync: resp=0x00

When I do the verbose upload (Shift+Upload), I get this error/message:

avrdude: usbdev_open(): did not find any USB device "usb"

Also, I tried adding 1k pull-up resistors at pins 2 and 3 of ATmega, but didn't help. So I guess the problem now is in the serial communication from the ST232 to ATmega? And is there any special connection to the Reset pin of ATmega? I've pulled it up to 5V with a 10k resistor.

share|improve this question
A schematic and or picture of your breadboard setup would help. – sptrks May 1 '12 at 6:24
3  
Did you reset the chip just before, at the same time as, or just after commanding the upload? Whenever I've gotten the 'not in sync' error, it was related to that relative timing. For my breadboard, and Eclipse/AVRDude, ungrounding the reset pin just before or just as I click the upload command is the right timing. But also check that your PC really does see the adapter when you plug it in. – JRobert May 1 '12 at 17:42
1  
@potato_in_my_ear - The proper format for posting a solution is not an edit but an answer. Look below, and you'll see a box titled "Your answer" in which to enter it. After entering, people will vote on your answer, and you can 'accept' it by pressing the check mark to the left of the answer. – Kevin Vermeer May 1 '12 at 21:14
1  
@potato_in_my_ear: I'm glad that helped. You're a gentleman and a scholar - I'll make my comment an answer. – JRobert May 2 '12 at 15:58
1  
The solution is for people to stop providing answers in comments! – Kevin Vermeer May 2 '12 at 16:55
show 8 more comments

3 Answers

up vote 2 down vote accepted

Whenever I've gotten the 'not in sync' error, it was related to my just missing the reset timing (or forgetting the reset entirely!). For my breadboard, and Eclipse/AVRDude, un-grounding the reset pin just before or at the same time as I click the upload button is the right timing. But also check that your PC really does see the adapter when you plug it in.

Later arduino boards are built to reset whenever a serial connection gets made, and programmatically by the bootloader. This blog article describes how it works, and even more interestingly, how to hack it onto earlier boards. It shouldn't be too hard to put it on a breadboard if you wanted to. The chip needs to have a compatible bootloader, of course (which you've already put into yours). For breadboards, I just do the reset-button / mouse-click dance.

share|improve this answer
I found some one saying that you can get the avr tool chain to do the reset itself by editing avrdude.conf; here (in comments). But I'm not sure how to do that. Can you help. I hate pressing reset all the time.. – Anubis Nov 22 '12 at 4:47
This will require hardware support on the Arduino board or breadboard that later Aduino's have built-in; code alone can't do it. It's based on a capacitor from the serial DTR to the reset and a reset pull-up. If you have a older one or a breadboard, you'll need to add it. This EE StackEx question and the blog article I quoted should point you in the right direction. – JRobert Nov 28 '12 at 2:18

As @JRobert said in the comments, the right timing of grounding and ungrounding the reset pin on ATmega did the trick. Keep grounding the reset pin of the ATmega when you click "Upload", and just as it shows "Uploading", unground it.

share|improve this answer
Just got an arduino mini and I knew that I needed to press the reset button to upload code, but I couldn't find out when!!! This worked for me. Thanks. – Keegan McCarthy Aug 16 '12 at 16:50

I had the same errors I have seen posted on several sites RE: Arduino message "avrdude: stk500_getsync(): not in sync: resp=0x00" or similar.

I found that if I remove whatever is patched into D0 ([D0]DIGITAL pin Zero, farthest away from USB and Power jacks, also reads "RX").

I tried two different computers and got same errors and found out that if: 1- I remove the wire from or open the circuit to [D0] 2- Upload to Arduino 3- re-patch the removed wire or close the open circuit to [D0]

I have only encountered that error when I upload and this is my solution. for now.

Hope it helps.

Feels good to finally give some useful info back to a community!

share|improve this answer
1  
Response is a bit unclear: The sentence beginning "I found that if I..." is incomplete, not sure what you are trying to say there. Please edit, thanks. – Anindo Ghosh Nov 1 '12 at 5:22

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.