Results 1 to 10 of 10

Thread: logging data to note pad?

  1. #1
    Join Date
    Apr 2003
    Location
    Florida
    Posts
    44

    Default logging data to note pad?

    This should be easy but I cant seem to find any info on it. I want to log the on/off data of a joystick "switch" to note pad with time/date also.
    What I am trying to do is see how long my hot water heater runs before I install a solar preheater, "so I can tell any change in energy usage" I plan to just use a 220 volt relay hooked to a joystick switch to input the on/off state of the water heater I can handle that part , it's just getting the data logged in some way that I'm lost.
    Thanks for any help

  2. #2
    Join Date
    Dec 2001
    Posts
    11,560

    Default

    Why not just use the logger plugin?

    Or just use lua to open a file and write events out to it.

  3. #3
    Join Date
    Apr 2003
    Location
    Florida
    Posts
    44

    Default

    the logger does work, and I can just copy and paste the results in a spread sheet. could you tell me how to write the datato a file like a txt or xls with lua? at least a starting point I dont expect you to do all the work for me

  4. #4
    Join Date
    Sep 2002
    Location
    Davis, CA, USA
    Posts
    382

    Default

    www.inf.puc-rio.br/~roberto/luabook1.pdf is a good resource.

    It includes a chapter on reading/writing files.
    Jim Hughes

  5. #5
    Join Date
    Dec 2001
    Posts
    11,560

    Default

    Think Jim.

    You also could use the FileSystemObject - link is in the luacom thread.

  6. #6
    Join Date
    Apr 2003
    Location
    Florida
    Posts
    44

    Default

    wow, thats a little deep, lol. I think I'll just copy and paste for now till I learn a little more about lua.

  7. #7
    Join Date
    Apr 2003
    Location
    Florida
    Posts
    44

    Default

    Well its all up and running, pretty cool I found the heater runs for about 4 mins just from washing your hands with hot water, lol I would like to know if the date format in the logger can be changed to xx/xx/xx for use in excel?

  8. #8
    Join Date
    Dec 2001
    Posts
    11,560

    Default

    It probably could be but our main priority is work on G4 right now.

  9. #9
    Join Date
    Apr 2003
    Location
    Florida
    Posts
    44

  10. #10
    Join Date
    Dec 2001
    Posts
    11,560

    Default

    Girder 4

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •