Shop OBEX P1 Docs P2 Docs Learn Events
Pulse counter — Parallax Forums

Pulse counter

haimhaim Posts: 25
edited 2007-09-14 18:03 in Propeller 1
Hi,

Any code sample for a pulse counter and the code as·"lookdown,branch" in Stamp? Thanks.

Hai·

Comments

  • Ken PetersonKen Peterson Posts: 806
    edited 2007-09-14 01:46
    Hai,

    If you are looking for help with the Stamp, this forum is for the Propeller so you should post to a Stamp forum in stead.· If you are looking to set up a pulse counter with the Propeller, that is a very simple matter as the built-in counters have that capability.· It is documented in the Propeller manual and in a Counter app-note in the Propeller Download section.

    Ken

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔


    The more I know, the more I know I don't know.· Is this what they call Wisdom?
  • haimhaim Posts: 25
    edited 2007-09-14 17:50
    Thanks, Ken.

    I know the "lookdown and branch" in stamp. What I mean is the same function but in propeller. Probably it is in the manual too. I am going to look into that. Thanks again.



    Hai
  • edited 2007-09-14 18:03
    There's an example in the Propeller Education Kit Counters lab that explains how to use counter modules to count rising and falling edges. Each of the Propeller chip's cogs has two counter modules. The nice thing about using counter modules to count transitions is that your cog's code can move on to other tasks, and check back later to find the value the counter module accumulated.

    The·Counter Modules and Circuit·Applications lab is available for download here: http://forums.parallax.com/showthread.php?p=617192

    See pages 32 - 35.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Andy Lindsay

    Education Department
    Parallax, Inc.
Sign In or Register to comment.