![]() |
![]() |
#1 | ||
Apprentice EcoRenovator
Join Date: Jul 2014
Location: Finland
Posts: 125
Thanks: 5
Thanked 35 Times in 34 Posts
|
![]() At AC's request, here is a new thread about my controller project.
Copied from the "DIY Sous Vide Temperature controller" thread: Quote:
|
||
![]() |
![]() |
![]() |
#2 |
Apprentice EcoRenovator
Join Date: Jul 2014
Location: Finland
Posts: 125
Thanks: 5
Thanked 35 Times in 34 Posts
|
![]() I have made a start on the project, so this post is a description of what progress I have made so far. Let's start with the hardware.
The guts of the controller is an Arduino. I have bought a mega and an uno and I don't know yet which I will use. This is my first Arduino project so I am learning as I go. I will use 1-wire temperature sensors. Initially I have been testing with two of these, one for a freezer and one for a fridge. I bought a few more in case I think of other applications. For the internet access I will use an Ethernet shield. To switch on & off the power for the controlled device(s) I will use a relay board. I have boards with 2, 4 and 8 relays. They are all basically the same, so I can use any of them, depending on the number of devices I decide to control. To log temperatures and relay actions etc I will use the SD card on the Ethernet shield. To provide a user interface I will using an LCD display. I bought some that were originally intended for Nokia 5110 GSM phones. Not very fancy but workable and cheap. For configuration and a more sophisticated user interface I will create a web page for the controller which I can access with a browser. I have a real time clock board so the controller knows the time of day. I think that is about it for the hardware I have obtained so far. I would like to add hardware to measure the current used by the controlled device(s) but I have not given enough thought to that yet. The approach I am taking to the software is to split the task into smaller sub-tasks and test each of these individually. When I have proven each one I will combine them into a single sketch. So far what I have working is: Temperature reading with the 1-wire sensors. I can read the temperatures from multiple sensors on the same 1-wire bus. I can log the temperature settings (or anything else I guess) to a text file on the SD card. I will create a new file for each day. I haven't yet finalised the layout of the text file. I have tested output to the LCD. I have put the current temperature on a web page which I can view from any PC on my home LAN. (I have tested using a dynamic DNS service to make this data available over the internet, but I don't see any reason to do that in the final version). I have not yet tried any configuration settings via this web page. I am able to set the time of day on the real time clock by checking the time on an internet NTP server. I can find the UTC time and I can add an offset for my timezone, but there is one bit for which I don't yet have a solution. I don't know how the controller can discover whether summer time is in operation, so I could be an hour wrong with the time I set. I am able to switch relays on & off, with LEDs to indicate which relays are on. At the moment I am working on getting electricity price data from the internet at Market data | Nord Pool Spot As a native speaker of Pascal rather than C++ I have prototyped this using Delphi on a PC. I now have to port the code to C++ on the Arduino. The web page gives the bulk price of electricity on the spot market, in euro per mWh. My price per kWh is the bulk price plus a fixed markup. I could convert the published price to my price but I don't think I need to. I am interested in the relative price at different times of the day, not the absolute price, so I can use the raw published data and don't need to change anything if the markup ever changes. Summary: I think I am well on the way to understanding everything required for this project and I have proof-of-concept code for most of the individual elements of it. Soon I will start adding these building blocks together to create a full working controller. At that stage I can provide some photos and code. |
![]() |
![]() |
The Following User Says Thank You to SDMCF For This Useful Post: | AC_Hacker (10-07-14) |
![]() |
#3 |
Apprentice EcoRenovator
Join Date: Mar 2013
Location: UK
Posts: 131
Thanks: 13
Thanked 35 Times in 32 Posts
|
![]() This is the easiest method I've found for measuring power with arduino.
The library does all the measurements and calculations for you. CT sensors - Interfacing with an Arduino | OpenEnergyMonitor Steve |
![]() |
![]() |
![]() |
#4 |
Helper EcoRenovator
Join Date: Sep 2014
Location: Columbus, OH
Posts: 34
Thanks: 1
Thanked 5 Times in 5 Posts
|
![]() With all of the hardware you're running, make sure to consider where you are pulling power from. For example I don't think the arduino being powered via USB can provide enough power to drive one of the 8-channel relay boards through the 5v rail. If you consider the LCD, and Ethernet shield as well you would be better off using a standalone power supply to ensure you don't stress the on board regulator. I doubt you want to buy a new one 5 minutes after you get everything connected up.
|
![]() |
![]() |
![]() |
#5 |
Apprentice EcoRenovator
Join Date: Nov 2013
Location: Moore Oklahoma
Posts: 267
Thanks: 108
Thanked 23 Times in 21 Posts
|
![]() Does your energy provider offer any devices that will do this automatically? I have a Thermostat that talks to my power meter, when the rate changes I tell it how much less I want to run the AC. Best of all the thermostat was FREE (including installation) for signing up for the variable price plan.
OGE: SmartHours Carrier ComfortChoice |
![]() |
![]() |
![]() |
#6 |
Apprentice EcoRenovator
Join Date: Jul 2014
Location: Finland
Posts: 125
Thanks: 5
Thanked 35 Times in 34 Posts
|
![]() @Ormston: Many thanks for that. I hadn't seen it before. I will study it. I had been thinking of something like that or alternatively something like this. The ready-made library for the approach you suggest is a big bonus though so I will probably go that way.
@bmxeroh: Good point. I was aware of this and I have a suitable power supply for both the Arduino and seperately for the relay board, plus a step down from 5V to 3,3V to suit the LCD. In operation the controller doesn't use USB power at all, and is only connected to a PC for development. @Servicetech: No, our energy provide doesn't provide anything like that, unfortunately. It sounds like your provider is more switched on (pardon the pun) and your meter is more sophisticated. Our meter doesn't know the rate so I have to get that data from the internet. How do you tell your device how much you want to run the AC? Is that a manual process or programmable? How often does your rate change? |
![]() |
![]() |
![]() |
#7 |
Apprentice EcoRenovator
Join Date: Mar 2013
Location: UK
Posts: 131
Thanks: 13
Thanked 35 Times in 32 Posts
|
![]() SDMCF
You could use the bi directional version Pololu - ACS714 Current Sensor Carrier -30A to +30A as I'm assuming it's AC you need to measure and control. This could be used with open energy's library. Hookup should be identical to using a CT and change the calibration value to suit 30A sensor instead of 100A Steve |
![]() |
![]() |
![]() |
#8 |
Apprentice EcoRenovator
Join Date: Jul 2014
Location: Finland
Posts: 125
Thanks: 5
Thanked 35 Times in 34 Posts
|
![]() OK, That makes sense. Thanks for the tip.
|
![]() |
![]() |
![]() |
#9 | |
Master EcoRenovator
Join Date: Aug 2012
Location: Toronto
Posts: 958
Thanks: 40
Thanked 158 Times in 150 Posts
|
![]() Quote:
|
|
![]() |
![]() |
![]() |
#10 | |
Apprentice EcoRenovator
Join Date: Nov 2013
Location: Moore Oklahoma
Posts: 267
Thanks: 108
Thanked 23 Times in 21 Posts
|
![]() Quote:
See Smarthours link posted about for how the rate changes. It increases from 2-7pm weekdays during the summer. The thermostat is programmed to go up 0-10 degrees for each rate increase. I have my thermostat set at 75f for 6 cents, 77f for 10 cents, 79f for 19 cents, 85f for 43 cents. Rate response completely consumer adjustable. Last edited by Servicetech; 10-08-14 at 06:07 AM.. |
|
![]() |
![]() |
![]() |
|
|