counter for counting magnetic microswich press


Results 1 to 5 of 5

Threaded View

  1. #3
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Carefull when you use reserved word... COUNT is also a PBP statement. You should change it to something else

    Now JUST FOR FUN, and as your current hardware is setuped to use it, try this one which use TMR0
    Code:
            ADCON1 = 7
            pCount    VAR BYTE
            OldpCount VAR BYTE
            CLEAR
            TMR0 = 0
            OLDPCOUNT = 1
    Start:
            pCount = TMR0
            IF pCount != OldpCount then
                LCDOUT $FE,$C0, #pCount
                OldpCount = pCount
                ENDIF
            GOTO Start
    Last edited by mister_e; - 17th June 2007 at 22:22.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

Similar Threads

  1. Conway's Game Of Life
    By wellyboot in forum mel PIC BASIC Pro
    Replies: 45
    Last Post: - 28th May 2020, 06:14
  2. 20 Digit Virtual LED Counter
    By T.Jackson in forum Code Examples
    Replies: 9
    Last Post: - 19th November 2007, 05:02
  3. Replies: 14
    Last Post: - 26th September 2007, 05:41
  4. How to set TMRO & TMR3 as Counter?.
    By NatureTech in forum mel PIC BASIC Pro
    Replies: 21
    Last Post: - 18th May 2007, 08:52
  5. Microcontroller with 2 way paging application problem
    By oneohthree in forum mel PIC BASIC Pro
    Replies: 30
    Last Post: - 20th April 2007, 17:27

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