Different Voltage by LJ Control Panel and getAin() | LabJack

Different Voltage by LJ Control Panel and getAin()

3 posts / 0 new
Last post
Andy_N.'s picture
Different Voltage by LJ Control Panel and getAin()


today i started working with the UE9 PRO and Python for the first time and i was happy, that i was able to manage the connection via ethernet and read the analog inputs.

But comparing the values wich i get in python and the ones from the LJ Control Panel, showes that some voltes are missing. I didn´t change any settings from LabJack. Neither in control panel nor i python. I checked my supply with a multimeter and it seems that the LJ Control Panel value is correct. One detail i recognized: when i changed the voltage from 5 V to 2 V, in Python i miss ~50 mV respectively ~20 mV. Maybe it helps you to find my mistake...

Hopefully in the following Pictures you get every information you need:

I also read somthing about the gain for the binaryToCalibratedAnalogVoltage. But i´m not sure what to change. I tried different falues for the BipGain, but no effect.

Can you help me?!

Thank you for your effort.

LabJack Support
LabJack Support's picture
It looks like you are both

It looks like you are both opening and reading an analog input in one line of code, so the reading isn't calibrated. Use the ue9.UE9 constructor to open the device and get a UE9 object, read the calibration which gets stored into the object and then read the analog input. Something like this in code (a snippet):

myUE9 = ue9.UE9(ethernet=True, ipAddress="")

# Get 50 readings, 1 second delay between.
for i in range(50):
    voltage = myUE9.getAIN(1)

Compare the Python calibrated readings with LJControlPanel readings to confirm they are about the same.

Andy_N.'s picture
Hi there,

Hi there,

thanks for your help. That was the Problem!

Now it ´s running.