Stable ADC readings


Results 1 to 40 of 91

Threaded View

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


    Did you find this post helpful? Yes | No

    Default Re: Stable ADC readings

    Salut et Bienvenue sur le forum

    I haven't check the whole thing in deep but I think you should modify the boucle_led section to
    Code:
    boucle_led:
            iled = 0
            while iled < 5
                    if iled = 1 or 3 or 5 then 
                            high blink1
                            low blink2     
                            endif
                            
                    if iled = 0 or 2 or 4 then 
                            low blink1
                            high blink2
                            endif
                    iled = iled + 1
                    pause 1000
                    wend
            goto val_leds
    Probably it will solve your problem though... let me know the PIC you're using and your PBP version.

    EDIT: Your code have 2 compilation error
    1) no mainloop label
    2) adcon1: the way you have written it, it's value should start with a % instead of a $
    Last edited by mister_e; - 24th August 2011 at 19:07.
    Steve

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

Members who have read this thread : 1

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