Emonlib with 333mV CT

Hey all. I’ve been building a little energy monitor for a couple applications I have and I was using the emonlib with a 333mV 100A CT. I can see a reading on my photon however it never actually zeros when the CT is not even around a wire.
Setup I built is pretty simple, 10k ohm voltage divider, I feed the divider with 3.3V from the device and wire in the CT as per the directions. The idea being that I’m just adding DC voltage to the AC output of the CT and it should swing between 1.65 +/- 333mV (max). I’m also using a 100uF capacitor as that is all I have laying around. I’ve seen other circuits built with 10 or 47uF, would that make a difference?

Anyway, if anyone is familiar with this library and has done this kind of thing before I’d really appreciate some input.

Best as I can make out from your description, the ADC should read mid-scale when there is no AC input since you have biased the DC with a pair of 10k resistors in a voltage divider.

Is there a setting in the library for the mid-scale value (2047-8 on a Photon)? Arduino’s would need a different value.

1 Like

Thanks for the reply I’ll look around in the library