Skip to main content
Pradnya
Associate II
January 27, 2020
Question

How to work on ADC0 and ADC1 in the same code ? ( SPC560P-DISP Board)

  • January 27, 2020
  • 2 replies
  • 1148 views

Hi,

I am able to work on ADC0 and ADC1 in separate code ( LED11 flashes properly as per the analog signal). But when I initialise ADC0 and ADC1 in the same code, LED11 AND LED12 flashes as per the analog signal at ADC1.

(I am using ADC sample code with addition of ADC0 , no error program compiled properly)

Please help me to resolve the issue.

Thanks and Regards,

Pradnya

    This topic has been closed for replies.

    2 replies

    Erwan YVIN
    ST Employee
    January 28, 2020

    Hello Pradnya ,

    Did you enable the Pin settings ADC0 and ADC1 by the pinmap wizard ?

    Best Regards

    Erwan

    Pradnya
    PradnyaAuthor
    Associate II
    January 28, 2020

    Hello Ervan,

    With SPC560P-DISP BOARD, I initialised ADC0 ( Analog input from Pot R58 available on board) , checked with LED11 flashing and then in same code I initialised ADC1 ( Analog input from Pot R57 available on board) , checked with LED12 flashing.

    But when I changed analog input at ADC1 (POT R57), flashing rate of LED11 also get change along with LED12.

    Flashing rate of LED11 is not expected to change since it is assigned to ADC0.

    Please guide,

    Thanks and Regards,

    Pradnya