XReceive/XSend Plug-in with Xlobby thin client?

Help each other out

XReceive/XSend Plug-in with Xlobby thin client?

Postby ficklma1 on Tue Feb 19, 2008 5:27 pm

Hi,

Just wondering if anyone has successfully updated an Xlobby thin client with the XReceive/XSend plug-in? I have not problem having it update my fat client. I either have something configured wrong or it's just not possible.

Any help with this would be greatly appreciated.
ficklma1
 
Posts: 12
Joined: Fri Oct 22, 2004 8:35 pm

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby Marbles_00 on Tue Feb 19, 2008 7:11 pm

You can use Xsend in events that are used by the thin client no problems. I'm doing just that in my Mirage skin. Menu navigation on the server via thin client is all done by Xsend commands.

I have not tried to display XRecieve info on the thin client, but should be possible as your only displaying a simple plugin>XReceive> text variable.

If your having problems, let us know how your using it, so we can help you more.

Remember to setup the IP and port in your ini file and your using the same one in your XSend commands.

*EDIT*
Re-reading what your asking is more to do with XRecieve on the thin client. I decided to give it a quick try and setup an example on my PPC screen. I then loaded Mirage and connected via thin client and noticed that it appeared to always be one command behind. But it did update the screen. The only problem I noticed (and I never have until I just tried this) is that my menu system behaved eratically...as at time it kept on rotating. I'm wondering if your problem, now thinking more about it, may lie in the fact of when the command is sent to when the PPC is refreshed.

The other thing you may look at is instead of using the default 172.0.0.1/8000 (IP/Port) use the machine network IP address if it is defined and not acquired via DHCP.
Marbles_00
 
Posts: 1867
Joined: Wed Apr 06, 2005 12:44 pm
Location: Canada

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby ficklma1 on Tue Feb 19, 2008 9:47 pm

Hi Marbles_00,

Let me try to explain what I'm seeing.
Here's my setup: I have a PC(main) running Xlobby as a server with XNET (default port) and have another PC running the PPC (thin client) of XLobby.
I have the XReceive/XSend plugin installed on (main) and an external app, PowerHome communicating to XLobby (changing my XLobby toggle buttons when an Insteon lighting event happens, works great on the fat-client). When I run the PPC (thin client) to do the same thing I don't see the toggle happen. IOW, it doesn't seem to update the toggle button state on the thin client screen.

Any ideas to why? Configuring the XReceive/XSend plugin the thin client IP address doesn't do anything. And BTW shouldn't the XReceive/XSend plugin be configured to update the XLobby Server? For instance, if you have multiple thin clients and wanted to reflect the toggle button state, wouldn't it make sense to have the central XLobby server be the only place that has to reflect the change, that way ALL clients would have the same toggle button state?

I hope this makes sense.

Thanks again for the help.
ficklma1
 
Posts: 12
Joined: Fri Oct 22, 2004 8:35 pm

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby Marbles_00 on Tue Feb 19, 2008 10:46 pm

First, I'm sorry, I made a typo....it isn't 172.0.0.1...it should be 127.0.0.1.

When I run the PPC (thin client) to do the same thing I don't see the toggle happen. IOW, it doesn't seem to update the toggle button state on the thin client screen.


I'm wondering if it has something to do with the refreshing I mentioned before...I'm trying to think of a way to force the PPC to refresh via some event. I see now that you aren't using a simple plugin>XReceive> text box, but you are trying to either set text events or use button show/hide events depending on the information you get from powerhome. I just tried to set text and show buttons when rotating my menu and I see your dilema. Trying to figure out some work around for ya...not sure, but let's see.

Configuring the XReceive/XSend plugin the thin client IP address doesn't do anything

Correct, you shouldn't configure the client IP address as the thin client is only running a simle exe and would not understand the XSend command directly.

the XReceive/XSend plugin be configured to update the XLobby Server?

You do know that you don't have to run a Server/Client setup to use XSend/XReceive, as it works at a IP level, not a XNET level. You can send/recieve commands between any two machines. I recently figured out how to send zone information from one XNET server to another XNET server (servers can't really be connected via XNET, but via IP...no problems). I also can use any machine and xsend commands to control the music server without even being a true client.

wouldn't it make sense to have the central XLobby server be the only place that has to reflect the change, that way ALL clients would have the same toggle button state?

Yep, you are correct, that would be the most ideal solution.
Marbles_00
 
Posts: 1867
Joined: Wed Apr 06, 2005 12:44 pm
Location: Canada

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby scottw on Wed Feb 20, 2008 1:45 pm

Marbles_00 wrote:I'm wondering if it has something to do with the refreshing I mentioned before...I'm trying to think of a way to force the PPC to refresh via some event.


I don't think there is, I remember reading a post asking for it before. I think the closest you can get is to set the refresh time down on the servers.txt file, I have mine set to 1000 and it works great but may not be ideal for what you are trying to accomplish.

edit: here is the post http://xlobby.com/forum/viewtopic.php?f=6&t=5407&st=0&sk=t&sd=a&hilit=refresh+ppc
scottw
 
Posts: 774
Joined: Mon Feb 06, 2006 4:21 pm
Location: Glen Burnie, Maryland

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby ficklma1 on Wed Feb 20, 2008 3:01 pm

Thanks for the suggestions.

I think that maybe it could be related to a refresh issue. Like I stated, if I click the button from the fat-client everything works as it should, PowerHome sends the XSend command and updates the fat-client button toggle state. However when I try this from a thin client (running on a completely different PC) it communicates to PowerHome(I can see the Insteon light turn off), but the XSend doesn't seem to refresh the thin-client (or more likely it's not really XSend, it is just the way the fat-client communicates back to the thin-client - i.e. not refreshing)

I'll try adding the "refresh" command to my servers.txt file tonight to see if that corrects the issue, it's probably not ideal, but it's better than the way it is now.

Thanks again for all of the suggestions.
ficklma1
 
Posts: 12
Joined: Fri Oct 22, 2004 8:35 pm

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby scottw on Wed Feb 20, 2008 4:17 pm

I don't think it will work....but please correct me if I am wrong. I think the thin client acts as it's own "enviroment" kind of like a fat client. I believe the "server" and the thin client do not share certain information with each other like toggle states and variables, and I believe is the same between 2 Fat clients. I would LOVE for this to work as I have complained alot in the past about this. I am running a zone map and if I click to activate a zone on the map which causes it to change colors showing it's active, this will not be reflected on any thin clients or other Fat clients. If I click the zone from the thin client it will show on the thin client but not show on the server or Fat client. Again I would LOVE to be wrong about this so if I am please let me know.
scottw
 
Posts: 774
Joined: Mon Feb 06, 2006 4:21 pm
Location: Glen Burnie, Maryland

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby Marbles_00 on Wed Feb 20, 2008 5:45 pm

What you could do, though visually it is not the most reliable, but functionally it should work is to have a button on your PPC that you setup to do multiple toggle states. A real good tutorial can be found here:
http://www.xlobby.com/forum/viewtopic.php?p=32891#32891

That will set you button to either "Light On" or "Light Off".
In those events you would have the commands to tell Powerhome to turn lights on/off, and change the button text and image accordingly.

Then above the button in your PPC screen you could have a text field with plugin>XReceive>received, which will receive all the XSend commands from Powerhome. The only thing is that if you are sending multiple messages, the text field will only show the most recent. The thing you could do then is to send one big message with all the status reported. This is how I do the zone status report from my music server to my Mirage skin.

In my ZoneSkin4 I've created an event recently (not released yet) with a command to os:execute xsend. In my arguements I've added "%zone>1>status%" "%zone>2>status%"..."%zone>X>status%" "8000" "AAA.AAA.AAA.AAA". Where: X is the zone number, and AAA is the IP address of the resultant machine. I've set up an XEvent variable to trigger this event every minute.

So then in my Mirage skin I've added a text field plugin>XReceive>received and every minute it receives an update on all the zones (which for my use in ZoneSkin4, these are really winamp sources). Check out the my most recent Mirage post in the skins section. Oh and by the way, the Mirage machine is not even a client of the ZoneSkin4 music-server.

You could do something similar as this, only you could update every 10 seconds, or 5 seconds, then set your PPC refresh to 1000 (1 second intervals).

Or in the very least, use the text box idea, but don't use a toggle button, but two buttons, one "On" the other "Off" and tie powerhome events to them to turn lights on/off. Powerhome in return should send xsend commands which you should be able to pick up on.

Now in your case, I've experimented yesterday with the plugin>XReceived text box on the thin client, and though it works, it always seemed to be one command behind the current. In this case I was rotating the XMenu in the Mirage skin around and every rotation sends an XSend command to update a text field. In Mirage, this text field is in the upper left corner of the screen and updates the name to whatever the front most image is. So in this case for powerhome, you could set up something similar but since it always seems to be one command behind, for an "On" state, you would want to send a text field saying "Off" and when off, you'd want to send a text field to say "On".

Pretty confusing...you bet . Is it perfect...no even close, but in the very least it gets you going with something, though will be buggy, it will be functional. What we really need are for more of the French dudes to come back and whip up some nifty plugins that will take care of this :wink: , or maybe P3rv with his P3rvTalk plugin...maybe he might have more of an idea/workaround.

What are the limitations of doing this:
1) As scott points out, toggling buttons on another client will not show up on the thin client (button wise). It should however update the plugin>XReceive textbox, so in the very least, you should be able to attain status of what a light is doing.

2) Toggling from the PPC will not be indicated on other clients...again unless you use something like the plugin>XReceive textbox.

3) Information displayed in the textbox on a thin client always seems to be one command behind the current. If only indicating two states, just xsend a text message to indicate the opposite state then the current.

4) The resultant text from the plugin>XReceive text field most times show the pure command sent. You would have to play around with it to get the message you want.

Sorry for the long and rambling post...I know it may not be exactly what you want to hear (or even if you understood anything that I have said). If I get a chance, I will do up some mock examples and and throw the images on here to help you out.
Marbles_00
 
Posts: 1867
Joined: Wed Apr 06, 2005 12:44 pm
Location: Canada

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby scottw on Wed Feb 20, 2008 7:41 pm

Awesome post Marbles!!!!!

I like the status update idea...since one of my issues would have been when the PPC client or a fat client fires up it would not be in "sync" with the server. There has got to be a way to make this toggle button thing work globally, I will try to think about it a little to see if I can come up with any ideas. It would be great to have all "clients" synced up.....but that may not be possible.
scottw
 
Posts: 774
Joined: Mon Feb 06, 2006 4:21 pm
Location: Glen Burnie, Maryland

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby scottw on Mon Feb 25, 2008 8:02 pm

Marbles_00 wrote:4) The resultant text from the plugin>XReceive text field most times show the pure command sent. You would have to play around with it to get the message you want.


Playing around with Xreceive I found out you can just send your "execute file" with the actual even you want run and then "wait" 500 then run a bogus command named whatever you want the plugin>XReceive>received text to say, like this:
--execute file--
File: c:\xsend.exe
Arguments: "command:xlobby:run event:music:test2" "8002" "x.x.x.x" X's being the IP

--Wait--
500

--execute file--
File: c:\xsend.exe
Arguments: "Finished" "8002" "x.x.x.x"

It does not give an error when "Finished" is run even though it is not a valid command but shows Finished in the plugin>XReceive>received text box.


Hope that helps!!!!
scottw
 
Posts: 774
Joined: Mon Feb 06, 2006 4:21 pm
Location: Glen Burnie, Maryland

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby Marbles_00 on Mon Feb 25, 2008 8:34 pm

8)
Marbles_00
 
Posts: 1867
Joined: Wed Apr 06, 2005 12:44 pm
Location: Canada

Re: XReceive/XSend Plug-in with Xlobby thin client?

Postby ficklma1 on Tue Feb 26, 2008 6:22 pm

Hello everyone,

I can't thank you enough for the suggestions. I will definitely keep them in mind.
I've currently decided to move away from the thin client, due to this shortcoming. I've implemented the Xlobby fat-client on a HP t5720 thin-client running XPe and it's working great. the t5720 is driving an ELO 1529L touch screen and I can't be more pleased. I had to of course do some research on how to correctly point the fat-client to my music DB, i.e. I just used UNC naming path on my Xlobby server application and the fat-client via XNET found it.
I'm still in "dev" mode with my skin, but so far I have music, pictures, weather and IR control for my AV recevier via Powerhome and a USB-UIRT. I originally had Xlobby control my USB-UIRT, but since I'm not really controlling it through the Xlobby server. I'm instead controlling it through the fat-client via XNET and so I've implemented a solution using the PH socket serer, sending PH IR commands from my Xlobby fat-client. So far so good.

Again, thanks for everyone's help with the thin-client suggestions. I'll definitely keep them in mind for future reference.
ficklma1
 
Posts: 12
Joined: Fri Oct 22, 2004 8:35 pm