I got a LJTick-InAmp but just can't get any meaningful readings out of it.
Hardware is U3B (v1.21), firmware 1.54, running under Ubuntu 16.04 using Python3 with LJPython 2.0.4. Generally, all works well reading/setting analog and digital.
I connected the LJTick-InAmp to the FIO6/7 port. Reading with LJdevice.getAIN(6, longSettle=True), and 7, resp.
With all INA+/- and INB+/- left open, and all switches Off, I read 2.458/2.458, with switch 5 On, I read 0.401/0.395, resp., with switch 6 On, I read 1.250/1.244.
So there is some response. Continuing with switch 5 = On, as the only On switch:
Connecting a 1.5V AAA batt between INA+/-, or INB+/- does not result in any change of the reading; it stays at the ~0.4V.
Flipping switches 2 and 8 to On results in absolutely no changes.
Am I missing something, or is the LJTick-InAmp defect?
Start on this page for some basic tests and troubleshooting:
https://labjack.com/support/datasheets/accessories/ljtick-inamp/appendix-e
Based on your description of your battery test you have the issue "Signals Not Referred to GND". You need to add a jumper from IN- to GND.
Thanks for the helpful link! Good to see that I am not the only one to struggle with it, but I find this reference to GND is not easy to grasp and hope you can give some further help.
I repeated the "Testing Basic Operation" and all come out as it should. What I want to achieve is this:
Measure the current going into a microprocessor (ESP32). Power comes from a single Li "3.7V" battery via a BuckBoost chip to generate the 3.3V, which feeds directly into the processor. In this 3.3V line I planned to put a 0.1 Ohm shunt and measure the voltage drop over the shunt. Given a current between 25 ... 250mA, a voltage drop of 2.5 ... 25 mV is expected. A 51x amplification should thus be ok?
I want to put the shunt into the plus-line of the 3.3V power. Since this would put the common-mode voltage inside -0.3 to +3.5 volts, this would be ok. Or must I put the shunt into the minus-line?
Now the grounding issue: I understand a 100kOhm from either the battery-side or the processor-side to the GND of the U3 would be ok? Or must it come from either the IN- or IN+ side of the LJTick-InAmp? And if only one side works, why?
The LJTick-InAmp has differential inputs, which makes sense since by definitation an instrumentation amp is differential in and single-ended out. Differential inputs are pretty complicated and a very common source of mistakes and confusion. In the case of your battery test, the following section has more explanation on why that it is not valid:
http://labjack.com/support/app-notes/differential-analog-inputs#differen...
For measuring current, the first choice is often something isolated like a Hall Effect sensor. If using a resistive shunt to measure current, the first choice is to use a low side shunt, which means you put the shunt between your load and ground, such that one side of the shunt is connected to ground and you can now take single-ended readings.
http://labjack.com/support/app-notes/measuring-current#ShuntOther
If you can't do low side, then you do a high side measurement which is what you are describing.
First you need a common reference. The most common is to connect ground/common/0 of your circuit to U3-GND.
That means the voltage on the + side of the shunt will be 3.3 volts versus GND. The voltage on the - side of the shunt will be just slightly less, so also about 3.3 volts versus GND. First, you check whether you are exceeding the simple limits on the max voltage that can applied to any signal input terminal. From "Specifications", the upper limit is 3.5 if your VS is 5.0 volts, so you are okay here, but if your VS is low you are borderline:
https://labjack.com/support/datasheets/accessories/ljtick-inamp
Finally, you have to look at the signal range information in Appendix A to see if your setup is valid:
https://labjack.com/support/datasheets/accessories/ljtick-inamp/appendix-a
You have a Vcm of 3.3V. Table A1.1 does not show that Vcm, but looking at the Vcm=2.5V section at Gain=51 it shows a max input of 41 mV, so sounds good for you. To properly check, though, you need to use the calculator linked at the beginning of Appendix A. Indeed with your values it does seem fine:
https://tools.analog.com/en/diamond/#difL=0&difR=0.025&difSl=0&gain=51&l...
After some more struggling, I finally get proper results!
What helped me most was the Analog Devices Diamond Plot tool. This is also where I learned that I have to subtract the offset (0.4V in my case) from the result. Perhaps I missed that, but I think I have not seen it mentioned on your pages? Helps a lot to newbies like me to state this very explicitely!
Many thanks!
Glad you got it working.
Yes, the equation for the output voltage is:
Vout = (Vin * Gain) + Voffset
I just went and added a few more mentions of this to the LJTIA datasheet.