X10 Community Forum
🔌General Home Automation => Automating Your House => User Modified Devices => Topic started by: daferrisda on December 09, 2011, 05:49:41 PM
-
Hi,
I've managed to write a test RB program which switches on and off X10 modules fine, however I've now moved on to dimming and can't get it working. This is what's being sent and received all in hex &h
> Is Sending to the CM12
< Is receiving
>0466 04=Header 6=HouseCode A 6=DeviceCode 1
<6a Checksum
>00 OK to transmit
<55 Interface Ready
>8664 8=DimCommand 6=HouseCode 64=DimValue
<ea Checksum
>00 OK to transmit
<55 Interface Ready
I know these are being sent as the test program confirms this and the timing is correct, I think as it works ok when I'm using ON and OFF commands. I only send the next command when I receive either the checksum or the 55
Would really appreciate some help.
Thanks
David
-
Have you tried with other dim values or only with 64?
-
Have you tried with other dim values or only with 64?
I've tried with several but all of them seems to be ignored. I've noticed there is a delay between last 00 and 55 responses, so I guess it is sending something through the mains?
-
I'm certainly no expert in programming this stuff, but it seems like I recall seeing somewhere that in order to dim a module, it first requires an ON command, and then the dimming command, so maybe it would be worth trying that.
HTH...
JK
-
It has been 3 or more years since I worked on low level code so things may have changed and the CM12 may differ from the CM11A but the current CM11A protocol documentation (Section 3.1.1) says...
Number of Dims is a value between 0 and 22 identifying the number of dims to be transmitted (22 is equivalent to 100%)
It can take quite some time for a Dim or Bright command to be sent over the powerline and the CM11A doesn't return the 0x55 until that has completed. From a web article I wrote...21 contiguous commands require 231 half cycles of the powerline or 3.85 seconds @ 60Hz. If an address + gap precedes the sequence, the total becomes 4.27 seconds.
It will take 20% longer at 50Hz.
- http://davehouston.org/micro-dim.htm
OTOH, if you are sending extended dims, that requires a different method. See Section 3.2 of the documentation.
- http://software.x10.com/pub/manuals/cm11a_protocol.txt
I wrote a CM11A demo in RealBasic several years ago but no longer have the source. A networked HDD died a couple of years ago and it had lots of things like this.
I no longer use RealBasic as it appeared their main motivation was to milk maximum revenue from their victims customers. I do have some ZBasic code but I'm not sure it will help you much and, as it was written 3+ years ago, I may not be able to answer questions. If you want the ZBasic code, send me a PM with your email address.
-
Thanks for your advise it has helped, although I think I may have found my error. I'll do some more testing but I think my understanding of this line wrong
>8664 8=DimCommand 6=HouseCode 64=DimValue
Will let you know how I get one.
Thanks
David