Active TopicsActive Topics  Display List of Forum MembersMemberlist  Search The ForumSearch  HelpHelp
  RegisterRegister  LoginLogin
PowerHome Programming
 PowerHome Messageboard : PowerHome Programming
Subject Topic: Remote CC and ph_ccmodify Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
jbbtex
Senior Member
Senior Member


Joined: February 15 2007
Location: United States
Online Status: Offline
Posts: 181
Posted: August 13 2007 at 14:47 | IP Logged Quote jbbtex

Does ph_ccmodify work with Remote CC and if not is there a way to do this

ph_ccmodify(1,'pbtn_daynight.filename="C:~\Program Files~\powerhome~\web~\graphics~\buttons~\b10black_100.gif"' )

to change the Remote CC?
Back to Top View jbbtex's Profile Search for other posts by jbbtex
 
dhoward
Admin Group
Admin Group
Avatar

Joined: June 29 2001
Location: United States
Online Status: Offline
Posts: 4447
Posted: August 14 2007 at 16:37 | IP Logged Quote dhoward

jbbtex,

Unfortunately, ph_ccmodify commands will not directly update Remote CC clients . You could do the ph_ccmodify, but the remote cc would only update the change if the remote CC was refreshed. You could simulate this command using the ph_sendudp function, but that would cause an annoying flicker and screen refresh in the remote CC.

However, I'll go ahead and add a couple of new ph_setccobj and ph_getccobj functions that will allow you to manipulate the graphic files associated with a CC object and this will get updated automatically on remote CC's.

Dave.
Back to Top View dhoward's Profile Search for other posts by dhoward Visit dhoward's Homepage
 
jbbtex
Senior Member
Senior Member


Joined: February 15 2007
Location: United States
Online Status: Offline
Posts: 181
Posted: August 14 2007 at 17:46 | IP Logged Quote jbbtex

Thanks Dave.

I have been trying to figure out how to show status in CC for some time. Then last week it just clicked.

Here's what I've been able to cobble together. It's not pretty but it works. All of the switch buttons are toggles.



Being able to manipulate graphic files will allow me to put a little lipstick on it.

Brady


Edited by jbbtex - August 14 2007 at 17:47
Back to Top View jbbtex's Profile Search for other posts by jbbtex
 
sharby
Groupie
Groupie


Joined: May 13 2007
Location: United States
Online Status: Offline
Posts: 50
Posted: September 02 2007 at 03:23 | IP Logged Quote sharby

Brady,

Can you post that template and gifs? I'd like to improve upon it. Thanks.

-=*Sharby*=-
Back to Top View sharby's Profile Search for other posts by sharby
 
jbbtex
Senior Member
Senior Member


Joined: February 15 2007
Location: United States
Online Status: Offline
Posts: 181
Posted: September 02 2007 at 16:10 | IP Logged Quote jbbtex

Sharby,

All of the gifs as well as the background come with PH. They should be in \powerhome\web\graphics directory.

The background is k3-3_640480.jpg

Here is the code for my current Contol Center. All that is different is the addition of a button to open a IE window to create a One Shot timed event and another button that opens an IE window that displays the current Winamp playlist:
Code:
insert into cctabs values ('1',1,15780518,'C:\Program Files\powerhome\web\graphics\backgrounds\k3-3_640480.jpg','' ,'N','N',0,0);
insert into ccbuttons values ('1',4,5,'ph_setglobal_s("REMOTECLICK","MAILBOXSTATUS")+ph_m acro("CC CLICK") ',0,'MAILBOX',87,276,251,96,0,0,0,553648127,2,'Arial',8,700, 0,0,2,1,'','',6,0,0,1,50,50,'MAILBOXSTATUS');
insert into ccbuttons values ('1',5,5,'ph_setglobal_s("REMOTECLICK","FRONTPORCH")+ph_macr o("CC CLICK")',0,'PORCH',91,512,251,96,0,0,0,553648127,2,'Arial',8 ,700,0,0,2,1,'','',6,0,0,1,50,50,'FRONTPORCH');
insert into ccbuttons values ('1',6,5,'ph_setglobal_s("REMOTECLICK","GARAGE")+ph_macro("C C CLICK")',0,'GARAGE',87,748,251,96,0,0,0,553648127,2,'Arial', 8,700,0,0,2,1,'','',6,0,0,1,50,50,'GARAGE');
insert into ccbuttons values ('1',3,1,'',0,'GIRLS',686,384,686,232,0,0,0,553648127,1,'Ari al',8,700,0,0,2,6,'','',6,0,0,1,50,50,'GIRLS');
insert into ccbuttons values ('1',7,5,'ph_setglobal_s("REMOTECLICK","UPLIGHTS")+ph_macro( "CC CLICK")',0,'UP LIGHTS',91,984,251,116,0,0,0,553648127,2,'Arial',8,700,0,0,2 ,1,'','',6,0,0,1,50,50,'UPLIGHTS');
insert into ccbuttons values ('1',8,1,'',0,'PLAYROOM',686,652,686,232,0,0,0,553648127,1,' Arial',8,700,0,0,2,6,'','',6,0,0,1,50,50,'PLAYROOM');
insert into ccbuttons values ('1',9,5,'ph_setglobal_s("REMOTECLICK","GIRLSROOM")+ph_macro ("CC CLICK")',0,'ROOM',731,460,251,96,0,0,0,553648127,2,'Arial',8 ,400,0,0,2,1,'','',6,0,0,1,50,50,'GIRLSROOM');
insert into ccbuttons values ('1',10,5,'ph_setglobal_s("REMOTECLICK","CLOSET")+ph_macro(" CC CLICK")',0,'CLOSET',1033,460,251,96,0,0,0,553648127,2,'Arial ',8,400,0,0,2,1,'','',6,0,0,1,50,50,'CLOSET');
insert into ccbuttons values ('1',11,5,'ph_setglobal_s("REMOTECLICK","PLAYROOM2")+ph_macr o("CC CLICK")',0,'ROOM',741,740,251,96,0,0,0,553648127,2,'Arial',8 ,400,0,0,2,1,'','',6,0,0,1,50,50,'PLAYROOM2');
insert into ccbuttons values ('1',12,5,'ph_setglobal_s("REMOTECLICK","PLAYROOM3")+ph_macr o("CC CLICK")',0,'CLOSET',1047,740,251,96,0,0,0,553648127,2,'Arial ',8,400,0,0,2,1,'','',6,0,0,1,50,50,'PLAYROOM3');
insert into ccbuttons values ('1',13,1,'',0,'MASTER SUITE',1449,380,686,464,0,0,0,553648127,1,'Arial',8,700,0,0, 2,6,'','',6,0,0,1,50,50,'MASTER');
insert into ccbuttons values ('1',14,5,'ph_setglobal_s("REMOTECLICK","VANITY")+ph_macro(" CC CLICK")',0,'VANITY',1518,460,251,96,0,0,0,553648127,2,'Arial ',8,400,0,0,2,1,'','',6,0,0,1,50,50,'VANITY');
insert into ccbuttons values ('1',15,5,'ph_setglobal_s("REMOTECLICK","BED")+ph_macro("CC CLICK")',0,'LAMP',1518,688,251,96,0,0,0,553648127,2,'Arial', 8,400,0,0,2,1,'','',6,0,0,1,50,50,'BED');
insert into ccbuttons values ('1',16,5,'ph_setglobal_s("REMOTECLICK","TOWEL")+ph_macro("C C CLICK")',0,'TOWEL',1824,460,251,96,0,0,0,553648127,2,'Arial' ,8,400,0,0,2,1,'','',6,0,0,1,50,50,'TOWEL');
insert into ccbuttons values ('1',17,1,'',0,'FAMILY/KITCHEN',1449,928,686,232,0,0,0,55364 8127,1,'Arial',8,700,0,0,2,6,'','',6,0,0,1,50,50,'KITCHENFAM ILY');
insert into ccbuttons values ('1',18,5,'ph_setglobal_s("REMOTECLICK","TABLE")+ph_macro("C C CLICK")',0,'TABLE',1824,1020,251,96,0,0,0,553648127,2,'Arial ',8,400,0,0,2,1,'','',6,0,0,1,50,50,'TABLE');
insert into ccbuttons values ('1',19,5,'ph_setglobal_s("REMOTECLICK","LAMP")+ph_macro("CC CLICK")',0,'LAMP',1518,1020,251,96,0,0,0,553648127,2,'Arial' ,8,400,0,0,2,1,'','',6,0,0,1,50,50,'LAMP');
insert into ccbuttons values ('1',20,5,'',0,'DAY',2592,1236,288,180,0,0,0,553648127,0,'Ar ial',10,700,0,0,2,2,'','',6,0,0,1,50,50,'DAYLIGHT');
insert into ccbuttons values ('1',2,1,'',0,'SMALL GARAGE DOOR',1472,1280,663,212,0,0,0,553648127,5,'Arial',8,700,0,0, 2,6,'','',6,0,0,1,50,50,'NARROWDOOR');
insert into ccbuttons values ('1',21,1,'',0,'CLOSED',1605,1364,402,88,0,0,0,553648127,0,' Arial',8,700,0,0,2,2,'','',6,0,0,1,50,50,'SMALLGARAGE');
insert into ccbuttons values ('1',22,1,'',0,'BIG GARAGE DOOR',695,1280,663,212,0,0,0,553648127,6,'Arial',8,700,0,0,2 ,6,'','',6,0,0,1,50,50,'WIDEDOOR');
insert into ccbuttons values ('1',23,1,'',0,'CLOSED',786,1364,402,88,0,0,0,553648127,0,'A rial',8,700,0,0,2,2,'','',6,0,0,1,50,50,'BIGGARAGE');
insert into ccbuttons values ('1',24,3,'CC UPDATER',0,'HOME',78,1236,283,172,0,0,0,553648127,0,'Arial', 10,700,0,0,2,2,'','',6,0,0,1,50,50,'HOMEAWAY');
insert into ccbuttons values ('1',25,1,'',0,'o',2798,648,64,80,0,0,0,553648127,0,'Arial', 11,700,0,0,2,2,'','',6,0,0,1,50,50,'DEGREES');
insert into ccbuttons values ('1',26,3,'GET WEATHER',0,'',2565,660,224,132,0,0,0,553648127,0,'Arial',20, 700,0,0,1,1,'','',6,0,0,1,50,50,'TEMP');
insert into ccbuttons values ('1',1,100,'1',0,'',91,1312,251,216,0,0,0,12632256,0,'Arial' ,8,400,0,0,2,3,'D:\powerhome\web\graphics\buttons\home.gif', 'd:\powerhome\web\graphics\buttons\away.gif',6,0,0,1,50,50,' HOME');
insert into ccbuttons values ('1',27,100,'1',0,'',2610,1312,251,216,0,0,0,12632256,0,'Ari al',8,400,0,0,2,3,'d:\powerhome\web\graphics\buttons\day.gif ','d:\powerhome\web\graphics\buttons\night.gif',6,0,0,1,50,5 0,'DAYNIGHT');
insert into ccbuttons values ('1',28,1,'',0,'Temperature',2528,540,357,96,0,0,0,553648127 ,0,'Comic Sans MS',10,400,0,0,2,2,'','',6,0,0,1,50,50,'T');
insert into ccbuttons values ('1',29,1,'',0,'Relative Humidty',2565,820,320,160,0,0,0,553648127,0,'Comic Sans MS',10,400,0,0,2,2,'','',6,0,0,1,50,50,'H');
insert into ccbuttons values ('1',30,3,'GET WEATHER',0,'%',2560,972,320,140,0,0,0,553648127,0,'Arial',20 ,700,0,0,1,1,'','',6,0,0,1,50,50,'HUMIDITY');
insert into ccbuttons values ('1',31,3,'SAY WEATHER',0,'',530,1704,1879,204,0,0,16777215,553648127,0,'Ar ial',10,700,0,0,2,1,'','',6,0,0,1,50,50,'FORECAST');
insert into ccbuttons values ('1',32,1,'',0,'Home System Status',517,60,1893,176,0,0,16777215,553648127,0,'Comic Sans MS',22,700,0,0,2,2,'','',6,0,0,1,50,50,'TITLE');
insert into ccbuttons values ('1',33,1,'',0,'Current Forecast',599,1624,1751,120,0,0,16777215,553648127,0,'Comic Sans MS',10,700,0,0,2,2,'','',6,0,0,1,50,50,'WXLABEL');
insert into ccbuttons values ('1',34,3,'GET WEATHER',0,'Currently',2533,208,334,104,0,0,0,553648127,0,'C omic Sans MS',10,400,0,0,2,1,'','',6,0,0,1,50,50,'CONDITIONS');
insert into ccbuttons values ('1',35,1,'',0,'',2514,340,389,176,0,0,0,553648127,0,'Arial' ,12,700,0,0,2,2,'','',6,0,0,1,50,50,'CURCON');
insert into ccbuttons values ('1',36,4,'TEST',0,'Create a New Reminder',718,976,626,184,0,0,0,15780518,2,'Arial',12,700,0, 0,2,1,'','',6,0,0,1,50,50,'REMINDER');
insert into ccbuttons values ('1',37,5,'ph_ssrequest("192.168.0.10", 8500, "kitchen", "notebook", "FORMULA", ''ph_openiewindow("Playlist","http://bkbe-main/playlist.psp" ,194, - 1, - 1,2200,1300,0)'')',0,'Show Playlist',2601,1760,224,128,0,0,0,15780518,10,'Arial',8,400, 0,0,2,0,'','',6,0,0,1,50,50,'PLAYLIST');


HTH,
Brady
Back to Top View jbbtex's Profile Search for other posts by jbbtex
 
dhoward
Admin Group
Admin Group
Avatar

Joined: June 29 2001
Location: United States
Online Status: Offline
Posts: 4447
Posted: September 02 2007 at 19:40 | IP Logged Quote dhoward

Brady,

Very nice. You'll be happy to hear that Ive implemented two new functions. ph_getccobjgraphic and ph_setccobjgraphic. This will allow you to set both the "Up" and "Down" graphics (in the case of graphic buttons) or the "Up" graphic in the case of other graphics. This will also update the Remote CC screen cleanly.

Dave.
Back to Top View dhoward's Profile Search for other posts by dhoward Visit dhoward's Homepage
 
jbbtex
Senior Member
Senior Member


Joined: February 15 2007
Location: United States
Online Status: Offline
Posts: 181
Posted: September 05 2007 at 17:50 | IP Logged Quote jbbtex

Dave,

Thanks for the added functions. And thanks for the great program and tech support.

Can't wait for .12

Brady
Back to Top View jbbtex's Profile Search for other posts by jbbtex
 
GadgetGuy
Super User
Super User
Avatar

Joined: June 01 2008
Location: United States
Online Status: Offline
Posts: 942
Posted: January 08 2009 at 09:35 | IP Logged Quote GadgetGuy

In attempting to develop a CC page I find I'm hampered
by lack of item definitions (I can find anyway) for the
various CC Object Property Types.

Can anyone explain the differences between an Item and
the Action and Static versions of the Item?

For instance there are:
  • Text Button

  • Action Text

  • Static Text

items, and the same for Graphics and Global Variables.

How do these types differ and where are they
respectively used?

__________________
Ken B - Live every day like it's your last. Eventually, you'll get it right!
Back to Top View GadgetGuy's Profile Search for other posts by GadgetGuy
 
nadler
Super User
Super User


Joined: February 25 2006
Location: United States
Online Status: Offline
Posts: 354
Posted: January 08 2009 at 09:47 | IP Logged Quote nadler

Static Text is just a label.
Action Text is a label that you can press and have the pressed label perform an activity (raw formula, macro etc).
Text Button is the same as Action Text but moves down when you 'press' it.

Graphic versions are the same as the above but you can make them graphically more interesting by assigning a graphic to each button or box.

Global versions of the above have just been added in PH2 and are very powerful in that their 'label' reflects the content of any global variable immediately when the global variable changes. For example I have a macro that checks the temperature at 2 Insteon thermostats every 10 minutes and writes the results to two global variables. In several Control Center tabs I have Static Global Text 'boxes' which point to the global variables. Everytime the global variables change the 'boxes' in the Control Center screens are automatically updated without doing anything further.

I hope that helps.

Noel
Back to Top View nadler's Profile Search for other posts by nadler
 
GadgetGuy
Super User
Super User
Avatar

Joined: June 01 2008
Location: United States
Online Status: Offline
Posts: 942
Posted: January 08 2009 at 10:37 | IP Logged Quote GadgetGuy

Noel -

That helps a lot!!!!!!!!!!

BIG THANKS.

Now if I can just get the button graphics to change,
I'll be on a roll. I've got most of my control macros
written, now just need to get it all playing together.

It is so great to be able to monitor/control our home
from my iPhone when we are anywhere in the world. Using
the control center will make it even easier than the web
interface which I have been solely using up to now.

Thanks

__________________
Ken B - Live every day like it's your last. Eventually, you'll get it right!
Back to Top View GadgetGuy's Profile Search for other posts by GadgetGuy
 
nadler
Super User
Super User


Joined: February 25 2006
Location: United States
Online Status: Offline
Posts: 354
Posted: January 08 2009 at 11:44 | IP Logged Quote nadler

I'm not creative enough to use graphics. I just change colors. If you need help with that let me know. I use the iTouch with PH and love it. From any place that has wifi I can control my house. It's particularly helpful in changing temperatures in my house. Even though I have 2 programmable thermostats (Insteon) we sometimes manually change the temperature when we're home and forget to change them back when we're gone. So now I can lower the temps even when the program would not have lowered them for a couple of hours.
Back to Top View nadler's Profile Search for other posts by nadler
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum