Jump to content
C4 Forums | Control4

Whole House light control app in Java


xc420

Recommended Posts

I created an app for discovering and controlling Lights on the LAN and uploaded it to the File Library. This is a WIP. A few of the issues with it so far is, it doesn't discover plugin Lamp modules, doesn't discover the state of light switches on startup(only dimmers), and also UI isn't updated when the toggle buttons are pressed. I plan of fixing these issues, but I decided to go ahead and release what I have so far. If any Java programmers would like to help me with this, please let me know.

USE AT YOUR OWN RISK. I don't want to be held responsible for a freeware app that you choose to run. I've been using this at my house and it hasn't crashed my system - 'yet'.

Also, if you decompile the bytecode don't laugh. :) I just started learning Java about 4 months ago and still have a lot to learn.

Link to comment
Share on other sites


If you want to do floor and room light status, you should integrate it with my Light Usage Agent driver.

It creates number variables for each floor and room, which show the percentage the lights are on in that area.

RyanE

I'm not sure if that's what I want but thanks I'll look into it.

Link to comment
Share on other sites

I'm having a problem tryng to run this app, when I click on the .JAR file it opens a window, looks to be a dos or command window, at the title bar it says C4LIGHTS 192.168.x.x, and thats it, it just sits there, what an I doing wrong?

Link to comment
Share on other sites

I'm having a problem tryng to run this app, when I click on the .JAR file it opens a window, looks to be a dos or command window, at the title bar it says C4LIGHTS 192.168.x.x, and thats it, it just sits there, what an I doing wrong?

Thanks for letting me know about this. You're not doing anything wrong. About two weeks ago this happened on my dev PC running XP. I think I just rebooted my PC and it started working again.

What is your OS? Do you have a current version of JRE installed?

It's definitely communicating with the controller. It seems like it's having problems retrieving or parsing getitems.xml.

If rebooting the PC doesn't fix the problem, as a last resort try rebooting the controller and see if it works. I know this is a lot to ask for, sorry. If you get this to work, please let me know what you had to do. Thanks.

Link to comment
Share on other sites

Tried rebooting the controller and the PC, running win7

Went to sun's site and got the jre from them.

Still same results??

Do me a favor if you don't mind. Send me your GetItems.xml and I'll try to figure out what is going on. I'll use it only for testing purposes and delete it off of my PC when I'm finished with it. At the very least, I can rule out any parsing issues.

If you have trouble retrieving GetItems.xml from your controller email me and I'll send you an App that will get it for you.

A thought I just had: I wonder if this has anything to do with UAC in windows7

Link to comment
Share on other sites

xc420,

I decompressed your code and ran "java GetLights" at the root of your subdirectory structure and got the following response:

I/O - java.net.SocketTimeoutException: Receive timed out

Couldn't get I/O for the connection to controller

Then a ShowDialog saying "Could not connect to the controller".

I am running Win7. I ran this form the command prompt and also created a bat file with property Compatibility mode set to XP SP3. In both cases, I got the same behavior.

Link to comment
Share on other sites

xc420,

I decompressed your code and ran "java GetLights" at the root of your subdirectory structure and got the following response:

I/O - java.net.SocketTimeoutException: Receive timed out

Couldn't get I/O for the connection to controller

Then a ShowDialog saying "Could not connect to the controller".

I am running Win7. I ran this form the command prompt and also created a bat file with property Compatibility mode set to XP SP3. In both cases, I got the same behavior.

Are you sure you have network access to the controller? Maybe it's on a different subnet.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.