Part Number: ADS131M06
Other Parts Discussed in Thread: ADS131M08EVM, ADS131M08
Tool/software:
We use a lot of TI products, especially mmwave and ADS112U04IPW . We are using the ADS131M06 with the older MSP430GF4619 which we have a lot of experience with using SPI, SCI and many other features. We are stumped trying to simply read the 6 Analog ports from the ADS131m06. Configuration registers are straight forward.
RREG (101a aaaa annn nnnn) 1010 0000 0000 0110 //READ starting from register 0 7-1 bytes
Assuming default start up gain=1, 24bit data, and other default conditions so it auto converts.
void ADS131_readConversion() { //read all 6 channels into array
IO_LOW(P9,BIT7); // Chip Select ADS13
for (int ch = 0; ch < 6; ch++) { // Read 6 ADC channels
command = 0XA | (ch & 0x07); //THIS DOES NOT LOOK CORRECT?? RREG (101a aaaa annn nnnn) 1010 0000 0000 0110 //READ starting from register 0 7-1 bytes
while (!(IFG2 & UCB0TXIFG)); // Wait for TX buffer ready
UCB0TXBUF = command; // Transmit the command byte
while (!(IFG2 & UCB0RXIFG));ch = UCB0RXBUF; // Wait for transmission and clear RX flag with a dummy read
unsigned int high = SPI_transfer(0x0000); //read lo, mid, hi byte
unsigned int mid = SPI_transfer(0x0000);
unsigned int low = SPI_transfer(0x0000);
adc_data[ch] = ((unsigned long)high << 16) | ((unsigned long)mid << 8) | low;
} // Read 6 ADC channels
IO_HIGH(P9,BIT7); ; // Deselect ADS131
}
We have read countless examples of the code and the user manual but it is not clear
WHERE ARE REGISTERS FOR THE 24BIT DATA?
ARE ANY OTHER STARTUP COMMANDS NEEDED?
DO WE NEED TO SEND THE READ COMMAND AND ADDRESS EACH A/D CHANNEL 0XA | (ch & 0x07);
PLEASE HELP WITH THE CODE ABOVE.
Many thanks, Peter





