For reasons I won't bore you with, I'm interested in building a cheap, simple data logger to monitor mains voltage, ideally two channels (live to earth and neutral to earth). In the dim and distant past I have designed and built such things more or less from scratch, but surely someone has already done this.
I havn't used either Arduino or Pi before, but I assume one or other would be the obvious starting point.
However ATM google isn't giving me a strong lead. Thoughts?
I'm trying to see if there are overvoltage transients on a farm site, and/or what the neutral is doing. Slow, rather than fast transients. I recognise that the arduino analogue inputs are multiplexed.
So, I want to collect data for a week or so, then pop it into Excel to see if anything is going on.
Would you go for Arduino rather than adding an ADC to a Pi?
I was just thinking, if I were trying to do this, I'd be needing to measure live to neutral on a small load, and the resistance of the earth to neutral or maybe anything that is being generated between them. anything else will be seen by the other measurement. However its important to run a load realistically during the times of monitoring and also switching any loads that could be connected to see how it responds. I've measured lots of spikes on mains when very little is actually running, but when things are running particularly resistive loads like heaters or cookers, the spikes are fewer, making me think much of it is just generated by some other reactive loads switching. Not able to do this now of course, but look on a scope at unfiltered and unloaded mains and its a wonder that it works!
Funny, I've just built some hardware to do this on a Pi for a presentation and demo I'm doing later this month. However, the object was to demonstrate using an ADC on a Pi rather than specifically to measure the mains voltage, although I thought it might be fun to record mains voltage.
As has been said, the Pi doesn't have native ADC built-in, so you would need to add on ADC's. However, another significant factors would be which of these platforms you have familiarity with, and if having a linux OS there would be useful for the project, or not.
I have an openenergy Arduino. It sends data to a Raspberry Pi running Openenergy software. For a while I was using a public Openenergy server. Readings are recorded every second. I record live to neutral voltage. To record other voltages I would need an irregular 13 amp socket.
If I am away from home in the winter I can see whether my boiler has been running.
Others have made that point. I don't have one and don't really think I need one. I think I should be able to "DIY" a solution which would also serve as an introduction to this new kit: I've been thinking for a while that it would be nice to have a portable data logger that I could use to monitor the heating system, etc.
I have an old PicoLog system somewhere that came in handy when diagnosing a combi boiler problem, but of course that had to be hooked up to a rumning netbook so it was all a bit cumbersome.
I've not touched either platform before, one of my reasons I'm interested in the views of those who have.
I converted an old desktop into a Ubuntu box so that I could have a play, and I've also got a Mint stick that I have used occasionally. I'm not particularly bothered about getting into Linux, but I'd do it if I had a project that needed it. I havn't done any serious coding for more than 30 years, but I imagine I could pick it up without too much difficulty (especially now that it's easy to find examples on the net).
Hmm. My instinct would be to sample MUCH more frequently than that and sample AC as well so that you get a really good set of smaples, and then do any filtering in 'software'
I dunno how long an arduino trakes to do a sample but it cant be that long
Oh. It seems you can sample at up to 9.6Khz...that should do nicley - and take an RMS value of the waverorm and moving average it out over the last say one second...and use that to store.
Or uses a shirfter period for more sensitivity to transients
Basically you need a small mains transformer to step down to about 5VAC or so, then a voltage diveider to set the mean voltage in the middle of the arduino range, and a pot to scale the output to - say 0-5V representing up to say 500V peak...
If say you are taking 5khz samples you will need a nmemoiryy buffer of
5000 16 bits (10k of RAM) to store the samples and a further location to do the running average in.
The problem I'd see with an Arduino would be Time in that it;s not very good as a clock but this would only be important if you wanted to know what time an event happend rather than it just happening and being recorded.
HomeOwnersHub website is not affiliated with any of the manufacturers or service providers discussed here.
All logos and trade names are the property of their respective owners.