Post Go back to editing

Mux control through Adcum363

Hello.

It is connected to Aducm363 I/O port for 16:1 Mux Selection.

There are 16 temperature sensors connected to the MUX.

Note. ADG1607 16:1 Mux product was used.

I want to obtain data from the first temperature sensor connected to the MUX through ADC, and then select and obtain the second temperature sensor connected to the MUX and obtain 16 sensors in sequence.

Any answers would be appreciated.

Watch out for corona.

  • Hi,

    Below is a code to obtain temperature data from 16 sensors in sequence:-

    pADI_ADC0->MDE = 0x00000003; // Allow writing to the calibration registers by placing ADC in idle mode

    pADI_ADC0->MSKI = 0x5; // Enable ADC0 /rdy IRQ

    pADI_ADC0->CON = 0x80001; // Enable ADC0, AIN0/AIN1 input channels, Internal reference

    pADI_ADC0-> ADCCFG = 0x00; // Enable input buffers, disable ground switch

    pADI_ADC0->MDE = 0x12; // G = 2, Single conversion

    In the interrupt handler,

    uiADCSTA = pADI_ADC0->STA; // read ADC status register

    uint8 i = 0;

    if ((uiADCSTA & 0x1) == 0x1)

    {

              uiADC_Data[i] = pADI_ADC0->ADC0DAT;

               pADI_ADC0->MSKI |= 0x1;

             /*Select next output of ADG1607 MUX*/

                i++;           /*i = 0 to 15*/

    }

    Regards,

    Akila