This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to read channel 3 of ADC on LPC2119

Hi all,

I have a grasp of setting up the ADC on the LPC2119 (by Phillps NXP). However, when it comes to reading the different channels I seem to be a little lost.

Please could someone explain how you can request the data from a specific channel of the ADC? As reading the ADDR is self explanatory, but reading a specific channel is not mentioned in the datasheet or user manual.

Many thanks

Parents
  • I don't think that the manual is confusing.
    It states very clearly that you should only enable one channel in software mode.


    ADCR b7:0
    Selects which of the Ain3:0 (LPC2119/2129/2194) or Ain7:0 (LPC2292/2294) pins is (are) to
    be sampled and converted. Only bits 3:0 should be set to 1 in the 48 or 64 pin package. In
    software-controlled mode, only one of these bits should be 1.
    In hardware scan mode, any
    value containing 1 to 8 ones (1 to 4 ones in the 48 or 64 pin package) can be used. All zeroes
    is equivalent to 0x01.

    Alex

Reply
  • I don't think that the manual is confusing.
    It states very clearly that you should only enable one channel in software mode.


    ADCR b7:0
    Selects which of the Ain3:0 (LPC2119/2129/2194) or Ain7:0 (LPC2292/2294) pins is (are) to
    be sampled and converted. Only bits 3:0 should be set to 1 in the 48 or 64 pin package. In
    software-controlled mode, only one of these bits should be 1.
    In hardware scan mode, any
    value containing 1 to 8 ones (1 to 4 ones in the 48 or 64 pin package) can be used. All zeroes
    is equivalent to 0x01.

    Alex

Children