vmax5000 Posted April 16, 2010 Share Posted April 16, 2010 I have programmed a schedule to turn on the bedroom pot lights when it's time to get up for work, but the schedule only allows for daily, weekly etc. It would be nice to have a list of all the holidays and then say weekly except for this/these holidays. Link to comment Share on other sites More sharing options...
ILoveC4 Posted April 16, 2010 Share Posted April 16, 2010 Create boolean variable, and have the action take place if the variable is true. On the days you don't want it to turn on the next morning, use a keypad to toggle the variable farse.Everyday at 10AM, automatically program the system to set the variable back to true so it will execute the next day.I don't see them compiling and maintaining a list of state (there are 50 of them after all) and national holidays. Link to comment Share on other sites More sharing options...
GoGo Delicious Posted April 16, 2010 Share Posted April 16, 2010 I am not a C4 programmer but if C4 support text files, hex, and parsing this should be easy to do. I created a "Holiday" solution for Crestron using the following. Again C4 must be able to read and parse a text file.1) I hard coded all the Holidays that are always on the same date since they never change. Example New Years, Christmas, Independence Day, etc.2) For the Holidays that have variable dates, such as Thanksgiving, Easter, Labor Day, etc. I created program that parses the data in the .ics file and saves it to a text file so it's readable by the Crestron processor. Below is the actual text from a "Holiday" .ics file from iCal.BEGIN:VCALENDARMETHOD:PUBLISHVERSION:2.0X-WR-CALNAME:US HolidaysPRODID:-//Apple Inc.//iCal 4.0.2//ENX-APPLE-CALENDAR-COLOR:#492BA1X-WR-TIMEZONE:America/Los_AngelesCALSCALE:GREGORIANBEGIN:VEVENTCREATED:20090721T010305ZUID:224FF2DF-00F8-4132-95FF-D780C0686A5FDTEND;VALUE=DATE:20091225RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=12TRANSP:OPAQUESUMMARY:ChristmasDTSTART;VALUE=DATE:20091225DTSTAMP:20090803T233541ZSEQUENCE:5END:VEVENTBEGIN:VEVENTCREATED:20090803T234608ZUID:4162B846-C557-48FD-B635-E70EED88243BDTEND;VALUE=DATE:20100705TRANSP:TRANSPARENTSUMMARY:Independence Day (observed)DTSTART;VALUE=DATE:20100704DTSTAMP:20090803T234625ZSEQUENCE:3END:VEVENTBEGIN:VEVENTCREATED:20090721T010305ZUID:B082D697-41C2-4B14-B167-00B0497FF2D9DTEND;VALUE=DATE:20090214RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=2TRANSP:OPAQUESUMMARY:Valentine's DayDTSTART;VALUE=DATE:20090214DTSTAMP:20090721T160548ZSEQUENCE:1END:VEVENTBEGIN:VEVENTCREATED:20090721T010305ZUID:7B16E9B7-22B1-43C3-ABE2-88F29ED00000DTEND;VALUE=DATE:20091126RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=11;BYDAY=4THTRANSP:OPAQUESUMMARY:ThanksgivingDTSTART;VALUE=DATE:20091126DTSTAMP:20090803T233519ZSEQUENCE:7END:VEVENTBasically I tell Crestron to do the following. (NOTE this is not Crestron programming. I am simplifying it so the basics are understood by all. If I explained it as a Crestron programmer 1, no one would understand it and 2, most importantly, no one would care)Start at the First Instance of "BEGIN:VEvent"Get first STRING after "DTEND;VALUE=DATE" and holdGet the first STRING after SUMMARY: and holdGet the first STRING after "DTSTART;VALUE=DATE:" and holdAt FIRST Instance if "END:VEVENT" parse and write data. At this point I tell Crestron to add dashes and commas.Lets look at Thanksgiving. Parsing Thanksgiving I would end up with the following in a text file.2009-11-26,Thanksgiving,2009-11-26I now have a clean text file that I can parse even further if need be, have a Crestron Serial I/O read it, run it through other Serial logic, etc.Using hex I can even break down, rearrange or extract from the line "2009-11-26,Thanksgiving,2009-11-26" in the text file using something like 012Ch - 23. What does this give me? The word "Thanksgiving". Breaking down 012Ch - 12 I am stating the following; Start at the First Instance(01) of a Comma(2C) using HEX(h) and take up to the 23rd character.To write the whole program took me about 15-20min, and it takes the processor < a second to process the file and send the data to a text file that my Simpl program looks for. As far state holidays, personal vacations, non U.S. holidays, etc, I wrote the program so a client can enter dates and holidays manually from the touch panel.Again if C4 supports the parsing of text files and hex then an automated Holiday calendar can be created. If you have a deep understanding of parsing and hex it should take you no more than 20min. If you don't then it can take days. Link to comment Share on other sites More sharing options...
ILoveC4 Posted April 16, 2010 Share Posted April 16, 2010 I am not a C4 programmer but if C4 support text files, hex, and parsing this should be easy to do. I created a "Holiday" solution for Crestron using the following. Again C4 must be able to read and parse a text file.1) I hard coded all the Holidays that are always on the same date since they never change. Example New Years, Christmas, Independence Day, etc.2) For the Holidays that have variable dates, such as Thanksgiving, Easter, Labor Day, etc. I created program that parses the data in the .ics file and saves it to a text file so it's readable by the Crestron processor. Below is the actual text from a "Holiday" .ics file from iCal.BEGIN:VCALENDARMETHOD:PUBLISHVERSION:2.0X-WR-CALNAME:US HolidaysPRODID:-//Apple Inc.//iCal 4.0.2//ENX-APPLE-CALENDAR-COLOR:#492BA1X-WR-TIMEZONE:America/Los_AngelesCALSCALE:GREGORIANBEGIN:VEVENTCREATED:20090721T010305ZUID:224FF2DF-00F8-4132-95FF-D780C0686A5FDTEND;VALUE=DATE:20091225RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=12TRANSP:OPAQUESUMMARY:ChristmasDTSTART;VALUE=DATE:20091225DTSTAMP:20090803T233541ZSEQUENCE:5END:VEVENTBEGIN:VEVENTCREATED:20090803T234608ZUID:4162B846-C557-48FD-B635-E70EED88243BDTEND;VALUE=DATE:20100705TRANSP:TRANSPARENTSUMMARY:Independence Day (observed)DTSTART;VALUE=DATE:20100704DTSTAMP:20090803T234625ZSEQUENCE:3END:VEVENTBEGIN:VEVENTCREATED:20090721T010305ZUID:B082D697-41C2-4B14-B167-00B0497FF2D9DTEND;VALUE=DATE:20090214RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=2TRANSP:OPAQUESUMMARY:Valentine's DayDTSTART;VALUE=DATE:20090214DTSTAMP:20090721T160548ZSEQUENCE:1END:VEVENTBEGIN:VEVENTCREATED:20090721T010305ZUID:7B16E9B7-22B1-43C3-ABE2-88F29ED00000DTEND;VALUE=DATE:20091126RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=11;BYDAY=4THTRANSP:OPAQUESUMMARY:ThanksgivingDTSTART;VALUE=DATE:20091126DTSTAMP:20090803T233519ZSEQUENCE:7END:VEVENTBasically I tell Crestron to do the following. (NOTE this is not Crestron programming. I am simplifying it so the basics are understood by all. If I explained it as a Crestron programmer 1, no one would understand it and 2, most importantly, no one would care)Start at the First Instance of "BEGIN:VEvent"Get first STRING after "DTEND;VALUE=DATE" and holdGet the first STRING after SUMMARY: and holdGet the first STRING after "DTSTART;VALUE=DATE:" and holdAt FIRST Instance if "END:VEVENT" parse and write data. At this point I tell Crestron to add dashes and commas.Lets look at Thanksgiving. Parsing Thanksgiving I would end up with the following in a text file.2009-11-26,Thanksgiving,2009-11-26I now have a clean text file that I can parse even further if need be, have a Crestron Serial I/O read it, run it through other Serial logic, etc.Using hex I can even break down, rearrange or extract from the line "2009-11-26,Thanksgiving,2009-11-26" in the text file using something like 012Ch - 23. What does this give me? The word "Thanksgiving". Breaking down 012Ch - 12 I am stating the following; Start at the First Instance(01) of a Comma(2C) using HEX(h) and take up to the 23rd character.To write the whole program took me about 15-20min, and it takes the processor < a second to process the file and send the data to a text file that my Simpl program looks for. As far state holidays, personal vacations, non U.S. holidays, etc, I wrote the program so a client can enter dates and holidays manually from the touch panel.Again if C4 supports the parsing of text files and hex then an automated Holiday calendar can be created. If you deep understanding of parsing and hex it should take you no more than 20min. If you don't then it can take days.I like my method better You don't have to be a programmer to do it, and you can easily set it for days that aren't Holidays, but that you may not want the lights to turn on. Oh yeah, and mine takes about 45 seconds if you're good, and about 10 minutes if you have to figure it out and have never done it before.Thanks for the rundown though... Link to comment Share on other sites More sharing options...
GoGo Delicious Posted April 16, 2010 Share Posted April 16, 2010 I like my method better You don't have to be a programmer to do it, and you can easily set it for days that aren't Holidays, but that you may not want the lights to turn on. Oh yeah, and mine takes about 45 seconds if you're good, and about 10 minutes if you have to figure it out and have never done it before.Thanks for the rundown though...I think your missing the point of automation. A person should not have to remember to "press a button" the system should do what the client wants it to do automatically.My solution requires no end user intervention at all. Once it's incorporated into the program it is set and will update itself automatically. If I'm a client and I am spending upwards of $15K on a home automation system and I ask for a Holiday schedule I better get one. I would hate to have a dealer tell me "well if you want to go into Holiday mode, you will have to remember when the holidays are and make sure you press this button the night before every time." A client should never have to do that. The automation system needs takes care of it without any client intervention. Link to comment Share on other sites More sharing options...
ILoveC4 Posted April 16, 2010 Share Posted April 16, 2010 I am a client, and I have invested more than $15k in home automation.We all have our own wants and needs, I was just telling the guy how to easily create a wake up that he can turn on and off with ease.I personally wouldn't want a certain thing to not take place every holiday, but that's just me I guess.Oh well...rock on. Link to comment Share on other sites More sharing options...
vmax5000 Posted April 16, 2010 Author Share Posted April 16, 2010 Wow, thanks for the feedback everyone! It's nice to have an answer in such a short time frame, I think I'm really going to like my shiny new Control 4 system!Thanks again..Randy Link to comment Share on other sites More sharing options...
vmax5000 Posted April 16, 2010 Author Share Posted April 16, 2010 I kind of have to agree with GoGo Delicious about having it automated, if you think about it they are able to get the constantly changing time of dusk from the internet, so shouldn't they be able to get the holiday list from the internet as well? I'm not a programmer, but I didn't think it would be that hard to get the information from the net and then just add a tab to the current scheduler.Oh well, maybe it's harder that that...Randy Link to comment Share on other sites More sharing options...
RyanE Posted April 17, 2010 Share Posted April 17, 2010 Astronomical time is *not* pulled from the internet.Once you have latitude and longitude, it is calculated.That said, someone could *certainly* write a DriverWorks driver that could set a variable if it was a holiday and clear it if it was not. It would just take a reliable source for the holiday data, and some programming.I'm not volunteering.RyanE Link to comment Share on other sites More sharing options...
EagleMoon Posted April 18, 2010 Share Posted April 18, 2010 First, I agree that the system should know holidays.That said, someone could *certainly* write a DriverWorks driver that could set a variable if it was a holiday and clear it if it was not. It would just take a reliable source for the holiday data, and some programming.Second, this sounds like the kind of fun stuff I'd like to do when I "give up my day job" this December. However, I'm not a dealer, won't be living in a city large enough to support dealer sales requirements, wouldn't want a full-time job or even much of a part-time job anyway, so what are my options for that -- convince my dealer to "hire" me as a non-paid employee so I can have access to the tools I would need? Link to comment Share on other sites More sharing options...
RyanE Posted April 18, 2010 Share Posted April 18, 2010 Making a deal like that with a dealer could work well for the both of you.RyanE Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.