Maker Pro
Maker Pro

building an AVR programmer CABLE

I'm trying to build a parallel port AVR programmer cable.

Surprisingly, this is turning out to be the most complex part of
programming my ATTiny13. (I already know I'm going to use WINAVR and
AVRDUDE; the tough part for me is building the cable.)

I'm planning on building this:

http://www.tldp.org/linuxfocus/English/November2004/article352.shtml

I bought a male DB25 from Radio Shack (a part I forgot to order from
Mouser... but no way I'm paying an extra $6 for shipping just for a
DB25!), and am planning on using parallel pins 1, 2, 11, 16, and 18.

I was planning on using a Cat5 cable for the wiring, and using the
solid colors only: green, blue, orange, brown, and using the white
striped wires for shielding to minimize crosstalk.

But wait... I need 5 wires. Cat5 (with shielding) only gives me 4.

So, I've got a few options:

1) completely strip the Cat5 wire, and run 5 wires parallel (ugly) to
minimize crosstalk;
2) use one of the white striped wires for ground.

I'm leaning towards (2), but I'm trying to figure out what I can pair
it up with.

What is the function of the RESET pin when programming an AVR? Does
it pulse, or is it steady...? I'm guessing SCK, MOSI and MISO will be
pulsing like crazy, and might introduce crosstalk...

Or am I worrying too much?

Advice requested.

Thanks,

Michael
 
L

linnix

Ok, thanks everyone.

You might also want a small cap to bring up the reset line slowly.

Hey, you are stealing my ideas, part of it anyway.

I use USB to RJ-45 to pin headers for ISP and Jtag. I've done it for
AT90USB162, AT90USB1287, ATmega169 and ATmega649. They works fine.

See: http://linnix.com/avr.jpg
 
You might also want a small cap to bring up the reset line slowly.

Hey, you are stealing my ideas, part of it anyway.

I use USB to RJ-45 to pin headers for ISP and Jtag. I've done it for
AT90USB162, AT90USB1287, ATmega169 and ATmega649. They works fine.

See:http://linnix.com/avr.jpg- Hide quoted text -

- Show quoted text -


Stealing your ideas, huh? I was just trying to find some way of
getting 5 wires into my programmer... got a garage full of junk; used
some old Cat5 wire that I'm not using anymore (and I discovered why
I'm not using it anymore, too: it's stranded wire, not solid copper
wire... yuck. Gotta solder it...)

It's my first uC project... once I get my blinky working, hoping to
make it generate two square waves for me...

Michael
 
L

linnix

Stealing your ideas, huh?

Just kiding, but RJ-45 cat5/6 are great for quick connect/disconnect
setups, as long as you don't plug them in the ethernet jacks.
I was just trying to find some way of
getting 5 wires into my programmer... got a garage full of junk; used
some old Cat5 wire that I'm not using anymore (and I discovered why
I'm not using it anymore, too: it's stranded wire, not solid copper
wire... yuck. Gotta solder it...)

My cat5/6 wires are soild. If you are running long wires, make sure
they are surge protected. I toasted many micros, some on very long
wires.
 
M

Meindert Sprang

linnix said:
You might also want a small cap to bring up the reset line slowly.

That cap is even recommended very strongly in the AVR datasheets, to prevent
any accidental resets due to EMC issues.

Meindert
 
J

Jasen Betts

Surprisingly, this is turning out to be the most complex part of
programming my ATTiny13. (I already know I'm going to use WINAVR and
AVRDUDE; the tough part for me is building the cable.)

http://www.tldp.org/linuxfocus/English/November2004/article352.shtml

I was planning on using a Cat5 cable for the wiring, and using the
solid colors only: green, blue, orange, brown, and using the white
striped wires for shielding to minimize crosstalk.

But wait... I need 5 wires. Cat5 (with shielding) only gives me 4.

only three of them carry high speed data
So, I've got a few options:

1) completely strip the Cat5 wire, and run 5 wires parallel (ugly) to
minimize crosstalk;
2) use one of the white striped wires for ground.

the Atmel STK200 parallel programmer (which has a chip in it to do level
conversion) works fine with a 3m ribbon cable. don't worry, the data
rate is relatively low (10KbPS maybe) and pretty much any wire will do.
I'm leaning towards (2), but I'm trying to figure out what I can pair
it up with.

What is the function of the RESET pin when programming an AVR? Does
it pulse, or is it steady...?

It's mostly steady.

SCK sees the most pulses, MOSI and MISO see almost
as many, you'll find timing diagrams in the back of the data sheet.
I'm guessing SCK, MOSI and MISO will be
pulsing like crazy, and might introduce crosstalk...

Or am I worrying too much?

way too much!

Bye.
Jasen
 
D

David M. Palmer

I'm trying to build a parallel port AVR programmer cable.

If your goal is to program AVRs, rather than to build a cable, you
might want to check out an $18 USB programmer kit which got good
reviews:
<http://www.makezine.com/blog/archive/2007/07/usbtinyisp_inexpensive_us.
html>
(I don't have any direct experience with this, I just came across it in
my browsing.)

Of course, you're learning a lot more building your own, so if that's
your goal, have fun.
 
If your goal is to program AVRs, rather than to build a cable, you
might want to check out an $18 USB programmer kit which got good
reviews:
<http://www.makezine.com/blog/archive/2007/07/usbtinyisp_inexpensive_us.
html>
(I don't have any direct experience with this, I just came across it in
my browsing.)


Did you mean this one?
http://www.ladyada.net/make/usbtinyisp/

(The link you gave me was dead - at least when I tried it.)

Of course, you're learning a lot more building your own, so if that's
your goal, have fun.


Yep, learning as I go. Otherwise I'd just buy everything... then
what's the point...? ;-)

Just last night I was proud of finishing my cable... even found a 5-
pin header from an unused motherboard plug that I could plug into my
breadboard, and soldered everything (while the kids were asleep - so
they wouldn't breathe in the lead fumes).

Then I realized I switched the pinouts for my male DB25 plug...
AAAHHH!!!
http://www.doc.ic.ac.uk/~ih/doc/par/doc/regpins.html

Have to buy more solder...



Thanks all,

Michael
 
M

mc

Just last night I was proud of finishing my cable... even found a 5-
pin header from an unused motherboard plug that I could plug into my
breadboard, and soldered everything (while the kids were asleep - so
they wouldn't breathe in the lead fumes).

There's no lead in the fumes. The solder is barely hot enough to melt and
nowhere near hot enough to vaporize.

Admittedly, the burnt rosin flux can be irritating.

But don't your children breathe almost as much air when asleep as when
awake? :)
 
There's no lead in the fumes. The solder is barely hot enough to melt and
nowhere near hot enough to vaporize.

Admittedly, the burnt rosin flux can be irritating.

But don't your children breathe almost as much air when asleep as when
awake? :)


Ah, no lead? When I was a kid I thought solder was 70% lead. And
this piece was from my dad's shop, probably a few years (decades?)
old... I only had a few inches of solder.

I just came back from Wal-Mart and bought a new roll of solder; about
$4.50 for 5 oz, 95% tin, 5% antimony. Wow... expensive.

Kids were in the bedroom, silly... I was soldering on the dining room
table.

Michael
 
M

mc

There's no lead in the fumes. The solder is barely hot enough to melt
Ah, no lead? When I was a kid I thought solder was 70% lead. And
this piece was from my dad's shop, probably a few years (decades?)
old... I only had a few inches of solder.

Solder is still commonly 63% lead. But the lead does not vaporize at
soldering temperatures.
I just came back from Wal-Mart and bought a new roll of solder; about
$4.50 for 5 oz, 95% tin, 5% antimony. Wow... expensive.

Yes; that is the new kind, harder to work with; be sure to get it hot
enough. I still use leaded solder as much as I can because it works better.
Kids were in the bedroom, silly... I was soldering on the dining room
table.

I figured as much but couldn't resist giving you a hard time :)
 
T

Tom Lucas

mc said:
Solder is still commonly 63% lead. But the lead does not vaporize at
soldering temperatures.


Yes; that is the new kind, harder to work with; be sure to get it hot
enough. I still use leaded solder as much as I can because it works
better.

With the Reduction of Hazardous Substances directive in Europe then
pretty much all our solder has gone to the lead free kind. It is more
expensive and harder to work with but at least we're not killing
dolphins - or whatever it is that lead does.

Fortunately, the equipment we produce is instrumentation and thus exempt
from the directive but I expect the goal-posts to move later next year
to encompass our field so we've moved to RoHS compliance in preperation
for that.

However, during development then I do tend toward leaded solder if it
looks like I might have to remove a part again later. I find that
soldering with the lead free stuff is fine (with a good hot iron) but
desoldering is a real pain - the leaded stuff comes up so much more
easily.

That's dangerous too. When I was little my dad once managed to singe the
dining room table soldering and my even now my mother still him about it
whenever he gets his iron out. And they've had three dining tables
since!
 
M

Meindert Sprang

Tom Lucas said:
With the Reduction of Hazardous Substances directive in Europe then
pretty much all our solder has gone to the lead free kind. It is more
expensive and harder to work with but at least we're not killing
dolphins - or whatever it is that lead does.

I sometimes wonder if whatever we save by implementing RoHS is not undone by
the fact that we now have to solder at higher temperatures and therefore
consume more energy.

Meindert
 
T

Tom Lucas

Meindert Sprang said:
in
message news:[email protected]...

I sometimes wonder if whatever we save by implementing RoHS is not
undone by
the fact that we now have to solder at higher temperatures and
therefore
consume more energy.

Meindert

Or the fact that many older lead parts will never get sold and end up in
landfills rather than used in products which won't get thrown away.
 
M

Meindert Sprang

Tom Lucas said:
Or the fact that many older lead parts will never get sold and end up in
landfills rather than used in products which won't get thrown away.

Prezactly!

Meindert
 
J

Jonathan Kirwan

Prezactly!

Meindert

As far as the parts go, that price has to be paid at some point or
else, if no price is to be ever paid, there never will be any change
at all. So I suppose that's just a barrier to climb over and not look
back on -- or else do nothing.

I don't know about the higher temperatures used and the associated
aggregate energy costs over time... but frankly I consider many
electronics products to be of "very high utility value," which makes
their energy use well worth the environmental costs.

For example, acute respiratory infections (ARI) kill more than 2
million children every year. It's the larger cause of child mortality
and kills more than HIV/AIDS plus malaria plus measles, combined. It
can become pneumonia and studies show that timely treatment reduce
those mortalities by about half. Pulse oximeters actually help reduce
mis-diagnoses by a large factor (I think I've read somewhere, by a
factor of 8 or something similarly fantastic from my point of view)
and have helped us achieve a successful diagnosis rate, where pulse
oximeters are applied, of about 99% in these pneumonic ARI cases.

Frankly, any energy cost we pay for a pulse-ox in the right place and
time is probably worth it.

Of course, that's not all we do with electronics. They also save
lives in industrial situations (for example, recognizing early when a
saw mill's motor driving a saw blade may be nearer to a destructive
wear out event.) Or they may simply help reduce energy costs in
otherwise seriously wasteful situations (glass, aluminum, and steel
mills, for example.) But that is some of it. Perhaps those kinds of
benefits make RoHS energy costs pale, in comparison. Just a thought.

Jon
 
M

mc

Of course, that's not all we do with electronics. They also save
lives in industrial situations (for example, recognizing early when a
saw mill's motor driving a saw blade may be nearer to a destructive
wear out event.)

Or even recognizing when the blade is cutting material with the wrong
elasticity, which might be a finger or an arm rather than a block of wood!
At least, I've heard of this being done.
 
H

Hans-Bernhard Bröker

Tom said:
Or the fact that many older lead parts will never get sold and end up in
landfills rather than used in products which won't get thrown away.

Nice idea in principle, but it has a major flaw. There's no such thing
as a product that won't get thrown away. It'll just get thrown away a
bit later.
 
C

CBFalconer

Hans-Bernhard Bröker said:
Nice idea in principle, but it has a major flaw. There's no such
thing as a product that won't get thrown away. It'll just get
thrown away a bit later.

Some actually get recycled :)
 
Top