Author |
|
jimmyb Newbie
Joined: December 10 2004 Location: United States
Online Status: Offline Posts: 6
|
Posted: December 10 2004 at 13:03 | IP Logged
|
|
|
Ok Dave. Downloaded, followed quick start guide, get reaction from Palm Pad, built a button to turn on a lamp, buttttt .......
How do I assign my turn on at sunset Timed Event to a particluar X-10 device??? I am completely stymied???
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: December 10 2004 at 14:23 | IP Logged
|
|
|
Jim,
Not a problem .
It sounds as if you've found the Timed Events and have created one for sunset but don't know what to put in the "ID/Keys/Formula" field to make it turn a light on via X-10. If Ive gotten this wrong, let me know.
There are several different ways to do this but I'll just go over 3.
The first way would be to simply set your timed event type to "Formula" and then type in a formula in the "ID/Keys/Formula" field to turn on the light. I don't know how much you know about X-10 but it basically takes two commands to turn a light on. The first command "addresses" the light and the second command "turns on" what you've addressed. So to keep this simple, this is the formula to turn on a light located at A1:
ph_x10(1,"A",1,0) + ph_x10(1,"A",102,0)
You can look up the details of the ph_x10 function in the help file for an explanation of the functions parameters.
The second way to do it would be again to use a type of "formula" and then use the ph_x10btn formula function. This one function combines both the addressing and function commands into a single function but requires you to have defined the X-10 device in the X-10 section of the PowerHome Explorer. Whereas the ph_x10 function sends raw X-10 commands regardless of whether you've defined the device or not (same as the internal palm pad), the ph_x10btn will send the appropriate commands based upon how you've defined the device within PowerHome. To continue with our example of A1, assuming you've defined this device within the X-10 section of PowerHome, the formula would look like:
ph_x10btn("A",1,2,0)
The last way to do this would be to first declare a macro within the "Macros" section of the PowerHome Explorer. You can use the above formulas with the "Formula" command or the specific "X-10 1" command for X-10 functions. Once you've declared the macro, you can then go back to the Timed Events and set the type to "Macro" and then select the "ID" of the macro you created in the "ID/Keys/Formula" field.
Let me know if you have any other questions and I'll be more than happy to help.
Dave.
|
Back to Top |
|
|
jimmyb Newbie
Joined: December 10 2004 Location: United States
Online Status: Offline Posts: 6
|
Posted: December 10 2004 at 15:28 | IP Logged
|
|
|
ok .. so using the 3rd sample. I had made a macro for ON but it is not assigned to any particular device. Should I make a second sequence (20) and assign the value as a number equal to the exact device? If so then I must make a Macro for each device or a sub seq under the main macro for lights on.
|
Back to Top |
|
|
jimmyb Newbie
Joined: December 10 2004 Location: United States
Online Status: Offline Posts: 6
|
Posted: December 10 2004 at 15:47 | IP Logged
|
|
|
Hoah!!! .. got it So I should change name of macro from lights on to say Dusk On and list all devices I want to come on at that time?
While I have your ear on a different note. I cannot see the PSP folder or ph-cgi, yet webserver works great. Is this something turned off until I register (read pay :)) or is something wrong on my end??
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: December 10 2004 at 15:57 | IP Logged
|
|
|
If you were using a macro, the first line (sequence 10) should be the address. The second line (sequence 20) should be the "on" command. The way X-10 works is that devices are first addressed, then commands are sent. A device will remain addressed until the first address after a command (on,off, dim, etc) is received.
So...you could address A1,A2,A4,A7 and then send an "A ON" command and units 1,2,4, and 7 under housecode A would all turn on simultaneously. If you were then to issue a "dim" command (to housecode A), then the above 4 units would all dim together. If you next issued an A5 address, then the previous A1,A2,A4, and A7 would become "unaddressed" (the first address after a command) and only the A5 would be "addressed". Keep in mind that all of this applies only within a "housecode" and what happens on housecode B,C, etc. will have no effect on housecode A.
So, your macro should look like this for A1:
10 X-10 1 A 1
20 X-10 1 A ON
If you wanted to turn on A1 and A2 and A3 simultaneously, it will look like:
10 X-10 1 A 1
20 X-10 1 A 2
30 X-10 1 A 3
40 X-10 1 A ON
And if you wanted to sequence the lights on so that A1 turns on followed by A2 and A3, it would look like:
10 X-10 1 A 1
20 X-10 1 A ON
30 X-10 1 A 2
40 X-10 1 A ON
50 X-10 1 A 3
60 X-10 1 A ON
The equivalent formulas for the above are:
ph_x10(1,"A",1,0) + ph_x10(1,"A",2,0) + ph_x10(1,"A",3,0) + ph_x10(1,"A",102,0)
and
ph_x10(1,"A",1,0) + ph_x10(1,"A",102,0) + ph_x10(1,"A",2,0) + ph_x10(1,"A",102,0) + ph_x10(1,"A",3,0) + ph_x10(1,"A",102,0)
Let me know how else I can help.
Dave.
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: December 10 2004 at 16:09 | IP Logged
|
|
|
Jim,
>>Hoah!!! .. got it So I should change name of macro from lights on to say Dusk On and list all devices I want to come on at that time?
Yep. That would be a great way to keeps things straight.
>>While I have your ear on a different note. I cannot see the PSP folder or ph-cgi, yet webserver works great. Is this something turned off until I register (read pay :)) or is something wrong on my end??
The PowerHome distribution used to have the PSP folder installed but I havent been including it in the beta versions since I havent had a chance to update the PSP code. It was a subfolder of "web" and contained sample PSP files. PSP files can be anywhere within the "web" folder heirarchy and will work just fine. I'll try to post a couple of working samples so you can get some ideas and they'll work just fine during the trial period.
The ph-cgi directory does not exist as a physical directory and is a "virtual" directory within the PowerHome webserver. All ph-cgi "commands" are built in to the PowerHome webserver. A partial list of these commands are:
/ph-cgi/main
/ph-cgi/controlcenter
/ph-cgi/directsql
/ph-cgi/sqlquery
/ph-cgi/formula
/ph-cgi/execsendkeys
/ph-cgi/evalformula
/ph-cgi/playmacro
Most of the workings of the "ph-cgi" commands can be gleaned from viewing the source of the internal web pages but I will be doing full documentation of them shortly. In the meantime, if you have any questions on a specific command, I'll be more than happy to help.
HTH,
Dave.
|
Back to Top |
|
|
jimmyb Newbie
Joined: December 10 2004 Location: United States
Online Status: Offline Posts: 6
|
Posted: December 10 2004 at 16:23 | IP Logged
|
|
|
Thanks so much for your hand holding. I can see I am going to like this. I made the changes as you said in Macros and await dusk.
The only sheets in the WEB folder are 2 CCS sheets, PH and PHCC which I recongnize as style sheets.
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: December 10 2004 at 21:24 | IP Logged
|
|
|
Glad to be of assistance. What I'll do is write the main page (/ph-cgi/main) as a PSP page and I'll post it on the web so you can download it and test with it. It'll take me a couple of days but I'll post a message on the board when it's ready.
In the mean time if you have any other questions, don't hesitate to ask.
Dave.
|
Back to Top |
|
|
|
|