Thursday, June 14, 2018

Local Power Politics: APS, AZCC and Things to Think About.

In my last political (well sorta) post I described how the local power company APS is organized and regulated by our Arizona Corporate Commission (AZCC) <link>. After that post and a few I did on local social media, I got a couple of requests to put this stuff all in one place. Well, I have a place to put it, and I'm getting tired of posting it over and over again, so here is my collection of gripes about our own AZCC and the power company APS. I decided to post this stuff on the blog because it related very directly with my efforts to keep the power bill as low as possible and the pitfalls, stumbling blocks and walls along the way.

I'm linking them all together on the (newly added) subject of 'Power Company' over on the top right of this page. Just scroll down to the 'P' and click on it.

The idea is that I can just put up a blog post, and then use a link to expand on my findings or thoughts easily without having to type them in all over again. Clever right? It also means that I can hit and run on social media. That means I can just slap a link on there and go off to the next place and do the same. There's a lot of social media sites that discuss this kind of thing out there.

No, I'm not a social activist, I'm a customer that is tired of getting raked over by politicians and corporations that are supposed to exist in our best interest.

Therefore, here are three 'Dockets' and one 'Announcement' that are recent and directly impact me and my neighbors in this area. They're real and verifiable. I try to put in links for the various items so people can double check me. Some of the text is my opinion, feel free to comment.

AZCC Docket # E-01345A-18-0111 - In the matter of the application of Arizona Public Service Company for approval of its Rate Rider RCP.

Last month (May, 2018) APS applied to the AZCC for a modification of the "rcp export rider for new on-site solar." This is currently being heard by the commission with no decision yet.

But, what the heck is this?

They invent names and acronyms to make it easier to describe things, but it also complicates reading this stuff to the point where people just give up and wander away. Resource Comparison Proxy (RCP) is a complicated series of observations to gather data, then calculations to show how much APS should be paying solar customers, people with solar that produce an excess of power and return it to APS.

What this is, is if your solar was installed after the cut off date, September 1, 2017, they want to change what they are allowing (as credits) for your excess power. Currently it's shown as $0.12900/kWh, almost 13 cents for each kWh you don't use and give to APS, and they want to lower it to $0.116 a little over a cent less.

They actually claim that it should be zero, but they're not going for that yet.
"... the avoided transmission and distribution capacity cost credit to be applied to the RCP should actually be 0%."
They already charge much more to supply power than they pay for it from the excess solar people provide, and now they want to lower that payment (actually credit). This is a decrease of over 10% to them. Essentially they're asking for a 10% decrease in what they agreed to just last fall in the last rate increase decision.

Yes, it's all above board and public in AZCC Docket #E-01345A-18-0111 and it's supporting documentation, but how many have heard about it? Is the news going nuts on this? Have you received any mail about it?

But wait you say, just last year APS agreed not to file for another rate increase until much later. That's completely true, but they're not asking for a rate increase, they're asking for a modification to a rider on your bill. See how it's done? You pay more, but they didn't do it, it's a rider on your bill. When you call them about it, they tell you it was approved by the AZCC.

Why aren't the solar companies complaining about this? Actually, the solar association has filed a response, they're angry that APS is attempting an end run around other agreements. For whatever good it will do.

Those that have solar already are managing to skate past it right now, but APS will be back before the AZCC soon. Those that are getting new solar will be impacted severely by the new rules, so this is a concern that everyone should be interested in.

E-01345A-18-0003 - In the matter of the application by Arizona Public Service Company to Implement Tax Expense Adjustor Mechanism.

This docket is actually in our (the customer) favor. When President Trump's tax changes came into effect, it lowered APS's tax rate to 21%, and they saved money. Someone realized, then insisted that APS revise their bill to reflect the savings instead of keeping it as a windfall. This was done under dockets #E-01345A-16-0036 and E-01345A-16-0123. The amount is a tiny percentage per kilowatt hour, but amounted to about $10 on my last bill.

The adjustment rate is supposed to be $.004258 per kWh, so the more you use, the more you get deducted from your bill. I question why they are paying it back by the kWh, it was a percentage decrease in taxes, why wasn't it a percentage decrease in our bill? When I looked closely at the docket, it was clear that they decided to play tax games with the requirement and deducted for various other things. They got to keep a heck of a lot of this windfall against their own expenses. One could also make a pretty clear case for discrimination; they get windfall money, then when caught, return it to their biggest customers by returning it based on how big their bill was. Our own APS sticking its hands in our pocket again. (actually, I may use that line in a complaint to the AZCC)

However, this also helps disguise the credit for money APS is saving in taxes as something APS is doing for us. It's not them giving us something, it's them not stealing something else from us. They even called it "TEAM" for Tax Expense Adjustor Mechanism, and shows up on the bill as "Tax Expense Adjustor."

PUBLIC NOTICE OF APS'S REQUEST FOR APPROVAL OF A FOUR
CORNERS SCR ADJUSTMENT (DOCKET NOS. E-01345A-16-0036 AND
16-0123)
"On April 27, 2018, APS filed a request for a Four Corners SCR Adjustment to allow recovery of an annual revenue requirement of $67.5 million. APS estimates that the average residential monthly bill impact would be an increase of approximately two percent. A copy of the request is available from APS  azenergyfuture.com), and at the Arizona Corporation Commission's eDocket website (edocket.azcc.gov), for public inspection in the above-referenced docket numbers"
The item above and the quote was one of those inclusions in the bill that we all toss out while looking to see how much they gouged us this month. What it's referring to is the pollution lowering devices called "Selective Catalytic Reduction" that they are installing at the Four Corners Power Plant. That particular power plant is coal fired and was cited for pollution. It's a long story beyond this author's willingness to write about right now. 

But, quoting directly from the AZCC filing:
 "(SCR Adjustment) to permit recovery of a $67.5 million annual revenue requirement."
You certainly see what is going on, the clue should have been "recovery." They want to pass the 67 million dollar per year cost of this stuff to their customers. Another quote from the same document:

"That would equate to an approximate 2% customer base rate bill impact. Additionally, APS requests that the SCR Adjustment become effective as soon as possible, but no later than January 1, 2019"
Yes, you read it right, they want to add another 'fee' to the bill to cover this and this one is a straight 2% increase in the base rate. Ever wonder why the base rate applies to all customers. This should give you a hint. You can read it yourself at <link>. It's also on the public record at the AZCC site under the unassuming name: "Motion/Request - Miscellaneous," but I suppose that's a little less noticeable than, "Motion to Screw Our Customers into Paying for Our Mistakes." The link to the document there is <link>.

AZCC Docket # E-01345A-18-0002 - In the matter of the formal complaint against Arizona Public Service Company filed by Stacey Champion and other Arizona Public Service Company customers

This docket is a direct complaint from a group of citizens against APS's latest rate increase (and fees of course). The dockets that the rate increase was approved were E-01345A-16-0036 AND E-01345A-16-0123. These two dockets were combined because they related to the same things. Eventually, they excluded existing solar, customers for the most part (more on that below), but most of us don't have solar, so the latest rate increase (and fees) from APS is directly impacting us; this also has significant impact on any new solar installations.

Stacey Champion, the named complainant, and a group of several hundred people gathered from a web campaign filed this, but as everyone suspects, APS is dealing in an underhanded fashion with the public and the AZCC. Want some facts to look up for verification? APS used the upcoming 2018 election as leverage against the Corporation Commission in writing and they did it on the public record. The following is a quote I copied and pasted:
"Unfortunately, APS is concerned that delay will only push this matter closer to the November 2018 election, which risks distorting this process and increasing customer confusion."
Which means: There's an election coming up and you guys may not get our funding if you don't end this now in our favor. Or maybe, if the complaint isn't decided soon, the voters may notice and vote against you. At any rate, it's pretty clearly a threatening statement. You want to see where they said this, go look at it on the state web site at this <link>. I think it's on page three.  Fortunately, Stacey Champion's lawyer noticed what they were doing and put this in the response:
"As for the November 2018 election, it is irrelevant to this proceeding and APS' professed concern that it "risks distorting this process and increasing customer confusion" should not trump Ms. Champion's right to due process."

Basically, Stacey's lawyer said, "We see what you're doing, and it's bullshit." If you want to read this it's at this <link>.This one is on page 4.

I also ran across the following part of a sentence when reading through an APS response to Stacey's complaint. I cut and pasted this right out of the document on the AZCC web site at <link>.
"(iii) an agreement with the solar industry to resolve a multi-year, otherwise intractable dispute regarding distributed generation that included a confidential agreement to avoid undermining the rate settlement through ballot initiatives, legislation, or advocacy at the ACC, "

What this means is that the solar industry in this state got together with APS and agreed that the solar folk wouldn't put up a ballot initiative, sponsor legislation or lobby the Corporate Commission. Since it is confidential, we don't get to see what the Solar companies got in return for GIVING APS FREE REIGN ON THIS RATE INCREASE.

Excuse my language, WHAT THE HECK??

We were all sold down the road by a secret agreement between APS and the Solar Industry ...

Yeah, this really makes me want to talk to a solar company in this state.

Now, if you do actually read this far, think about it a bit. Here is publicly held documentation that APS is using the upcoming election as a tool against the Corporation Commission and they entered into a secret agreement with the solar industry to shut them up. Now act accordingly. I suggest you visit Stacey Champion's site, read the documentation and contribute to the effort. Stacey is taking on APS for us, and they're driving her down with legal fees. If she has to withdraw because she can't afford it, that's the end of the effort to get this back for a rehearing.

https://www.fundedjustice.com/StopTheAPSGreed?ref=ab_6Ezo8KIX4xn6Ezo8KIX4xn

You can also file a complaint directly with the AZCC in support of Stacey's docket. Heres how to complain:

 What you have to do is go to

http://eservice.azcc.gov/Utilities/Complaint

And file a complaint.

You MUST state that you're commenting on the existing docket number E-01345A-18-0002 in the first line so they can see what you're doing. I started mine off with:

"In support of Docket Number: E-01345A-18-0002 It appears that APS did not deal in good faith with its ratepayers, the Corporation Commission or the public in general. "

The "In support" part means you agree with Stacey Campbell that APS is a bunch of thieves, and it also shows up in a listing of the documents filed on this docket. You also have to fill out all the blanks in the form to identify yourself as a customer of APS so you will be taken seriously. At the bottom of the form is a space to type in exactly what you think about this.

We have elected representatives in the state legislature, time to actually use them and see what happens, so here are the two for District 1. I'm listing their web pages so you can get to the mail facility easily.

David Stringer is at:
https://www.azleg.gov/House/House-member/?legislature=53&legislator=1748

and Noel Campbell is at:
https://www.azleg.gov/House/House-member/?legislature=53&legislator=1718

State Senator Karen Fann is at:
https://www.azleg.gov/emailazleg/?legislatorId=1774

Just click on their email address and let them know what you think about this.

Sorry this is so long, but I wanted to get the actual links in so you can see for yourself what I have seen.

I really hope I made you angry.

Oh, one other thing: the spam will really be flying on this post, so be warned: talking about how great your solar plan is, sales blurbs or obnoxious comments will be deleted without remorse.

Wednesday, June 13, 2018

Supercooling in the Desert: May 22, 2018 a day that will live in infamy !

This is the day I got clobbered by APS (my power company)


Look just before 8PM (20:00); see that bunch of spikes? My peak billing period lasts until 8, and something was sucking power before the period ended ! Let me expand the little piece that shows the problem:


That little period from about 7:24 to 8:00PM was the clothes dryer.

Yes, just a little before the end of my peak period a guest started the dryer to do some clothes. It wasn't their fault, they didn't know that the fascist power company would be watching to see if such a thing happened.

The peaks run as high as 7.4 kW, and it was doing this for a little over a half hour. The APS chart shows it like this:


And it was almost impossible to find. I looked for quite a while before I noticed it. I put the arrow on there to show you the tiny little green area that resulted. It shows up a little better on a single day chart:


That minor little slope up in the green area is where the meter saw the dryer running. It's recorded as "usage 3.18" during the 7-8PM hour. In theory, this should be my high 'demand' number that is calculated into my bill for the month.

I guess I should do a little calculating to see how this works to help me understand and avoid it even more stringently in the future. Let's look at the detail portion of my bill first:


So, the demand number wound up being 3.17 and is used as a multiplier in several items in billing. Here's the rate sheet for the plan I'm on:


So, my 'On-Peak Demand Charge' is 17.438 * 3.17 for $55.28. But, there's nothing on my bill that says that. Guess what? To make it more complicated and harder to understand, they actually split the $17 charge into two components and calculate them separately. From their tarif sheet again:


Notice how the two numbers, $4.000 and $13.438 add up to the $17.438 they call the 'On-Peak Demand Charge'. OK, fine, I have a calculator and can punch in numbers like anyone else. 4.000 * 3.17 = 12.68 and 13.438 * 3.17 = 42.60, and they add up to the 55.28 I got above. So I should see:

Delivery On-Peak Charge 12.68
Generation On-Peak Charge 42.60

Or something similar on the bill, and indeed I do. Sort of:

Demand charge on-peak - delivery $12.40
Demand charge on-peak - generation $41.66

If you look at the bill, you'll see them on there. The sum of the two charges is $54.06 which is darn close to my initial $55.28. The reason for the difference is that APS made a mistake in the original rate change request and has to use the demand number to one significant digit and they can't round, so the actual demand number they get to use in this case is 3.1kW. That's on the bill also, so I don't even have to do the truncation itself:

Your billed on-peak demand in kW 3.1

That's a good thing because rounding would have put me up to 3.2 and would be paying even more.

Now, I got the cost all figured out, the dryer running cost me some amount, but how much extra based on past performance. To get that, I'm going to look at last month to see; taken from last month's bill:

Your billed on-peak demand in kW 1.5
Demand charge on-peak - delivery $6.00
Demand charge on-peak - generation $20.16

That stuff totals up to $26.16, so my dryer cost me $27.90 last month because I didn't keep it under control. It's actually a little bit higher because the rate per kW during peak is higher ($0.08683 vs $0.05230), but that's only 3 cents per kw, and the dryer only uses 7.5 kW at around a 50% duty cycle for 3.75 kW or $0.32 extra. I'm willing to ignore that.

Now is the appropriate time to talk about how APS gets that demand number. As I mentioned in another post, they average each hour and compare it to the maximum hour during the billing cycle. That gives me 5 vulnerable periods each day: 3-4, 4-5, 5-6, 6-7, 7-8. So, the dryer kicked on and sucked power in bursts like all electrical heating appliances and those bursts pulled 7.5 kW for a short period. The bursts were roughly half the time, so it worked out, on average, to the 3.17 kW number that APS measured. It would be too much to read if I did all the calculations, but you see what I mean. That 3.17 was the highest reading so far that month, so it kept it and continued to look for a higher hour; fortunately, it didn't find one, and that's how the month's bill came to be. Next post I'm going into how to read our smart meter so folk can actually see what is coming. Unless one goes to the trouble of doing what I've done, you can't catch it real time and stop it; you can only see the what's already happened.

