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.
Hello,
I have a DK-TM4C129X dev kit that I would like to interface via SPI to the ads1256evm-pdk performance kit. The performance kit has ADC Pro that can be used to sample the channels; however, it appears as though you can only look at a single channel at once. I'd like to look at three channels at once, so I was considering writing a SPI interface to the DK-TM4C129X dev kit to display the samples to the LCD and/or log the samples to the SD Card.
The code itself doesn't necessarily need to be TIVA 129 specific (that'd be great if it was). I'm just looking for sample code that puts the SPI bytes together that properly configures the ADS1256 to help speed up our development.
Thanks!
Hi Aaron,
There are a several examples projects for the ADS1256 scatted around E2E. Here are links to the example projects that I'm aware of:
Multiplexing the ADS1256 with the MSP430 (I created this project so I'm familiar with this code):
Another ADS1256 and MSP430 project can be found here:
ftp://ftp.ti.com/pub/data_acquisition/ADS1256_on_HPA449/ads1256evm_dist.zip
Example code using the C641x
There is also a third-party project on GitHub with example code for an Arduino, found here:
I hope that helps!
Best Regards,
Chris
Hi Aaron,
I believe I got those specific delays out of another project, but in effect all they need to do is provide for the ADS1256's t6 timing specification. Both RDATA and RREG need a short delay between the command and data bytes as shown below:
It also looks like I commented out the only place where "DELAY_RDATA()" was called in the code. I believe with the MSP430's 8-bit SPI transfers, there was a built-in delay when waiting for the single byte SPI transfer to complete. So in my case it really wasn't necessary to provide these extra delays at all, but it's still a good idea to keep a placeholder or reminder that a delay would be required on a faster processor.
Best Regards,
Chris
Hi Chris,
Thanks for the explanation.
I have a follow-up question on the code. It appears as though you're waiting for 3 pulses on the DRDY line before acquiring the sample. I'm curious if there is a need for this?
I was looking through the datasheet on page 22 table 15 and it seems for 100 SPS, that you should be able to use the reading on the first falling edge of DRDY (you wouldn't need to wait 3 unless your SPS was set to 15,000). Am I interpreting this correctly?