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.

ADS1147: CC2640R2F

Part Number: ADS1147

"Send 16 SCLKs to read out conversion data on DOUT/DRDY;" I took this part in ADS1147 datasheet page number 65 pseudo code. Is the SCLK signal sent to the DIN pin using SPI? Or SCLK pin of ADS1147 normally? This is not clear to me. After it goes successfully, how do I identify it? Is the output signal given for it?. I crated the clock signal show below code.

ADS1147_Code.rar

Navodvishwa/ADS1147 (github.com) code uploaded in this link. code has include in Spimaster.c file. Can explain me mistakes and omissions. I have used the CC2640R2 microcontroller.

  • Hi Navod Rajapaki,

    I'm not really sure what is being asked here, so you might need to provide additional clarification to your questions.

    The SCLK signal is provided to the ADC's SCLK pin from the controller. SCLK is the Serial Clock, and as its name implies this is the clock that the serial communication uses for timing. DIN is the Data Input pin, so your controller sends commands (Read reg, write reg, read data, etc.) to this pin to be able to control the ADC.

    I would strongly encourage you to completely read the ADS1147 datasheet before posting additional questions, many of the answers are already included in this document

    We typically do not review third-party code. There is example code for the ADS114x (16-bit) and ADS124x (24-bit) devices on TI.com: https://www.ti.com/lit/zip/sbac144

    -Bryan

  • how to send 16 SCLK for ADS1147?.pluse duration is 366ns.i didn't understand your reply. I used CC2640R2 board.

  • Hi Navod Rajapaki,

    SCLK is signal that is sent by the controller, so the first thing you need to do is set up the SPI peripheral in the controller (CC2640R2).

    There is a separate support forum for MCUs if you need help with the CC2640R2: https://e2e.ti.com/support/microcontrollers/arm-based-microcontrollers-group/arm-based-microcontrollers/f/arm-based-microcontrollers-forum

    -Bryan

  • Hi Bryan Lizon86,

    I already set up the SPI peripheral in the controller and send 16 SCLK using SPI but I haven't come expected result. Following code is used.

    void SCLK_16_command()
    {

    /* Call driver init functions */
    SPI_init();

    SPI_Handle handle;
    SPI_Params params;
    SPI_Transaction transaction;
    uint32_t txBuf[] = {0b010101010101010101010101010101010}; // 16 SCLKs


    // Init SPI and specify non-default parameters
    SPI_Params_init(&params);
    params.bitRate = 2700000;
    params.frameFormat = SPI_POL0_PHA1;
    params.mode = SPI_MASTER;

    // Configure the transaction
    transaction.count = sizeof(txBuf);
    transaction.txBuf = txBuf;
    transaction.rxBuf = NULL;

    // Open the SPI and perform the transfer
    handle = SPI_open(CC2640R2_LAUNCHXL_SPI1, &params);

    SPI_transfer(handle, &transaction);

    SPI_close(handle);


    }

    //checking whether DRDY(MISO pin as Data ready connected) is high


    while(DRDY==1){

    Task_sleep (0.01 * (1000 / Clock_tickPeriod));
    RDATA_command();
    SCLK_16_command();
    usleep(1.7);

    }

    The below picture indicated Clock signal.

    Why its not continuing the 32 bit clock cycle either giving delay after a 8 bits.i want to clean that delay and give a 32 bit continuously.

    please answer to my question directly either sending links. 

  • Hi Navod Rajapakisha,

    Do you have a logic analyzer? It would be helpful to see all the signals you are sending to and receiving from the ADC. This will help us understand if there are any issues with the communication.

    Please include: DOUT, DIN, DRDY, RESET, SCLK, and START pins

    -Bryan