This is not going to break me, but it does lose me some bragging rights. Because I didn't keep control, I'm out about 28 bucks. Be warned though, if the hot water heater had kicked on, and the stove was running, this would have been a monetary disaster. Thank goodness it was only the clothes dryer and that close to the end of peak !

There you are, an example of how power can get out of control no matter what you do and how much attention you pay to it. Something will slip in and get you from time to time. Overall though, keeping tabs on my power has saved me thousands over the years. This post is also good for folk that don't completely understand how that 'Demand Billing' stuff actually works, and how to tell if you're messing up.

The parts to prevent this from happening to me again are already on order.

Sunday, June 10, 2018

Wrapping Up The Water Heater Monitor (and control)

For the present, I'm going to claim that (as the British say) the water heater monitor is, "All done and dusted." There's a few tiny items I'll mention that I may do in the future to make is a little easier for other folk to understand, but it does what I set out to do with it.

It monitors the temperature at the top and bottom of the tank, the power usage of the entire system and controls the power applied to the internal heating element. I save the data on my house data base and can chart anything I want. It has been a cool project that I got to use new things on and implement some software that I haven't dealt with yet.

To measure the temperature I made a couple of sensors out of discrete 18B20 temperature sensors and installed them under the insulation against the tank at the top and bottom. No, I wasn't going to drill into the tank to install them, and I wasn't going to tap into the existing sensors that drive the tank. Tapping into the existing sensors might break them and drilling into the tank would have been a disaster. I want this thing to be capable of working if the new electronics ever fail.

Here's one of the sensors:


I thought about using one of the 18B20 sensors that are enclosed in a waterproof stainless steel enclosure, but I wanted as much sensitivity as possible and jamming the sensor up against the tank and securing it with metal tape seemed like the best way to do it.  It was a bit of a pain getting through the insulation to the tank, and the tank itself was covered with a high density insulation as well. I didn't dig into the tank coating; I just secured the sensor to the top of it. This made my reading low as compared to the temperature of the water inside, but if necessary in the future, I can correct for that by adding a little to the reading in the code.

With two sensors, the PZEM-004 power monitor, power supply and control wire for 220VAC power to the heating element, I ran into a little problem with available connectors for power ground and the sensors. After considering electrical tape, hot glue, shrink tubing and such, I just soldered some more power, ground and sensor connectors on the XBee shield I used.


Those three vertical black things are where I tap off and supply the various power and signals. I'm going to have to remember this trick in the future. It turned out to be a really convenient way to get extra connections. I even put the pull up resistor that one-wire devices need in there. You can barely see the 4.7K resistor in there between the rows of connections.

But, you ask, what did you discover after all this work? Well, I discovered how annoying working on a step stool over the top of a working solar hot water system is. Up, down, dropping things, wires too short to reach, taking it apart, putting it back together, all were inconvenient. It probably added several hours of pure frustration to the process, but all of us folk that do this around the house should be used to that ... right?

Here's a chart of actual operation that I pulled today:


In this the solar is running at around 80 watts and then reaches temperature and shuts off. The top of the tank was at 129F and the bottom at 118F for a differential of 11 degrees over the height of the tank. The actual water temperature measured at a nearby faucet was 138F, so it looks like the tank coating was keeping 9F of temperature away. To me, that's OK since I understand what is going on.

I also caught this where I turned on the dishwasher after the sun went down:


You can clearly see where I turned on the dishwasher and the cold (well tepid) water came into the bottom of the tank. Then a little later the rinse cycles of the dishwasher removed some more hot water from the tank. The temperature at the top of the tank didn't drop that much though, only down to 127F. It wasn't even enough to turn on the heating element (it was dark outside). Here's the entire chart for the same period:


Ok, it's a mess. That's because the power being used is only 3-10 watts and that auto expands to cover most of the chart. But, you can see that it isn't using 80 watts circulating the solar or over 4000 watts running the heating element, and that the grid power was available by the green line at the bottom.

That means that I ran the dishwasher a full cycle with hot water and didn't pay anything for heating the water since it was still hot from the solar cycle during the day. I've seen this several times now; the dishwasher, shower, various faucets, don't use enough to cause the heating element to turn on. Especially since the incoming water is probably close to 100F already during the day.  Hang on a minute, I'll go measure the water temperature coming into the house right now.

It was 89.6F. So, the incoming water is 90F and the solar will take it up to 138 making the differential only 48 degrees or so. It will show up as 129 on the graph due to the loss I described above, but that's a known thing. As a matter of fact, the heating element hasn't come on at all in the last 72 hours. I can't show you a graph to prove it because I've had the thing taken apart too many times. I may post an update later after a few days of operation. But, as a consolation, let's take a look at the cooling rate of the water heater:


