The d/s for the NTE952 is not clear regarding the Vref change on using adjust.
Hey Eric,
NTE data sheets are the worst. It's so annoying when I go to a store and that's all they carry. At any rate, I took your suggestion and used 2 1kΩ/1% resistors to set a 2.5V reference voltage so no NTE952 for me.
I apologize in advance for this gargantuan post but I was pretty busy yesterday and there's lots to discuss. First off, I expanded the test circuit and it is much improved. I attached the latest schematic.
The differential signal coming from the load cell can be either positive or negative depending on whether the load cell is experiencing compression or tension. Since this is a single supply circuit I have two INA118Ps in parallel. One is inverting and the other non-inverting and each one goes into its own ADC channel. The PIC retrieves both channels one at a time and after some math, figures out the applied load and the direction (i.e. push or pull). It works pretty well right now. I have the PIC talking to the MCP3204 and displaying the values on an LCD.
After hooking everything up, I adjusted the offset voltage pots (R5 and R10) so that each ADC channel output 100 counts with no applied load. I then loaded the load cell in compression with 50 pounds and adjusted the gain pot R2 until the first channel of the ADC output 4050 counts. I repeated that step in the tension direction for the second channel while adjusting the gain pot R9.
The PIC then does some math. Here is a simplified form:
force = 50*(ADC_CH0 - ADC_CH1)/(4050-100)
The PIC determines direction by looking at the sign of force.
So as I stated, it works fairly well but there are still 2 aspects of the circuit with room for improvement.
The first is signal noise. I already have the PIC doing a running average calculation of the last 5 measurements but still, without touching anything and just watching the ADC value it jumps around a lot. Sometimes as much as 20 or 30 counts in either direction. It's hard for me to tell right now the source of the noise. I'm sure my home made power supply isn't that clean. Also, the entire circuit right now is in a solderless bread board with wires going everywhere. On top of that, it's plugged into my development board so, there's probably a lot of digital switching noise in there too.
I'm sure if I follow good practices, the performance will improve after I design the board and build the circuit. I found this pretty handy application note,
AN688 - Layout Tips for 12-Bit A/D Converter Application. Also, once in the final circuit, the analog portion will be powered with a precision 5V reference. Right now it's just a 7805 powered by my bench power supply. So I know the signals will be more stable but just how much more, I have no idea.
Because I won't know until after the board is put together, I'm thinking about designing in some low pass filters. Ideally, I would have 1 filter at the input of the INA118P, 1 at the output, and 1 at the reference voltage input. That would be 3 per amplifier for a total of 6 low pass filters.
Since the offset voltage and INA118P output are already being buffered with op amps, I was thinking I could just add some resistors and capacitors and make them into unity gain low pass filters. For the input of the INA118P, I was thinking about using a dedicated low pass filter IC. After looking around a little, the
MAX7426, the
TLC04, or the
TLC1062 seem to fit the bill pretty well.
Do you have any thoughts on this approach? Do you think this is overkill?
The second area for improvement is non-linearity. At 0 and at 50 lbs, the output matches the applied load. But in between, it can be off by as much as 1.5 lbs. I'm unsure of the source of this non-linearity. The load cell data sheet states that the non-linearity is ± .02% of full scale. So that would be ± .01 lbs, not 1.5lbs. I did get the load cell on the cheap so it wouldn't surprise me is it was out of spec but that is way out of spec. I know also that the INA118P and the MCP619 output buffer can introduce some non-linearity but I'm unsure how significant their contribution is. I know that I can compensate for this in software via a transfer function, but I'd like to minimize all sources of error due to non-linearity before doing that.
Do you have any thoughts in this area? How can I minimize this error?
I think that's about it for now. Thanks again for your thoughts and ideas. They are most helpful.