EmonTx & EmonPi Voltage Reference

Hello,

I’m trying to get inspiration from emonTx or emonPi on how to build my own hardware and I got confused by the usage of MCP1501. On emonPi, the schematic suggest a MSP1501-10 (1.024V) and on emonTx the BOM refer to MCP1501-18 (1.8V). I also see a voltage divider at the output of the MCP1501 (10K + 10.010k) which for the MCP1501-10 would produce around 511mv. When looking at the front end, I see a 180k/33k voltage shift which, out of 3.3V will produce 511mv as well. CT Sensor will generare up to 333mv so in my undertsanding of things, the ADC ref voltage should be right above 511+333mv. That is compatible with the MCP1501-18 which once divided by roughly two will be 900mv but not witth the MCP1501-10. Now why don’t we just use a MCP1501-10 without a divider which would set the ref voltage to 1.024V ? What is it that I get wrong ?

Welcome, Valery, to the OEM forum.

Unfortunately, almost everything!

We use the 1.024 V internal reference for measuring the voltage from the 0.333 V rms output from the current transformers, and a similar voltage from the emonVs, and this gives a sensible amount of headroom, without losing resolution. Clearly, with the maximum nominal measurable voltage being 1.024 V, but assuming it’s at the bottom end of the tolerance range (“typically” ±4%, with no defined limit), which would be 0.9830 V, it’s not going to be possible to compare and measure a 1.024 V “standard”. You need to be able to guarantee the AVR-DB’s internal reference is well above the nominal 1.024 V. This is why the 1.8 V MCP1501 is used, divided down to 0.900 V using ± 0.1% tolerance resistors.
Note: When designing your cicuit around the MCP1501, do not follow the emonTx4 schematic - the 2.2 µF with 10 Ω in series can cause gross instability and the output becomes unusable. Instead, follow the data sheet examples closely. I believe before long, emonTx4’s from The Shop will have the capacitor removed. See emonVS Power Supply reporting Strange voltages - #27 by Robert.Wall
Hopefully, the next manufacturing batch will implement a better solution.

Thank you very much for taking the time to educate me a bit.
I was using the emonPi2 as reference, just checked the emonTx because on the schematic of emonPi2, the MCP1501-10 (1.024V) is referenced instead of the MCP1501-18 (1.8V) on the emonTx.
I think I understand that you calibrate the internal ref voltage of 1024mv using the exernal ref of 899.55mv (why the 10 Ohm serie resitor btw ?) but then why not just using an external refe voltage that we trust ?
Sorry if I sounds even more confused than before :wink:

I only wish I knew. It’s certainly part of the instability problem. I was only involved at a distance with the original design, so even if I knew the details of why it’s been done the way it is (and I’m not sure that I ever knew), I can’t remember enough about it because I was working full-time to get the software into a workable state. It would probably take days going through the correspondence with the designers to find anything, and I don’t think I can afford the time.