Here is a period between cycles of the solar heat running. The bottom temperature is affected by the solar running, so it is higher than the incoming water temperature; the heat transfer coils are at the bottom. That makes the bottom temperature drop at the beginning. The top temperature  drifts down over time at a reasonable rate of about a degree every hour that decreases to less than a degree every two hours when it gets around 125F or so. This thing will keep 80 gallons of hot water all night this time of year. I'll have to wait a few months to see what it does in colder weather. If it gets too cold, the heating element will turn on and raise it back up anyway.

Which brings up a point I didn't realize until I did this. The temperature for solar heated water is 138 degrees. I set that back when I got the heater and it is controlled by a differential controller separate from all the other stuff. The electrical heater is set lower; how much lower I don't know yet. I'll experiment a bit to find out, but I suspect it's about 10 degrees or so. That's why the mains power isn't used much. The solar keeps the water above the temperature where the heating element kicks in. I don't know where that control is, but it's worth looking for at some point.

Software wise, it wasn't particularly hard to put together. I used the arduino library for one-wire sensors like I did for my room temperature sensor project. What I did was to read the sensors, then read the power, then send the data using timers. Since the water isn't changing very fast due to the nature of water and the mass of 80 gallons, I only read it every minute. I read the power every 15 seconds. The report is sent every 30 seconds right now, but that may change in the future when the new wears off the project. In the remaining CPU cycles, I watch the XBee for incoming items.

I only respond to the time signal and a command to turn on the mains power. The mains power was easy, I just picked a digital pin on the arduino and set it high to turn on the 100 amp solid state relay in the box. I watch the time for obvious reasons, I turn off the mains power at noon (soon to be 3 PM) to avoid the peak period charges. It doesn't get to turn back on until 8PM.

I used the timeAlarm library for the arduino to handle both timers and alarms. Timers control the readings and report while alarms turn the mains power on and off.

See how previous projects where I used time and various libraries are paying off? As one works with this stuff it gets easier to put things together and create something new.

It didn't work first try though. Most of it did, but the darn thing quit sending data every day at noon when it turned off the mains power to the heater. The problem turned out to be that 'on' has one less letter than 'off', and I was overflowing the buffer that I build the JSON report string in. That simple little problem took almost a day to isolate. I kept trying to blame it on the pin controlling the SSR.

There you are, the most comprehensive water heater controller I've ever seen. Probably more than I'll ever actually need.

But, exactly what I wanted.

Edit: I just put the code in Github so you can take a look if you want to.

Thursday, May 31, 2018

Monitoring Water Heater Power

Well, I can now monitor my hot water heater power usage. The step-down transformer I got <link> worked just fine and I managed to put together all the pieces and now have it out there running just fine. I mounted the transformer on the lower right of the picture below. I used exactly the same technique that was used in the power converter it came out of, high adhesion two sided tape.

What I did was to spread some silicon grease on the bottom of the transformer then put the tape on one side. I pressed the grease down on the enclosure and slid the transformer back until the tape adhered to the back of the enclosure. This way I used the entire steel enclosure as a heat sink for the transformer. I used the same idea for the three phase solid state relay (SSR) that actually controls the power to the water heater.


In case some of you haven't worked with power transformers, they get hot. It seems like no matter how high the rating, they generate more heat than expected, and can cause problems over time. That's why I was careful about giving the heat generated somewhere to go.

Just to the left of the transformer is an Arduino with an XBee shield on top, and just left of that is a AC to 5VDC switching power supply.

This little power supply is really nice:
I got it from itead.com a while back because I knew I would need a small power supply in the future and wanted to try one out. Unfortunately, they retired this model and I only have one left. I guess I'll have to hunt down another one sometime in the future.

I took the easy way out in mounting both the Arduino and the power supply, hot glue. It just wasn't worth the effort to build something special to hold them in place, so I grabbed a piece of plywood and mounted them to it. Worked fine, and they'll still be easy to get to if I want to change something or fix it in the future.

The enclosure is from Home Depot and I've had it for a while now. It's been the enclosure for the big SSR in the middle of the box for years, I'm just now adding more circuitry to it.

I'm interested in monitoring the power right now, so I haven't moved the code to control the SSR over to this Arduino yet, but that will come in a few days. That control is still part of my garage controller that also controls the garage doors. As a matter of fact I had power applied to the water heater when I took this picture; you can tell because the LED on the SSR is on. The control for that comes through the small wire on the top and connects to the left side of the SSR.

I was a bit worried about how far the little XBee would reach since it would be inside a grounded metal box once I put the lid on, but it worked well enough that it got to another XBee and the network took care of the store forward part I needed to get away with this.

It looks pretty good up there on the wall above the water heater:


Now I can glance up at the display and tell immediately if the solar pump is working, the mains power is being used or nothing is going on. To measure the power used by the solar pump and temperature controller I used the transformer mentioned above to reduce the power from 240 to 120 and put a plug on the front of the enclosure.


Notice that the solar pump is running when I took the picture. It uses about 80 watts to circulate the fluid from the collector on the roof through the heat exchanger inside the water heater. It has to run a long time to heat the water up inside, but at 80 watts, I don't even notice the power usage.

Now that I can see all the power data for the water heater, I can pretty much write it off as a large factor in my power bill.


Above is a chart of the last 24 hours of all the power usage by my solar water heater. Notice that there is one peak of main usage around 10AM and some light usage at other times. The large peak is too short in duration to cause a problem with the 'demand' billing and the light usage is around 80 watts from the solar pump.

Here's a chart of just the solar pump running:


The gap just to the left of middle is me installing stuff. Yes, I turned off the breaker; I have a healthy respect for 240VAC directly from the mains panel. All the jagged readings on the lines are the circuitry doing measurements and sending them off through the XBee. I have blinking lights on the Arduino and displays of the PZEM-0400 that are constantly changing. Makes for an interesting display.

Now before the more astute readers out there start picking on me for parasitic power usage, here's a chart of the power usage when nothing is heating at all:


The usage when nothing is heating varies between 3 and 10 watts, that will take a long time to add up to a full kilowatt and even show up on my bill. If you look up above at the first chart, you'll see that this is the condition that the water heater is in most of the time.

Actually, when I looked at parasitic power a few years ago, it just wasn't a problem. I have a baseline of roughly 500 watts that is used all the time. Things like ceiling fans, necessary appliances, phone chargers and such do add up, but what are you going to do about it? You have to keep the food cold and a 10 watt device running just isn't worth bothering with. All the hype about this just doesn't add up.

So, I did all this just to find out that my water heater is doing a really good job of saving me money. To heat the 80 gallons of water in my heater using the rule of thumb number of 0.166 kWh per gallon (60 degree F increase) for 80 gallons is 13kWh of power. I get it for a few hours of 80 watts in full sun. And, sunny days are not something in short supply around here.

I'll use the charts and power control to find a happy medium between using sunshine and mains power for keeping the power bill under control. I'm sure I can fine tune this over time. Plus, for the rare cloudy day, I can always crank on the power during off-peak periods to handle my hot water needs. I have special web code to do that from anywhere <link>.

I'm not quite done with the water heater yet though. I want to put a couple of thermometers up against the tank one at the top and one at the bottom to measure the actual temperature of the water. I also want to move the code that controls the SSR over to the new device so I have all the water heater code in one place.

But this little exercise has opened the doors to another possibility. All of my 240 volt appliances should have monitoring like this. I can get several of the power monitors and install them for the AC compressors, AC air handlers, dryer, and maybe even the microwave. Heck, I could monitor the kitchen oven as well. Hmmm, I could use another SSR and keep the darn clothes dryer from messing with my power bill, that has happened twice now. Someone needs clothes dried and they turn on the dryer during the peak period. I can actually put a stop to that by doing what I've done with the water heater.

How come every project leads to another?

Tuesday, May 29, 2018

Ordering Chinese Devices Through Amazon

This isn't a complaint session about Amazon, they've done well by me <link> several times, nor am I going to complain about Chinese products; a lot of the posts on this blog are about those items. This is just the story about a single product that I thought my readers would enjoy.

I needed a 240VAC to 110VAC transformer to provide power for my latest project, increased monitoring of my solar water heater. The 45 watt pump that moves fluid from the rooftop collector actually measured 68 watts when I plugged it into a Kill-a-watt to measure it. I know how this stuff goes, so I figured I'd probably need a 200 watt transformer because they always over rate these things in the specs, and I should probably stay below 50% of rating to get good service.

Have you checked out the prices on those things? A simple 2 to 1 transformer can cost as much as one can pay. The prices I found started around $37 and went up indefinitely from there. I know these things exist and shouldn't cost as much as some televisions, so I looked for another solution. I thought I found it and ordered one of these:

It's a 220 to 110 transformer rated at 200 watts for converting power for US travelers abroad. The images on Amazon showed the interior and it is a simple transformer with no other supporting circuitry to worry about. This should be perfect and only costs $16. That's less than half the price I found for the transformer inside.

It came in today and I rushed to unwrap it --- it rattled. There was something broken inside that sounded like a piece of plastic. But first, here's a picture of what I received:


First, notice the plug. It's a normal non-polarized US plug, not the European round pin plug shown on the Amazon page. Why would they put a US plug on something that was designed to be used outside the US?

Since I was going to dismantle it anyway, I took it apart.


There was the transformer I needed, but what had happened was that the transformer had come loose from the case, banged into the molded socket and broken one of the plastic pieces. The transformer was supposed to be mounted with some of that high strength two sided tape. I've used this tape several times and it really works great; why did it fail? Well, here's a shot of the tape:


Don't see it? They didn't remove the paper from one side of the tape. Like all two sided tape rolls, there is a piece of paper on one side of the tape. You cut off a piece, stick it to whatever you're attaching, then peel the piece of paper off and adhere the tape where you want it. This simple technique holds lots of things in our everyday life in place. The decorative molding on your car is probably held on this way, and you drive it at speed down the road every day. This stuff is good, if you actually remember to take the paper off.

