This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Starterware/TMDSIDK437X: Is there any library/source code available for ADC1?

Part Number: TMDSIDK437X

Tool/software: Starterware

Hi,

I use idkam437x with ccs 6.1.2 and sdk 2.1.1.2.

Based on the examples presented in sdk Starterware, I have written some code utilizing the adc0 module. However, there seems to be neither an example nor the libraries to support the adc1 module.

If I want to use the ADC1, should I use the functions declared in tsc_adc_ss.h or there is no support for this module in Starterware?

Thanks

JJ

  • JJ,

    The magnetic card reader function is not supported on the AM437x product family. ADC1 should only be used as a general-purpose ADC when using an AM437x device. So I assume you use ADC1 just as general purpose.

    The ADC driver in tsc_adc_ss.h and tsc_adc_ss.c are written with adc_base + offset style. You can get the ADC1 base address from adc_base = CHIPDBBaseAddress(CHIPDB_MOD_ID_ADC1, 0);

    The ADC register layout are almost the same by looking at Table 11-4 and Table 12-6 in AM437x TRM, except that ADC0 has extra registers at offset 0x34 and 0x50.

    So, you can use the same API for ADC1 with the correct base address.

    Regards, Eric
  • Hi Eric,

    Thanks for your detailed answer - that's exactly what I wanted to know.

    Regards,

    JJ