Plugwise on Bwired

Forum about Questions, discussions and announcements regarding the Bwired website owned by Pieter Knuvers
digibeetle
Starting Member
Starting Member
Posts: 1
Joined: Thu Oct 09, 2008 10:18 pm
Location: Netherlands

Plugwise on Bwired

Post by digibeetle »

What i'm wondering is how you can switch the socket on/off locally? I understand you can do this remote, but if you connect it to a lamp or washing machine it would be nice if you could also "overrule" it by hand to switch a device on wich was switched off remote.
Digit
Global Moderator
Global Moderator
Posts: 3388
Joined: Sat Mar 25, 2006 10:23 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Digit »

Well, when it's on, you can switch it off by pulling it out of the socket. [:)] No just kidding, without local switch there's no way to do it. Maybe in future versions of the plug?
Bwired
Administrator
Administrator
Posts: 4704
Joined: Sat Mar 25, 2006 1:07 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Bwired »

Right, you can upload a timer schedule to plug for example turn it Off at 3.00 and On at 7.00
Or you can integrate in your home automation system, my HA system can turn a circle on if there is motion or turn a circle of when the alarm is activated.
I think Plugwise will also come with a manual switch on the plug.
User avatar
aeh
Member
Member
Posts: 76
Joined: Sun Mar 09, 2008 10:08 am
Location: Netherlands

Plugwise on Bwired

Post by aeh »

How can I control the Circle with Homeseer????
User avatar
TANE
Forum Moderator
Forum Moderator
Posts: 4806
Joined: Fri Apr 06, 2007 9:46 pm
Location: Netherlands
Contact:

Plugwise on Bwired

Post by TANE »

you can't do this at the moment..
we have to wait for the plugin..or someone has to write a basic script to do this from events..
Bwired
Administrator
Administrator
Posts: 4704
Joined: Sat Mar 25, 2006 1:07 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Bwired »

Who is going to write the Plugin for Homeseer?, I'm not a Homeseer user anymore but I know its not that difficult because I wrote them for version 1.7.

I will help you with the starting code for controlling the ON and OFF
part for the Plugwise circles.

You can switch the circle devices like:
http://www.yourwebsite.nl:8080/circleco ... =8&cmd=off

This is the HTML code for controlling the circles (circlecontrol.html):

Code: Select all

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<? header("HTTP/1.0 204 No Content"); ?>
<html>
  <head>
  <title>Bwired Plugwise example</title>
  </head>
  <body>
    <%
    Response.Status = "204 no content"
    $cmd=Request.get.containsKey("cmd")?Request.get["cmd"]:""
    $applid=Request.get.containsKey("applid")?Request.get["applid"]:0
    $modid=Request.get.containsKey("modid")?Request.get["modid"]:0
   
    if ($applid>0)
      With Appliance($applid)
        //echo "<br>",.Name,": "
        if $cmd=="on"
          .SwitchOn()
          //echo " ingeschakeld"
        elseif $cmd=="off"
          .SwitchOff()
          //echo " uitgeschakeld" 
        /if
      /With
    /if
    if ($modid>0)
      With Module($modid)
        //echo "<br>",.Name,": "
        if $cmd=="on"
          .CloseRelay()
          //echo " ingeschakeld"
        elseif $cmd=="off"
          .OpenRelay()
          //echo " uitgeschakeld" 
        /if
      /With
    /if

    echo "<hr>"
    foreach Plugwise.Appliances
      //echo '<br>',.Name,': <a href="?applid=',.Id,'&cmd=on">Aan</a> <a href="?applid=',.Id,'&cmd=off">Uit</a>' 
    /foreach
    	//echo "<hr>"
    foreach Plugwise.Modules
      	//echo '<br>',.Name,': <a href="?modid=',.Id,'&cmd=on">Aan</a> <a href="?modid=',.Id,'&cmd=off">Uit</a>' 
    /foreach
    %>
  </body>
</html>
User avatar
TANE
Forum Moderator
Forum Moderator
Posts: 4806
Joined: Fri Apr 06, 2007 9:46 pm
Location: Netherlands
Contact:

Plugwise on Bwired

Post by TANE »

Pieter,
I have created the file circlecontrol.html in
C:\Program Files\Plugwise\Plugwise Source\www

when i send the command nothing happens
http://192.168.1.97:8080/circlecontrol. ... TL&cmd=off

This is the error


<% Response.Status = "204 no content" $cmd=Request.get.containsKey("cmd")?Request.get["cmd"]:"" $applid=Request.get.containsKey("applid")?Request.get["applid"]:0 $modid=Request.get.containsKey("modid")?Request.get["modid"]:0 if ($applid>0) With Appliance($applid) //echo "
",.Name,": " if $cmd=="on" .SwitchOn() //echo " ingeschakeld" elseif $cmd=="off" .SwitchOff() //echo " uitgeschakeld" /if /With /if if ($modid>0) With Module($modid) //echo "
",.Name,": " if $cmd=="on" .CloseRelay() //echo " ingeschakeld" elseif $cmd=="off" .OpenRelay() //echo " uitgeschakeld" /if /With /if echo "" foreach Plugwise.Appliances //echo '
',.Name,': Aan Uit' /foreach //echo "" foreach Plugwise.Modules //echo '
',.Name,': Aan Uit' /foreach %>


direct control from the index page is working fine when using http://192.168.1.97:8080
Digit
Global Moderator
Global Moderator
Posts: 3388
Joined: Sat Mar 25, 2006 10:23 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Digit »

Maybe just a typo in your post, but you have a file called circlecontrol.html and you're using circlecontrol.htm in your command???
Digit
Global Moderator
Global Moderator
Posts: 3388
Joined: Sat Mar 25, 2006 10:23 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Digit »

No, that can't be it. It looks more like something running server-side is not working ok. What? Don't know, but i guess Pieter is the one that will be able to come up with an answer for that[:)]
Bwired
Administrator
Administrator
Posts: 4704
Joined: Sat Mar 25, 2006 1:07 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Bwired »

I think it's the applId, this must be a number I guess
User avatar
RDNZL
Forum Moderator
Forum Moderator
Posts: 1008
Joined: Sun Sep 24, 2006 1:45 pm
Location: Dordrecht, The Netherlands
Contact:

Plugwise on Bwired

Post by RDNZL »

Is it possible to track your order at plugwise?

I ordered a start pakket monday, haven'got any response so far, except the fact that I have placed an order.

No answer on the question I sent the helpdesk by e-mail.
Edit: Ok, got the package today...
User avatar
TANE
Forum Moderator
Forum Moderator
Posts: 4806
Joined: Fri Apr 06, 2007 9:46 pm
Location: Netherlands
Contact:

Plugwise on Bwired

Post by TANE »

<blockquote id="quote"><font size="1" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote"><i>Originally posted by Bwired</i>
<br />I think it's the applId, this must be a number I guess
<hr height="1" noshade id="quote"></font id="quote"></blockquote id="quote">Where can i find the applID?
Bwired
Administrator
Administrator
Posts: 4704
Joined: Sat Mar 25, 2006 1:07 am
Location: Netherlands
Contact:

Plugwise on Bwired

Post by Bwired »

It's not in the source control software, in the beginning of this topic I posted the XML layout to get more real time information like the ID from the Plugwise webserver. Place this XML in webserver directory and run it, then you find for every device you have connected the ID. Use this ID in the URL as parameter.
User avatar
TANE
Forum Moderator
Forum Moderator
Posts: 4806
Joined: Fri Apr 06, 2007 9:46 pm
Location: Netherlands
Contact:

Plugwise on Bwired

Post by TANE »

Yes it's working...my own Homeseer interface to Plugwise..:)

The only problem is by every status change there will be a new browser window open.:(
hope that someone can find a better script for controlling this part..
I will post the scripts in HS forum
http://www.domoticaforum.eu/topic.asp?TOPIC_ID=1535

@Pieter: all the credits are for you, thank you for your help.
Niknik
Member
Member
Posts: 255
Joined: Wed Apr 26, 2006 6:22 pm
Location: Portugal
Contact:

Plugwise on Bwired

Post by Niknik »

Sorry for the newbie question, but what is the difference between the "CIRCLE +" and the other (non "+") sockets?

Is the "+" the master network socket or something?
(And is that why this socket needs to be the one closer to the USB receiver?)
Post Reply

Return to “Bwired Forum”