16F1828 HPWM and ADC


Results 1 to 20 of 20

Threaded View

  1. #12
    Join Date
    May 2013
    Location
    australia
    Posts
    2,644


    Did you find this post helpful? Yes | No

    Default Re: 16F1828 HPWM and ADC

    DEFINE ADC_BITS 8
    DEFINE ADC_CLOCK 3
    DEFINE ADC_SAMPLEUS 100

    ADCON0 = %00000000
    ADCON1 = %00000011
    ADCON1 = %00000011 ; this line just destroyed all your defines

    ADCON1 = ADCON1 | %00000011 ; will set bits 0 and 1 without wrecking the others
    Last edited by richard; - 17th November 2015 at 09:52. Reason: wrong line

Similar Threads

  1. ADC values above 4095 for 12 bit ADC
    By longpole001 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 1st February 2015, 22:24
  2. ADC problem on 18F46K22 device using all 28 ADC pins
    By JimAvanti in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 23rd February 2012, 20:22
  3. Replies: 3
    Last Post: - 23rd October 2011, 12:53
  4. Newbie HPWM / ADC question
    By Johan in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 25th June 2007, 12:52
  5. HPWM of the port of two HPWM
    By ja2rqk in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 25th April 2007, 15:05

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