JochiSt / OpenFlowMeter

Measuring Flow
GNU General Public License v3.0
6 stars 0 forks source link

Current Calibration v2 #22

Closed JochiSt closed 1 year ago

JochiSt commented 1 year ago

Channel 0

High Gain

20230104_CH0_HighGainFit

The current fits the measured current with the multimeter quite well (99.5%). There seems to be an issue with the low gain channel in the low current regime. (see the gray / black oscillations)

The residuals also look promising:

20230104_CH0_HighGainFit_residuals

JochiSt commented 1 year ago

DAC steps

CHANNEL 0

20230104_CH0_dac_step_calibration

The dac step fit for version 2 is the same than the one for version 1. There is 1 LSB difference.

CHANNEL 1

20230104_CH1_dac_step_calibration

JochiSt commented 1 year ago

Channel 1

High gain

In this channel the wiggles of the low gain are not observable. I suspect an issue with the gain switching amplifier in channel 0.

20230104_CH1_HighGainFit

20230104_CH1_HighGainFit_residuals

JochiSt commented 1 year ago

To exclude the problems with the gain switching amplifier, I reduced the resistors by a factor of 10, so that R47 = 47k and R51 = 5k6. Same for R46 = 33k and R50 = 5k6.

JochiSt commented 1 year ago

By using the lower resistors, this effect is gone. There is now a gain mismatch, but this might be wrong population of the resistors. If I get this channel working, I'll update the other one as well.

20230105_CH0_HighGainFit

JochiSt commented 1 year ago

The gain mismatch was a swap of the population, I did not mirror the board. Thus the U gain and I gain has been mixed up.

20230105_CH0_HighGainFit_2

20230105_CH0_HighGainFit_residuals

JochiSt commented 1 year ago

CH0 voltage and current bias

It seems, that there is a slight voltage and current bias in the low gain with respect to the high gain. (see attached image)

20230105_CH0_IUbias

This can be calibrated out (not working 100% in the image above) and by this the measured resistances match much better.

JochiSt commented 1 year ago

The offsets have been implemented in b254d9760f564fae4d8d9865fb7bdbdeee8afc4e. The default values are somewhat arbitrary, they have to be tuned to match the exact board.

JochiSt commented 1 year ago

Offsets

after tuning the offsets, the resistance at the saturation border of the high gain is rather smooth between HG and LG.

CH0

calibration_20230105_190011_CH0_10_Rmatching_final

CH1

calibration_20230106_091749_CH1_10_Rmatching_final

JochiSt commented 1 year ago

The PID starts working better and better. Also the gain switching is working.

20230108_PID_test_working

The usage of different gains for voltage and current needs some further investigations.

JochiSt commented 1 year ago

Since v3 will have a offset voltage included to get a higher resolution at higher currents, I close this issue here and in case it is needed, I'll open a new one.