Sensing Current for Solar

by Ben N on November 13, 2017

About a week or so ago, I started playing around with a DIY current sensor. The initial experiments seemed to work, so I took it out to the garage, and hooked it up to my grid-tie solar array.

I first removed the cover from my garage circuit breaker panel so that I could get to the actual wiring. Next, I clamped the CT (current transducer) onto one of the two HOT wires from my solar combiner box to the circuit breaker that feeds the solar power in to my garage. I’m using micro-inverters, so the power is already 240V AC. There’s no neutral used, and both legs have the same current flowing through them, so I can get an accurate measurement with just one CT.

I used some double-sided tape to stick my Arduino, breadboard, and servo onto a piece of cardboard. That way, I could just hang the whole unit on the wall near the breaker panel. For testing, the whole thing is just powered off a 5V USB battery pack.



So far, this project is based on concepts from the Open Energy Monitoring project. Take a look at their web page. There’s all sorts of great information there! This link will take you straight to the section on sensing current. LINK

In a nut-shell, the CT creates a small current proportional to however much current is traveling through the wire the CT is clamped around.

That current then effects the voltage of the circuit it’s connected to, based on the voltage supplied and resistance of that circuit. In this way, a large current gets converted to a low current and then into a low voltage which can be read by the Arduino. (For details of how this happens, please visit this page.)

Inside a micro-controller, it’s very easy to do a little math and then use that to output to the real world. In the tutorial I was following, the output is just using a USB cable to display data on a computer screen through the Arduino software. Once I had done that, I modified the code to instead move a servo to a position, based on the current measured. (I did that by essentially just cutting and pasting some code from a servo tutorial.)

The whole idea is to create data (the current sensed) and then be able to interact with the real world (position a pointer on a servo.) In this case, I’d like to make a simple “Speedometer” style physical display which would just show how much solar power I’m making.

The next step after that would be to use the data to interact with an electric car charging station (EVSE) or other power use that I would want to control, depending on how much solar power I have available. For example, I could have an electric car charging station which would allow the car to charge at full power, but have it charge more slowly when a cloud comes in front of the sun. That way, I would maximize my solar use yet NOT draw power from the grid for my car charging.

Anyways, I’m still just in the early stages of this monitoring system, but it’s pretty cool to learn how things work, and then figure out neat new ways to use them!

Until next time, stay charged up!


PS: To be technically accurate, at this point, I am simply measuring current. I’m really trying to figure out the POWER of my solar, which would be measured in Watts. Right now, I’m just doing some multiplication times 240V to get power. The finished version of this project will include a voltage sensor so that truly accurate power can be measured, as well as tracking which direction power is flowing. That aspect is important back at the meter to see if I’m importing energy from the grid or exporting to it.

PPS: Here’s the video I shot when I was first starting to play with this:



{ 3 comments… read them below or add one }

1 Emmanuel ADEKUNLE December 2, 2017 at 8:36 am

Hey i ve been following ur *chain *..ahem of electric vehicles and I’m hoping to get an emptied out body at a reasonable price but i was thinking do you think if i replace the car wheels with probably a motor bike’s wwheel, or any thing lighter would it improve to rpm of the wheels and is it a good idea.

2 james February 11, 2018 at 7:09 pm

this is super interesting. found my way from MMM forum. Nice work. Is the purpose of limiting output during solar production because you “pay” a different rates during each day? i.e. you don’t want to “consume” higher cost energy when you could just charge the car at night at the lower rate. If this is correct, I think it maybe works out in the wash anyway. I’m quite confident I’m missing something. Still taking this all in.

3 Ben N February 11, 2018 at 7:20 pm

Hi James,
In my case, I have a square deal with my power company, and pay the same price for electricity at any time of day and I am credited that same full price for any excess electricity that I produce and push to the grid. However, not everyone is as fortunate as I am. Many people with grid-tie systems get paid LESS for power they send to the grid than power they GET from the grid. There are also places where people are allowed grid-tie solar, but may not send out ANY power to the grid (ZERO-Export)
Charging an electric car is a pretty hefty electric load. Ideally, it makes the most sense to USE whatever solar power you have when you have it. However, solar power can vary, based on the weather. Therefore, I think one of the best ways to approach it is to vary that load to match the solar power produced.
In a really well thought out system, a measurement could be taken of how much solar is being produced, how much total power is being used in the home, and then just the difference is applied to charging a car. That way, even as appliances are turned on and off, the solar is completely used to charge the car.

I really like the idea of doing this, but as I said, it’s almost more for figuring it out and for other people than something that I really “need”. For people with Time of Day rates, bad deals on power export, etc., it could be really financially handy!

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Previous post:

Next post: