
Originally Posted by
MarkHarrison
I'd like to see something about integration with other Home Automation systems (Homeseer, xAP, xPL, Misterhouse, or whatever.)
Mark
Hi mark, that is something that I dont think that I will be able to do, as I dont have, and have never used any other home automation systems
- im doing all this on a very tight budget, and fell that if i choose a particular system, then I will be limiting my options somewhat.
Toscal, They are very good questions, I'll do my best to answer, and put the best bits in my article lol.
My light server mk1 was strictly one way (I had never used flash before the night I posted up about my MID) As you may know the MID is very restricted, it resets all your settings on power off etc. It does come with flash player v5, and v6 (I dont have a windows CE sdk, and I dont think the MID has .net installed) - anyway, I dug through my software box and found flash, installed it and started reading the help files, created a basic slider using code I found on the net. A few hours reading (and googling) later I found some code to send data over TCP - My light switch was working
Its really basic - this is the full code for something that works (although it does need work)
Code:
var scrollMax:Number = 207;
var scrollMin:Number = 141;
var xsTestSocket: XMLSocket = new XMLSocket();
cbtCallFW.onPress = function() {
var bSuccess:Boolean = xsTestSocket.connect("10.0.0.12", 2000);
}
myoffbtn.onPress = function() {
xsTestSocket.close;
}
xsTestSocket.onConnect = function(bSuccess:Boolean):Void {
if (bSuccess) {
trace("Connection to RPC Server opened");
}else{
trace("Connection failed");
}
}
Slider1.onPress = function() {
this.startDrag(false,this._x,scrollMin,this._x,scrollMax);
this.onMouseMove = scroll2;
}
Slider1.onRelease = Slider1.onReleaseOutside = function() {
this.stopDrag();
}
function scroll1() {
var iValue:Number = (Slider2._y - ScrollMin) * 4;
if (iValue > 255) {
iValue = 255;
}
iValue = 255 - iValue
var sFWCmd:String = "1,2," + iValue + ",X";
xsTestSocket.send(sFWCmd);
}
And thats how the lightswitch works (Ive ommitted the other channels, but they are identical code, only slider2, slider3, etc
On to feedback - if you can understand the code above, you will see that there is no feedback - yet. But I have just finished coding DMX Light Server mk2, and this time it does have feedback.
This one is a .net application, based on downloaded code for a multi-threaded, multi-client chat server, only I dont chat with it, I send light commands - any other connected clients get the information forwarded onto them from the server to update their display. I have included a 'hello' message, so that new clients that connect to the server get a list of the current channel settings - alloying them to be in sync with the rest of the system.
Shortly I will add some code to my flash script to allow it to interprit this information and update the screens accordingly.
As for homebrew vs commercial -> I tend to homebrew everything that I can, as I find it difficult to pay £50 for something that contains £2 worth of parts(hardware).
I get microprocessors for £0.29 and they are very capable, and can be tuned to suit my needs.
Software wise, its always homebrew, as again I dont like paying for something then finding out it cant/wont do what I want.
Im scottish, and living up to the reputation - eg im as tight as a cats..... when it comes to money (more money for parts
)