1. Welcome Hearth.com Guests and Visitors - Please enjoy our forums!
    Hearth.com GOLD Sponsors who help bring the site content to you:
    Hearthstone Soapstone and Cast-Iron stoves( Wood, Gas or Pellet Stoves and Inserts)
    Caluwe - Passion for Fire and Water ( Pellet and Wood Hydronic and Space Heating)
Thread Status:
Not open for further replies.
  1. in hot water

    in hot water New Member

    Joined:
    Jul 31, 2008
    Messages:
    895
    Loc:
    SW Missouri
    this is the data logger that comes with the solar control I showed in another post. Plug it into a USB port and slip the SD card into it. Now you can program the control parameters. Then take the card to the control, plug it in and it transfer the set up data. The control does come pre-programed with 5 or so arrangements. You cannot build new arr. but you can change setting within them.

    Then the card records the system data as it runs. Here are a couple screen shots of the set up screen and the view screen. When you put the cursor over any point on any line it reads the temperature and time of day.

    This control also accepts input from the Grundfos flow and temperature sensors.

    I know the manufacturer of this control and have been testing a few versions for them. They are looking for dealers or distributors. I suspect street price could be under $300 depending on dealer markup.

    Attached Files:

    Helpful Sponsor Ads!





  2. Nofossil

    Nofossil Moderator Emeritus

    Joined:
    Oct 4, 2007
    Messages:
    3,398
    Loc:
    Addison County, Vermont
    Cool. Memory has gotten cheap. I use a 2GB SD card in the NoFossil Control System. It records all inputs, outputs, and internal variables every minute for a whole year. Then it rolls over and starts overwriting the previous year's data a day at a time so that you always have the previous 365 days worth. Pretty amazing for a $10 card.
  3. Gooserider

    Gooserider Mod Emeritus

    Joined:
    Nov 20, 2006
    Messages:
    6,737
    Loc:
    Northeastern MA (near Lowell)
    Looks like a nice unit - is the software on it cross platform capable, or are customers going to have to run a [del]Microsoft[/del] defective box just to make use of it?

    (I get annoyed by all the manufacturer supplied software out there that won't run right on my Linux box - I really don't like running virused malware systems)

    Gooserider
  4. in hot water

    in hot water New Member

    Joined:
    Jul 31, 2008
    Messages:
    895
    Loc:
    SW Missouri
    I will find out. It runs on my mac but I have the Parallels software.
  5. jebatty

    jebatty Minister of Fire

    Joined:
    Jan 1, 2008
    Messages:
    4,321
    Loc:
    Northern MN
    Anyone with experience as to this data logger?
    Pico USB TC-08 8-Channel Thermocouple Data Logger
    Pico
  6. twofer

    twofer New Member

    Joined:
    Jun 4, 2008
    Messages:
    91
    Loc:
    SLP Michigan
    Not sure how much experience you have with computers/programming but for ~$105 you could get:

    1 - Arduino Board
    1 - Arduino Ethernet Shield
    8 - OneWire Temperature Sensors

    This setup like that Pico would require a computer except if you went the Arduino route you would could just setup a PHP script to pipe the readings into a MySQL database. Another benefit of going with the Arduino is that you have 16 digital pins that would allow you the ability to control your system in the future.
  7. jebatty

    jebatty Minister of Fire

    Joined:
    Jan 1, 2008
    Messages:
    4,321
    Loc:
    Northern MN
    Years ago I did quite a bit of programming, so maybe it's time to start again. Thanks for the info.
  8. jebatty

    jebatty Minister of Fire

    Joined:
    Jan 1, 2008
    Messages:
    4,321
    Loc:
    Northern MN
    If I go the Arduino route, is there a shield to record data rather than using a computer, and then downloading to the computer? I'm really new at the jargon for this, but I think you get the drift: an Arduino with a data logger.
  9. twofer

    twofer New Member

    Joined:
    Jun 4, 2008
    Messages:
    91
    Loc:
    SLP Michigan
    They have shields with SD card interfaces on them but you're still going to need a program to view the data (i.e. write to CSV file and graph/view it with Excel).

    Personally, if you have a computer in your home that is always on already then I would go the ethernet shield route. The reason being that the data is automatically logged and if you want to view it you could just fire up a web browser and have JPGraph & PHP graph the results.

    Next month I'll be working on setting up my Arduino controller with an ethernet shield and the corresponding MySQL database and webserver so if you need any help I'll be more than happy to share my code and database.
  10. ISeeDeadBTUs

    ISeeDeadBTUs Guest

    True True
  11. Blevesque

    Blevesque Member

    Joined:
    Oct 17, 2008
    Messages:
    149
    Loc:
    Maine
    Twofer, I was just wondering if you were going to do a detailed write-up of your control system. It's a slick system and I love to learn more about it.
  12. twofer

    twofer New Member

    Joined:
    Jun 4, 2008
    Messages:
    91
    Loc:
    SLP Michigan
    It's nothing fancy but here is the thread about my control system. If there's any details missing that you're interested in feel free to ask.

    http://www.hearth.com/econtent/index.php/forums/viewthread/44038/
  13. jebatty

    jebatty Minister of Fire

    Joined:
    Jan 1, 2008
    Messages:
    4,321
    Loc:
    Northern MN
    I'm thinking of excuses in addition to boiler monitor/control to get an Arduino, etc. and learn the programming. After reviewing some sample sketches, the language structure is very similar to dBase programming I did years ago, so it shouldn't be too difficult to learn. So, what other "useful" uses to do with Arduino -- maybe a robot to split and stack boiler wood?
  14. mwk1000

    mwk1000 Member

    Joined:
    Nov 12, 2008
    Messages:
    152
    Loc:
    Southern MI
    go to sparkfun.com and look down the list of sensors. That should give you an idea or two.

    I am also ready to hook up my arduino board. I have it working with 4 sensors and one relay on a prototype board now. I have been building out the mysql code and the graphing portion. I am using an opens ource tool called pentaho, it's way overkill for this but we develop with it for work so I am getting up to speed and making something for the house. If you strip away all the junk I would point some of the members here to the openflashchart php modules. VERY clean charts for that sexy professional look.

    I can post any of the stuff out here as well. I am using a perl script I wrote years ago to log tty data , it is in production at many companies for years , very reliable code. The arduino sends out formatted lines that are simple to parse and I have decided to update the ttylogger to convert the formatted lines to sql inset statements written to a file every 1-5 min. Very simple and requires no special modules to work, all you need is the basic perl and mysql. I'll have the script make the insert file and run it to load in the data.

    It's about 3/4 baked right now. I have a sample database schema called temperature with about 5 or 6 tables. The ttylog code is done about another hour to add in the SQL statements. Pentaho is up and a VERY simple dashboard is drawing a graph against the "RAW" temperature table. I was looking to wire it in this weekend and start logging real temps.

    It's a nice project I have been itching to do and I'm having fun with it !
  15. jebatty

    jebatty Minister of Fire

    Joined:
    Jan 1, 2008
    Messages:
    4,321
    Loc:
    Northern MN
    You're much more advanced in programming than I am. I have a "goals" list that is designed in part to cover my aging process. Although I'm only 62, I know the time will come when scaling Mt Everest no longer will be achievable, so I have on my list re-learning programming. C++ was the language at the time I did the goals list, but when the time arrives, who knows? Maybe start now with the Arduino and get a jump start on future dementia, although my wife thinks I'm demented already.
  16. twofer

    twofer New Member

    Joined:
    Jun 4, 2008
    Messages:
    91
    Loc:
    SLP Michigan
    The last couple days have had me thinking about how it might be a worthwhile project for one of us to setup a database and webserver that could do the logging and graphing for people. This way those that are not familiar or comfortable working with PHP/MySQL could just setup the Arduino to send the sensor data there. This would also eliminate the need for everyone to maintain a local webserver, not that it is hard to do with XAMPP.

    What do you guys think?

    ETA: The one hurdle would be the authentication of the incoming data from the Arduino's but I think this could be overcome with a lightweight AES implementation.
  17. Medman

    Medman Feeling the Heat

    Joined:
    Jul 8, 2008
    Messages:
    425
    Loc:
    Sault Ste. Marie, Ontario
    I would agree that a "readymade" setup for the code, with simple and clear instructions, would be excellent. I am very comfortable and competent when it comes to the hardware of boards, sensors, interfaces etc. but I have not coded for years. Any help you could provide would be worthwhile.
    Some thoughts I had:

    Any needed applications should be open source and free, available as a download.

    Most of us can find a PC or two (I have two now) to reformat and load with just the setup needed to make this run. What are the bare necessities for applications required? Which OS?

    In my case, I would like to have the arduino controller run independently of a PC, with only the data logging and conversion functions running on the PC.
  18. Medman

    Medman Feeling the Heat

    Joined:
    Jul 8, 2008
    Messages:
    425
    Loc:
    Sault Ste. Marie, Ontario
    Additionally, which make/version of Linux will be best for someone like me who is new to the OS? I want to get at least one PC reformatted and running soon, as I have ordered the arduino board and sensors.
  19. mwk1000

    mwk1000 Member

    Joined:
    Nov 12, 2008
    Messages:
    152
    Loc:
    Southern MI
    JeBatty: Maybe this will work:

    Little boy, I have some candy for you ... A nice little arduino sketch that reads temperature sensors and turns on relays ....


    Code:
    #include <OneWire.h>
    #include <DallasTemperature.h>
    
    // Data wire is plugged into port 2 on the Arduino
    #define ONE_WIRE_BUS 2
    #define TEMPERATURE_PRECISION 9
    
    // Setup a oneWire instance to communicate with any OneWire devices (not just Maxim/Dallas temperature ICs)
    OneWire oneWire(ONE_WIRE_BUS);
    
    // Pass our oneWire reference to Dallas Temperature. 
    DallasTemperature sensors(&oneWire;);
    
    // arrays to hold device addresses
    uint8_t SourceFeedSen[8], SourceReturnSen[8];
    uint8_t LoadFeedSen[8], LoadReturnSen[8];
    uint8_t StoreMaxSen[8], StoreMinSen[8];
    uint8_t TempSen1[8], TempSen2[8];
    
    // Try for an array of pointers to the arrays so wa can process them in for loops
    uint8_t *SensorList[6];
    
    // Save the Relay pin setup
    
    int relay1Pin = 7;
    int relay1State = LOW;
    int lastrelay1State = LOW;
    
    
    // Counter in Seconds
    long relay1Sec = 0;
    
    // Relay/Pump will not cycle more than once every xx seconds
    long resetinterval = 180;
    long collectinterval = 60000; // get temps every nn000 milliseconds
    
    // Set up some default temperature variables
    
    float DeltaTdropF = 5; // Buffer temp for comparisons
    float FloorTempF = 120;
    float SenAdj = 4;
    
    
    // Setup some handy temp variables
    // Farenhieght
    float SourceFeedTempF, SourceReturnTempF, LastSourceFeedTempF, LastSourceReturnTempF;
    float LoadFeedTempF,  LoadReturnTempF, LastLoadFeedTempF,  LastLoadReturnTempF;
    float StoreMaxTempF,  StoreMinTempF, LastStoreMaxTempF,  LastStoreMinTempF;
    
    
    // Set up some handy loop counters and general variables.
    float ver = 2.0;
    int j,k;
    int sennum;
    
    // Some format flags to control what prints
    int logSourceFeed = HIGH;
    int logSourceReturn = HIGH;
    int logLoadFeed = HIGH;
    int logLoadReturn = HIGH;
    int logStoreMax = LOW;
    int logStoreMin = LOW;
    
    void setup(void)
    {
      // Fill in sensor list with named var addresses
      SensorList[0] = SourceFeedSen;
      SensorList[1] = SourceReturnSen;
      SensorList[2] = LoadFeedSen;
      SensorList[3] = LoadReturnSen;
      SensorList[4] = StoreMaxSen;
      SensorList[5] = StoreMinSen;
      
      // start serial port
      Serial.begin(115200);
      Serial.println(" ");
      delay(15000);
      Serial.print("Gassification Bioler Temperature IC Control Version ");
      Serial.println(ver);
     
      // initialize the relay digital pin as an output:
      pinMode(relay1Pin, OUTPUT);     
      pinMode(ONE_WIRE_BUS, INPUT);
      // Start up the library
      sensors.begin();
      
      // locate devices on the bus
      Serial.print("Locating devices...");
      Serial.print("Found ");
      sennum = sensors.getDeviceCount();
      Serial.print(sennum, DEC);
      Serial.println(" devices.");
      delay(5000);
      // report parasite power requirements
      Serial.print("Parasite power is: "); 
      if (sensors.isParasitePowerMode()) Serial.println("ON");
      else Serial.println("OFF");
       
      // assign address manually.  
      
      SourceFeedSen = { 0x28, 0x54, 0xD6, 0x5E, 0x2, 0x0, 0x0, 0xAC };
      SourceReturnSen   = { 0x28, 0x7C, 0x2, 0x5F, 0x2, 0x0, 0x0, 0x75 };
      LoadFeedSen = { 0x28, 0xC9, 0xD6, 0x5E, 0x2, 0x0, 0x0, 0x57 };
      LoadReturnSen   = { 0x28, 0xF9, 0xCB, 0x5E, 0x2, 0x0, 0x0, 0x2A }; 
        
      // set the resolution to 9 bit
      for ( j = 0; j < sennum; j++)
      {
        sensors.setResolution(SensorList[j], 9);
      }
     
      // Make sure we are starting with relay off  
      digitalWrite(relay1Pin, LOW);    // set the Relay off
      // Initialize the state vars
      lastrelay1State = LOW; 
      relay1State = LOW;
      relay1Sec = millis()/1000; // Set the initial relay last switched time to the startup time 
    }
    
    // function to print a device address
    void printAddress(uint8_t deviceAddress[])
    {
      for (uint8_t i = 0; i < 8; i++)
      {
        Serial.print(deviceAddress[i], HEX);
        if (i < 7) Serial.print(" ");
      }
    }
    
    // function to print the temperature for a device
    void printTemperature(uint8_t deviceAddress[])
    {
      // method 2 - faster
      float tempC = sensors.getTempC(deviceAddress);
      Serial.print("Temp C: ");
      Serial.print(tempC);
      Serial.print(" Temp F: ");
      Serial.print(DallasTemperature::toFahrenheit(tempC));
    }
    
    // function to print a device's resolution
    void printResolution(uint8_t deviceAddress[])
    {
      Serial.print("Resolution: ");
      Serial.print(sensors.getResolution(deviceAddress));
      Serial.println();    
    }
    
    // main function to print information about a device
    void printData(uint8_t deviceAddress[])
    {
      Serial.print("Device Address: ");
      printAddress(deviceAddress);
      Serial.print(" ");
      printTemperature(deviceAddress);
      Serial.println();
    }
    
  20. mwk1000

    mwk1000 Member

    Joined:
    Nov 12, 2008
    Messages:
    152
    Loc:
    Southern MI
    The rest ...

    Code:
    void loop(void)
    { 
      // call sensors.requestTemperatures() to issue a global temperature 
         sensors.requestTemperatures();
     
      // print the device information
      for ( j = 0; j < sennum; j++)
      {
        printData(SensorList[j]);
      }
    
    // Ok now actually do something to control the EKO
    // Fill in my vars for easy reading
      
     SourceFeedTempF = sensors.getTempF(SourceFeedSen);
     SourceReturnTempF = sensors.getTempF(SourceReturnSen);
     
     LoadFeedTempF = sensors.getTempF(LoadFeedSen);
     LoadReturnTempF = sensors.getTempF(LoadReturnSen);
     
     StoreMaxTempF = sensors.getTempF(StoreMaxSen);
     StoreMinTempF = sensors.getTempF(StoreMinSen);
    
     // Save the state before the Checking starts
     lastrelay1State = relay1State;
     
    // if ( (SourceFeedTempF + DeltaTdropF) > LoadFeedTempF )
    if ( (SourceFeedTempF ) > LoadFeedTempF + DeltaTdropF )
     { // Turn on Tank pump flag
       relay1State = HIGH;
     } else 
     { // Turn off Tank pump flag
       relay1State = LOW;
     }
     if ( SourceReturnTempF <= FloorTempF )
     {
       relay1State = LOW;
     }
     
     // Now set the relay -- After all the logic so we only turn on/off once 
     
     if (((millis()/1000) - relay1Sec > resetinterval) && ( relay1State == HIGH ) && ( lastrelay1State != relay1State ))
     {
       Serial.print("Setting Relay pin HIGH Run Sec: ");
       Serial.println((millis()/1000)- relay1Sec,DEC);
       digitalWrite(relay1Pin, HIGH);   // set the Relay on
       relay1Sec = millis()/1000; // Using seconds to store longer interval 10-12 hour run times
     } else if (( relay1State == LOW ) && ( lastrelay1State != relay1State ))
     {
        Serial.print("Setting Relay pin LOW Run Sec: ");
        Serial.println((millis()/1000)- relay1Sec,DEC);
        digitalWrite(relay1Pin, LOW);    // set the Relay off
        relay1Sec = millis()/1000; // Using seconds to store longer interval 10-12 hour run times
     }
     
    // Store the values for the next run
    LastSourceFeedTempF = SourceFeedTempF; LastSourceReturnTempF = SourceReturnTempF;
    
    LastLoadFeedTempF = LoadFeedTempF; LastLoadReturnTempF = LoadReturnTempF;
    
    LastStoreMaxTempF = StoreMaxTempF; LastStoreMinTempF = StoreMinTempF;
    
    if ( logSourceFeed == HIGH )
    {  // create an EASY to parse line for database inserts
       Serial.print("log:SourceFeed:F:");
       Serial.println(SourceFeedTempF );
    }
     // Don't loop like crazy the Temps rise and fall SLOW !
     delay(collectinterval);
      
    } // End of main loop
    
    
    
  21. mwk1000

    mwk1000 Member

    Joined:
    Nov 12, 2008
    Messages:
    152
    Loc:
    Southern MI
    Last, A picture of the test setup.
    That should kick start anyone wanting to try this. The program and wiring in the picture are all working.
    ( My son and I did the picture to take to school )

    Note on the code: I hacked up a lot of the code originally to get the size down to a postable size --it didn't work. If someone wants to share how to post the text files ( I was rejected ) I will gladly put up the original and the ttylog script as well. The sketch IS functional, I removed comments, duplicate sections for each sensor etc.

    Attached Files:

  22. twofer

    twofer New Member

    Joined:
    Jun 4, 2008
    Messages:
    91
    Loc:
    SLP Michigan
    Maybe we should pull this discussion into a dedicated Arduino thread.
  23. DaveBP

    DaveBP Minister of Fire

    Joined:
    May 25, 2008
    Messages:
    1,054
    Loc:
    SW Maine
    Why do that? I can't be the only one to enjoy listening to conversations in languages I don't speak a word of. It's just fun imagining what you might be saying!
  24. jebatty

    jebatty Minister of Fire

    Joined:
    Jan 1, 2008
    Messages:
    4,321
    Loc:
    Northern MN
    MWK -- Thanks, much -- I'm not moving too fast on anything right now except completing some doll wardrobe cabinets for two of my granddaughters. But I'm starting to get myself intrigued by something that likely will turn into lots of fun, plus soak up my winter time in the frozen north country. Thanks again.
  25. pybyr

    pybyr Minister of Fire

    Joined:
    Jun 3, 2008
    Messages:
    2,301
    Loc:
    Adamant, VT 05640
    I am far from a Linux guru, and do not know if the following will work for the purpose being discussed, but I've had a little experience with a version known as "Ubuntu"- which has the dual advantages of being available at no charge, and also being usable by way of a graphical user interface (click on icons, etc.) for those of us who aren't I.T. whizzes. Google around and you can probably find more about it quickly.
Thread Status:
Not open for further replies.

Share This Page