Counting led blinks..


Results 1 to 40 of 93

Threaded View

  1. #2
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,624


    Did you find this post helpful? Yes | No

    Default Re: Counting led blinks..

    Hi,
    How fast does the LED blink? You're only counting for 60ms so you need to insert the coin at exactly the right time - every time - for it be consistent.
    I'd probably do this by setting up one of the PICs timers as a counter and wire the pulse signal to its input.

    EDIT: Or something like:
    Code:
    Init:
      While PortB.1 = 0 : WEND
      Count PortB.1, 60, W1
      Count = Count + 1
      'LCDOUT......
      '.....
    Goto Init

    /Henrik.
    Last edited by HenrikOlsson; - 23rd September 2011 at 19:21.

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts