Shop OBEX P1 Docs P2 Docs Learn Events
Counting pulses (counter/accumulator) — Parallax Forums

Counting pulses (counter/accumulator)

FranklinFranklin Posts: 4,747
edited 2009-11-02 04:21 in General Discussion
I need a way to offload the job of counting the number of pulses comming from an anemometer to a chip or circuit that I can query to find how many have elapsed. I can use the main processor to do the math, all I need is a running count. 16 bits would be nice but other esolutions could work. Thanks.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen

Comments

  • ElectricAyeElectricAye Posts: 4,561
    edited 2009-11-02 01:23
    What's your main processor? a BS2 or a Propeller or what? A Propeller chip has built-in counter modules, and with a Propeller you could have one of its cogs keeping track of pulses while its other cogs do the main program processing, etc.
  • FranklinFranklin Posts: 4,747
    edited 2009-11-02 02:05
    I'm sorta looking for a standalone solution. Prop, stamp and xbee are all options for reading the info, it depends on what I come up with.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Stephen
  • ElectricAyeElectricAye Posts: 4,561
    edited 2009-11-02 02:16
    Franklin said...
    I need a way to offload the job of counting the number of pulses comming from an anemometer to a chip or circuit that I can query to find how many have elapsed. I can use the main processor to do the math, all I need is a running count. 16 bits would be nice but other esolutions could work. Thanks.

    If you use the Propeller chip, I think this would be a piece of cake. One of its built-in counter modules will do all the counting and your main program can simply look at the count values after so many tenths of a second or seconds or whatever time scale you desire. Meanwhile, the rest of the Propeller chip (it has multiple parallel processors) can run on its own, do calculations, and drive a TV display, or VGA display and/or record your data onto SD cards. You can simultaneously run a real time clock, too. In fact, you could probably very easily observe several anemometers with a single chip.
  • ElectricAyeElectricAye Posts: 4,561
    edited 2009-11-02 02:27
    For example, you might want to take a look at this:

    http://forums.parallax.com/showthread.php?p=809389
  • kwinnkwinn Posts: 8,697
    edited 2009-11-02 04:21
    I would think a prop could run a complete weather station (wind speed, direction, temperature, humidity, precipitation) with ease.
Sign In or Register to comment.