What happened is that Amazon took the converter off the shelf in its box, shoved it into a padded envelope and shipped it to me. One of the conveyor belts somewhere dropped the envelope a little ways, the  loose transformer banged against the molded socket and broke it. That was how my rattle came to be.

If I wasn't going to only use the transformer, I would have returned it for another one. But the part I needed came through the ordeal unscathed. Unfortunately, there are no numbers on the transformer at all. No manufacturer, no nothing that can help me trace it to buy another. Maybe someone reading this will have some idea where I can source another when I need it.

So, even though the plug is dumb, it arrived broken and would have been intrinsically unsafe in use, it fits my needs perfectly. I saved at least $15 buying this instead of a transformer from a regular supplier.

Go figure.

Monday, May 28, 2018

PZEM-004: Now to actually use it for something

Literally hundreds of these energy monitors have been sold, but judging from the various articles I've run across, not too many of them have actually been used to meaningfully monitor power around the house. I'm going to install one of them on a troublesome device and actually use it to help understand my power usage. My current victim is my hot water heater.

I've described it before <link>, it's a solar hot water heater with a helper element in it for times when the sun isn't shining. Basically every day here in the desert I'm supplied with unlimited heating for water, but how often do I need the heater element? The element is designed to turn on any time the temperature drops below a certain temperature, but I have no idea what temperature that is. I have the solar heating set for 138F, and since it is an 80 gallon heater, this supplies my needs quite well. Nevertheless, I still want to understand the device and how it uses power.

The first thing I need to do is both read the serial output from the power monitor and be able to transmit it to my house controller so I can save the readings over time. This turned out to be a problem because an arduino only has one hardware serial port. It is possible using software to get another one, but having two software ports is a problem.

The SoftwareSerial library allows for two serial ports, but you can only work with one at a time. Each time you switch ports, the input buffer for the other one is cleared. When I tried it, that meant that the buffers were wiped such that I couldn't actually get enough data from either the XBee or the power monitor to construct a usable packet. I want the serial port for debugging and commands, so I had to work out another method.

What I did was set up a timer that fires off every 15 seconds to interrogate the power monitor, saving the data in global variables. Every 30 seconds another timer fires and sends a report of whatever the variables happen to hold at that time over the XBee network. This way I have reasonably fresh data to send every thirty seconds and only use the two software ports one at a time.

The exception is that in the main loop of the code I check for incoming data from the XBee network at every iteration. Basically in the idle periods between gathering and reporting, I check the network. To prevent the arduino startup from sending bad data from the variables that aren't filled in yet, I read the power monitor before I do anything else. Then I wait for a time message from my house clock, set the two timers and let it run.

It seemed to work pretty well.

Now, how the heck am I going to attach this mess to the water heater? I'm dealing with mains voltages here, I can't just stuff it in a cardboard box and hang it by its USB cord on a nail. This will take some consideration. Additionally, since there is no neutral line to the water heater, everything needs to work from a 220VAC source. Yes, I know, most of the world already has this to deal with; for me, it's a new experience.

Being impatient, I took a big rag and insulated (if you can call it that) the top of the water heater and hooked the power monitor to the high power solid state relay that I use to control the power to the water heater. Then I draped the USB cord over to a wall plug for 5VDC power to the arduino and XBee combination. This way I could actually watch the water heater power usage real time and work on the software to add the data to my Graphana display.


I had some foresight though, I put in plugs for the connections to the CT, 240VAC voltage monitor and serial input so I wouldn't have to flip the breaker when I did something, and it worked like a charm after some programming to save the data I had gathered and a little work in the charting software:


Granted, it's not much to look at. The heater only turned on three times, and even then, it was only for a minute. Slow day around here, but notice that the spikes are 4500 watts. This thing can really pull the power; remember, the solar is running also.

What is happening is that using hot water causes the temperature in the tank to drop and both the solar and the helper element kick on. This heated the water back up in a hurry. Or, maybe I have a bug I haven't discovered yet. Over the next few days I intend to look at how hot water is used for showers and general use around the house. I won't get good data on how this thing is working until I can also monitor the small solar pump as well, but that will take some thought, and probably, some more parts and pieces. Keep in mind that the small pump is 120VAC and I'm working with 240 at this point. A transformer maybe??

My data gathering will be impacted by the fact that the water here doesn't get cold enough to need much of it. This time of year, the rest of summer and early fall, one can take a shower with nothing but the cold water turned on. The best we get for cold water is tepid, and maybe use a tiny bit of water from the hot side. Not that way in the winter though, then hot water usage is much higher.

I'm starting to like the PZEM-004; when this project is running, I want to look around at other similar devices. It's hard to beat less than $15 for a device like this. I certainly can't build an equivalent for less.

I'll put the code for this on github when it is a little farther along. There may be too many bugs right now.

Previous post on PZEM-004 <link>

Friday, May 18, 2018

