Pages: [1]   Go Down
Author Topic: How to use a CP2102 USB TTL Cable with Arduino  (Read 4305 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 2
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello,

I recently bought a usb ttl adapter which uses the cp2102 chip. I had some problems with autoreset when uploading a Sketch, and I found no clear description on how to get it working. To help other people, I wrote a small blog post which describes how to get autoreset working:

http://blog.tarn-vedra.de/2011/09/using-cp2102-on-arduino.html

Thanks.
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17294
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I think a cleaner and simpler solution is to just solder a .1ufd cap from the DTR pad to the base of the RST pin. Then turn the board over and cut the trace going to the RST pin. After that simple mod the RST pin can be wired to the processor's reset pin and the auto-reset function will work fine. I've done that mod and it works fine.

Lefty

Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 53
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Lefty can you make a picture of your mod? Thanks!
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17294
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Kind of hard to get good pictures but here is what I have.

First shows wiring the .1ufd cap from the DTR pad to the RST edge connector pin.
Second shows other side of the board where the original RST signal trace is cut.

Lefty



* 101_0501.JPG (54.68 KB, 640x480 - viewed 263 times.)

* 101_0502.JPG (43.02 KB, 640x480 - viewed 175 times.)
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 53
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks! Is it true that the tx and rx pins are reversed so you basically have to connect rx-rx and tx-tx..
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 48
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have actually had the exact same issue but i never had a cap between the pad (cant remember the name) and the rst pin and cut the trace.

Here is the pinout I was using on the arduino Pro Mini which , I imagine , is the same setup.

http://img12.imageshack.us/img12/663/arduino2.jpg

It is interesting that you mention the cap because I was under the impression I wouldn't need one since there is already a 1mfd cap on the RST pin arduino side.Then again it could be the RST on the other side of the board I was seeing there...
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 48
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Have a look here if you want to have a butchers at my topic too:

http://arduino.cc/forum/index.php/topic,96697.msg746116.html#msg74611
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 53
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Another thing, if the arduino already has a cap on reset pin - I'm assuming that the arduino pro mini has one (I looked at the schematic), then I don't need to add that cap to the programmer? Or it doesn't matter if there are maybe 2 caps?
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 538
Posts: 27089
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

There's a cap on the DTR pin on the arduino, which then connects to the reset pin.
Adding one to the CP2102 is not needed.
If you've built up your own arduino clone with no cap, then a cap on the programmer is a good idea.
Not sure if 2 in a row will work as intended - altho mathematically the resulting capacitance value is (C1*C2)/(C1+C2).
So two 0.1uS = 0.05uF, may go low long enough for a successful reset, or it may not.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Davie, Fl
Offline Offline
Newbie
*
Karma: 0
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Another thing, if the arduino already has a cap on reset pin - I'm assuming that the arduino pro mini has one (I looked at the schematic), then I don't need to add that cap to the programmer? Or it doesn't matter if there are maybe 2 caps?
You DON'T want ANY capacitor between reset and ground!  If the "arduino" has such a capacitor REMOVE IT!  The capacitor is connected in SERIES between DTR and the processor reset pin.  The processor should have a 10K resistor from reset to VCC.  A .1uf (100nf) capacitor will provide the correct timing of the reset pulse on a 5v circuit.  A 3.3 volt circuit might need a larger capacitor.  The value shouldn't be critical however.
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 538
Posts: 27089
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Calm down there scharkalvin! The arduino's have 0.1uF cap between the DTR pin and the reset pin, not from reset to gnd.
Of course, reset to gnd would just drag any reset pulse out as it charged up and came out of reset.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Pages: [1]   Go Up
Jump to: