EmbeddedRelated.com
Forums

Simple Clockable Decoder Chip

Started by Unknown May 3, 2008
Let's say we have an 8-Bit shift register. We reset it so that its
outputs are as follows:

    00000000

We then set the data input high and clock it:

    10000000

We then drop the data input low and continuously clock it:

    01000000
    00100000
    00010000
    00001000
    00000100
    00000010
    00000001

This is done easily using two pins from a microcontroller, one pin for
the data input and another pin for the clock input.

I'm looking for something that will do the same job with just one pin
(i.e. a pin to clock it). That is to say, when you reset it, it
becomes:

    10000000

and then when you clock it, it cycles thru the outputs:

    01000000
    00100000
    00010000
    00001000
    00000100
    00000010
    00000001
    10000000
    01000000
    01000000

I've googled a bit and the closest I've come to this specification is
the 4017 chip in the 4000 CMOS family. Here's a quick paragraph about
it:

http://www.kpsec.freeuk.com/components/cmos.htm#4017

The only problem though is that I need a chip that will count to 16
instead of 10. Does anyone know of a similar chip that will cycle thru
16 different outputs?

Then again I could always just use two of these chips, but I just
thought I'd check to see whether there was a more suitable chip out
there.
Tom�s � h�ilidhe wrote:


> I'm looking for something that will do the same job with just one pin > (i.e. a pin to clock it).
Look, we told you last time that this was a daft idea. What do you think asking the same question again will change?
> The only problem though is that I need a chip that will count to 16 > instead of 10. Does anyone know of a similar chip that will cycle thru > 16 different outputs?
Daisy-chain and loop-back two 8-bit shift registers.
On May 3, 7:44=A0pm, Tom=E1s =D3 h=C9ilidhe <t...@lavabit.com> wrote:
> Let's say we have an 8-Bit shift register. We reset it so that its > outputs are as follows: >
<SNIP>>
> Then again I could always just use two of these chips, but I just > thought I'd check to see whether there was a more suitable chip out > there.
Could you outline the purpose of your project? At this stage (based on your other posts too) you appear to have a desired to build a project that drives as many LEDs as possible using only 1 processor pin. In real life I have seldom found such constraints - it is often cheaper & quicker to use a bigger part. I worked on a hobby project that drove 36 LEDs and had 3 input switches all running of an 18 pin PIC. The interface components were 3 pullups, and 3 current limit resitors.
On May 3, 7:29=A0pm, Hans-Bernhard Br=F6ker <HBBroe...@t-online.de> wrote:
> Tom=E1s =D3 h=C9ilidhe wrote: > > I'm looking for something that will do the same job with just one pin > > (i.e. a pin to clock it). > > Look, we told you last time that this was a daft idea. =A0What do you > think asking the same question again will change?
My project's already finished and it works perfectly. In fact I'll record a video of it, stick it on youtube, and post a link here. I thinking of ways to improve the project though now.
On May 3, 11:37 am, Rocky <RobertG...@gmail.com> wrote:
> On May 3, 7:44 pm, Tom=E1s =D3 h=C9ilidhe <t...@lavabit.com> wrote: > > > Let's say we have an 8-Bit shift register. We reset it so that its > > outputs are as follows: > > <SNIP>> > > Then again I could always just use two of these chips, but I just > > thought I'd check to see whether there was a more suitable chip out > > there. > > Could you outline the purpose of your project?
He already said it's for college project. Homework by usenet.
> > At this stage (based on your other posts too) you appear to have a > desired to build a project that drives as many LEDs as possible using > only 1 processor pin. In real life I have seldom found such > constraints - it is often cheaper & quicker to use a bigger part. > > I worked on a hobby project that drove 36 LEDs and had 3 input > switches all running of an 18 pin PIC. The interface components were 3 > pullups, and 3 current limit resitors.
Course assignments seldom make sense in real life.
Tom&#4294967295;s &#4294967295; h&#4294967295;ilidhe wrote:


> The only problem though is that I need a chip that will count to 16 > instead of 10. Does anyone know of a similar chip that will cycle thru > 16 different outputs? > > Then again I could always just use two of these chips, but I just > thought I'd check to see whether there was a more suitable chip out > there.
Just use two of them. They date from DIP package days, and 16 OP would not fit into a small DIP (DIP24). Or, you can put this into a CPLD. - then you could move to a one-wire PWM protocol if you wanted to get much smarter... -jg
On May 3, 4:00 pm, Jim Granville <no.s...@designtools.maps.co.nz>
wrote:
> Tom=E1s =D3 h=C9ilidhe wrote: > > The only problem though is that I need a chip that will count to 16 > > instead of 10. Does anyone know of a similar chip that will cycle thru > > 16 different outputs? > > > Then again I could always just use two of these chips, but I just > > thought I'd check to see whether there was a more suitable chip out > > there. > > Just use two of them. They date from DIP package days, and 16 OP > would not fit into a small DIP (DIP24). > Or, you can put this into a CPLD. - then you could move to a > one-wire PWM protocol if you wanted to get much smarter... > > -jg
But why use a CPLD along with a CPU when you can just use two CPUs? One input and 16 outputs, heck that can be done in a CPU in a 24 pin package. The program is about as simple as writing the HDL for the counter. If you already have an MCU in your system this is like falling off a log. Only a masochist would want to add obsolete 4000 series CMOS parts, RC timing or PLDs to such an otherwise simple and elegant design.
rickman wrote:

> On May 3, 4:00 pm, Jim Granville <no.s...@designtools.maps.co.nz> > wrote: > >>Tom&#4294967295;s &#4294967295; h&#4294967295;ilidhe wrote: >> >>>The only problem though is that I need a chip that will count to 16 >>>instead of 10. Does anyone know of a similar chip that will cycle thru >>>16 different outputs? >> >>>Then again I could always just use two of these chips, but I just >>>thought I'd check to see whether there was a more suitable chip out >>>there. >> >>Just use two of them. They date from DIP package days, and 16 OP >>would not fit into a small DIP (DIP24). >>Or, you can put this into a CPLD. - then you could move to a >>one-wire PWM protocol if you wanted to get much smarter... >> >>-jg > > > But why use a CPLD along with a CPU when you can just use two CPUs? > One input and 16 outputs, heck that can be done in a CPU in a 24 pin > package. The program is about as simple as writing the HDL for the > counter. If you already have an MCU in your system this is like > falling off a log. Only a masochist would want to add obsolete 4000 > series CMOS parts, RC timing or PLDs to such an otherwise simple and > elegant design.
This was a project, so normal commercial yardsticks do not apply. However, even when they DO, do not dismiss the 4017 so quickly. It has VERY low static power, cannot crash, and costs 15c for 10 op pins. Show me a Micro that even comes close! If that is ALL you need, using a Micro actually makes little sense. CPLDs also compete reasonably well in a cents/IO function, with a uC, and if you need highish drive current, they can outclass a uC, as most uC have single GND pins, vs commonly 4+ on a CPLD. ie a Micro is not always the best solution. We still use PLD and 4000 cmos in active designs, because they are the best parts for the task. (and uC too, of course!) -jg
On May 3, 10:55 pm, Jim Granville <no.s...@designtools.maps.co.nz>
wrote:
> rickman wrote: > > On May 3, 4:00 pm, Jim Granville <no.s...@designtools.maps.co.nz> > > wrote: > > >>Tom=E1s =D3 h=C9ilidhe wrote: > > >>>The only problem though is that I need a chip that will count to 16 > >>>instead of 10. Does anyone know of a similar chip that will cycle thru > >>>16 different outputs? > > >>>Then again I could always just use two of these chips, but I just > >>>thought I'd check to see whether there was a more suitable chip out > >>>there. > > >>Just use two of them. They date from DIP package days, and 16 OP > >>would not fit into a small DIP (DIP24). > >>Or, you can put this into a CPLD. - then you could move to a > >>one-wire PWM protocol if you wanted to get much smarter... > > >>-jg > > > But why use a CPLD along with a CPU when you can just use two CPUs? > > One input and 16 outputs, heck that can be done in a CPU in a 24 pin > > package. The program is about as simple as writing the HDL for the > > counter. If you already have an MCU in your system this is like > > falling off a log. Only a masochist would want to add obsolete 4000 > > series CMOS parts, RC timing or PLDs to such an otherwise simple and > > elegant design. > > This was a project, so normal commercial yardsticks do not apply. > > However, even when they DO, do not dismiss the 4017 so quickly. > > It has VERY low static power, cannot crash, and costs 15c for 10 op > pins. Show me a Micro that even comes close! > > If that is ALL you need, using a Micro actually makes little sense. > > CPLDs also compete reasonably well in a cents/IO function, with a uC, > and if you need highish drive current, they can outclass a uC, as most > uC have single GND pins, vs commonly 4+ on a CPLD. > > ie a Micro is not always the best solution. > > We still use PLD and 4000 cmos in active designs, because they are > the best parts for the task. (and uC too, of course!)
Let's face it, if this were a commercial project, you would just pick a larger MCU and be done with it. Of course if you are making a million of them a larger CPU is likely more expensive than a 4000 series chip. But most of my projects are space constrained and adding a couple of chips would be way down the list of options. Everything depends on your constraints.
rickman wrote:

> Let's face it, if this were a commercial project, you would just pick > a larger MCU and be done with it.
I wouldn't, and precisely _because_ it's a commercial project. Hobbyist or one-off in-house projects often have virtually no cost constraints. It's the commercial ones that do.
> Of course if you are making a > million of them a larger CPU is likely more expensive than a 4000 > series chip.
Exactly. And below a million pieces, some might not consider it a commercial project ;-)