Supercooling a House in the Desert: part 3

I'm going to talk about the APS (Arizona Public Service) phone software for monitoring your power. For folk that don't live here (Arizona, USA), much of this will be of little value. It might give you a clue as to how your own power company works, but this is directed at my neighbors.

I'm not going to describe how to look at your bill, or make a payment, etc. I want to talk about the usage numbers and graphs they provide so you can monitor how good or bad you're doing at saving money by juggling power usage.

First though, I want to explain a bit for people in other countries with different rules around providing power. The name, Arizona Public Service is historic and not actually reflective of what it is. APS is a private company that supplies power to a big part of Arizona. They are publicly held (as in stockholders) and regulated under Arizona's version of a public utilities commission, the Arizona Corporate Commission (AZCC). The AZCC is also in charge of licensing corporations in this state. So, if APS wants to increase its rates to customers, it has to get approval from the AZCC. Confused yet?

One of the things that is part of every submission for a rate increase is the statement, "fair and reasonable return on investment." Which means that if APS runs their business sloppily and doesn't make enough profit, they ask for a rate increase to increase the profit. Nice business to be in. If you screw up a business decision, there's someone out there that will guarantee you a profit.

No, I'm not being completely fair, there are various government requirements that APS is forced to meet, and those do increase their costs. But, every time one of those comes along, a new 'fee' is added to our bill. AZCC approval of these items is almost automatic.

Enough background, on to the actual application.

The app is called 'APS' and is on the google play store for download. Once you get it installed, you can log in to your web account with APS and look at billing and usage. There's also hints on ways to save, but that's just the usual things that we see every day about conservation. The last choice is 'apsFYI' that is the same things that they send with the bills. I'm not going to discuss the billing areas; it's hard to remove my account information from every single illustration. I may get to that at a later point though.

Lets go to 'MY USAGE' and see what it shows for me when I do it, that's where the fun stuff is:



You get a nice display that shows your percentage of use on peak. That means of the amount of energy you used so far this billing period, some percentage was during the peak demand period. Mine was 7%, which must mean that the rest, 93% was off peak usage:


And they have a display for that as well. The real data that can actually help is found by touching the 'Detailed Energy Usage' link at the bottom.


This is actually a nice chart that shows my energy usage for the last 6 days. It's only been six days so far this period. The bars are divided into peak usage, green and off peak usage, blue. The height of the entire bar is my total usage for that particular day. So, I used a lot off peak and only a little bit on peak; the actual values for these can be displayed by touching one of the bars.


So, what does this mean? It shows you when you are using the most power, on peak or off peak, and that's important because the billing rates are considerably different. I want to use as little as possible on peak and concentrate my usage to the off peak periods. That way I can use the larger appliances and pay the least possible for it.

If you touch 'LAST CYCLE' you'll be shown the entire period and you can inspect each day to see if you ran something big during the peak period.


This display can be scrolled left and right to get to a particular day. You can then see the days where you used the most power and work out a plan to deal with it in some fashion. Notice that I used almost 80Kwh on the 28th; it was Saturday and off peak, so I just let the AC run. Rates are much cheaper off peak and I can afford to do this. You certainly wouldn't want the green area to get large because that would result in probably an excess of $100 addition to the bill.

Up at the top of the display is a drop down menu currently labeled 'Daily Energy Use', This menu will let you look at a more detailed display that will actually show you your usage times. Here's mine:


For the last week this displays my usage on a time line so I can get an idea when my major usage occurs. My chart above shows that I cut the usage way back during the peak period (green) and then let it run wild the rest of the time. The big peaks just after the demand period is the AC kicking on full bore to cool the house back down to where I normally keep it. Also in there is the stove, dryer, pool pump, all the things that use a lot of power. See how I control my usage to only the cheaper times?

The reason they call this 'Demand' is because you can scan the green area to see when something turned on a drove the demand number up. They save the highest of the green parts as your demand number and use it as a multiplier on your bill.

If you choose 'Day' up near the top, you can get one days usage and a good indication of the time of day that you used a lot of power.


My big power usage spike came after the peak period (green), so I paid the lowest price for it. Notice how I keep the green area (peak usage) as low as possible? That keeps my demand number down to save money. You can get to a specific day by using the little calendar symbol on the upper right.


Doing this will allow you to zero in on some usage period that may be giving you trouble. Fridays after work when you're hot and kick the AC on too early, or the day the kids were home and fooling with the thermostat come to mind. Little things like that can mess up the demand number and cause an unexpected large bill.

That's pretty much the guided tour of the APS app. It can tell you how well you did at controlling usage and help isolate troublesome events. What it doesn't tell you is how you are doing right now. You can't get the current day, or a close to real-time display to tell you something is on that shouldn't be. You can only look back.

My contention is that this nice display was designed to help the APS representative prove it was your fault you get a large unexpected bill. However, given enough time, you can use it to learn what hurts and what you can get away with; you just have to pay for the mistakes when they happen.

Previous post on this subject <link>  Next post on this subject <there isn't one yet>