Quantcast
Channel: Data converters
Viewing all articles
Browse latest Browse all 27683

Forum Post: RE: ADS1013: The acquired value is fixed to the maximum value.

$
0
0
Yukie-san, Thank you for the pdf. However, I think the communication is a little off. Let me show you what I see: The A signal looks like a write to the configuration register. This looks correct, but the data rate is off. The master writes 10010000, there is an ACK from the device. Then the master writes 00000001 to indicate a write to the configuration register (then ACK from device). The next byte is 10000101. This starts a new conversion, with inputs AIN0-AIN, PGA=±2.048V, in single shot mode (then another ACK). Then the master sends 10000000 (with an ACK and a STOP). This sets the data rate to 1600SPS. Then there are a few comparator settings before finishing the write with an ACK and stop. This looks like a correct communication with the device similar to Figure 16 of the datasheet. Note, after this communication, data will not be ready until after the conversion completes. If the device is in single-shot conversion mode, here is the sequence of events: After the conversion start, it takes about 20us to start the ADC. Then you would wait for the conversion to complete. This would nominally take 1/(data rate) to complete, with ±10% from internal oscillator variation. For instance, if the data rate is 128SPS, you would wait 20us+(1/128)*1.1 = 0.708ms. After this time period, you can read the device and the data should be ready. After this, it looks like B is a read from the device, and the device responds with the configuration register. That's not how the read from the device works, the master should write to the device, and write the register that you want to read from. See figure 15 in the datasheet. Signal C then looks like a write to the device of 00 (which is the data register), then it looks like a write of the configuration register. But this I don't think this is set up correctly. Signal D looks like a read, but it just gives 00s, I also don't think this is set up correctly. Instead of what you have shown, the following is what I think should happen: 1. Signal A is correct. Send a write to the device that gives the configuration register. Send 10010000A00000001A10000101A1000000A This will also start the conversion in single-shot mode. 2. Then wait for the conversion to complete. If the data rate is 1600SPS, this should be 0.708ms. 3. Read the device using the format of Figure 15. Note that a read of the device starts with a write to show which register you read from. This becomes address write, 00, address read, read data (2 bytes). Send 10010000A00000000A10010001AXXXXXXXXAXXXXXXXXA The Xs are all data from the device. This is a 5 byte transaction total. After that, start a new conversion with 1 again (or you can change the configuration register and have a different conversion). Read through my explanation and see if this makes sense. I think if you try this, is should work correctly. Joseph Wu

Viewing all articles
Browse latest Browse all 27683

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>