Please login or register.

Login with username, password and session length

Author Topic: Monitor Device  (Read 1516 times)

X10_Coder

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Monitor Device
« on: May 15, 2017, 02:01:12 PM »

Hello:

I'm new to this forum and to programming X10 devices. For the most part I am just tinkering around having fun turning everything in my house on and off.

I wrote some code to work with the firecracker, and now am playing with the CM11A. For the most part my code is working quite well but a little confused about monitoring a device on the CM11A.

I can see in the status response the House Code and Device Code along with the on/off and dim values, but I'm not all that sure how to change to monitoring a new device?

How do I tell the CM11A that I want to change the monitored House Code / Device?

thanks.
Logged

Tuicemen

  • Administrator
  • Hero Member
  • ****
  • Helpful Post Rating: 282
  • Posts: 10497
  • I don't work for X10, I use it successfuly!
Re: Monitor Device
« Reply #1 on: May 15, 2017, 02:25:53 PM »

You can change the monitored house code in AHP/tools/Hardware configuration.
If your trying to do this via your own code, are you using the AHP SDK?
Logged
Please Read Topic:
General Forum Etiquette
Before you post!

X10_Coder

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Re: Monitor Device
« Reply #2 on: May 15, 2017, 04:01:08 PM »

Hey, thanks for the reply.

      No I'm not using any third party DLL or SDK, it's all my own code. This way I don't have to worry when going to another platform or OS, I just compile the code with the only hurdle being the interfacing with either a Serial or USB Port.
Logged

Tuicemen

  • Administrator
  • Hero Member
  • ****
  • Helpful Post Rating: 282
  • Posts: 10497
  • I don't work for X10, I use it successfuly!
Re: Monitor Device
« Reply #3 on: May 15, 2017, 05:50:02 PM »

You might search(Google) for the CM11A serial protocol.
It may help point to how to switch monitored house codes.
Logged
Please Read Topic:
General Forum Etiquette
Before you post!

X10_Coder

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Re: Monitor Device
« Reply #4 on: May 15, 2017, 06:29:04 PM »

Thanks for the info.

     I have exhausted search engines looking for CM11A protocol and found a bunch of information, but nothing specific to setting the Monitor House Code and Device.

     I found a section on setting the clock with has a byte in the output buffer to clear the house code I think;

     send_buffer =  0x60;   // house (0:timer purge, 1:monitor clear, 3:battery clear

     I coded a Set_Clock routine and it works and I was able to set the clock no problem, and it appears that it did reset the monitored house code as it had been set to D, and now its set to A which I can only assume is what happens when you chose to set the bit above while setting the time to clear the monitor.
Logged

Brian H

  • Community Organizer
  • Hero Member
  • ***
  • Helpful Post Rating: 305
  • Posts: 13260
Re: Monitor Device
« Reply #5 on: May 15, 2017, 06:53:00 PM »

You are close. It is part of the Section 8 of attached text file. Set Interface Clock command. Bits 7-4

If you have not found it yet.
« Last Edit: May 15, 2017, 07:10:24 PM by Brian H »
Logged

X10_Coder

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Re: Monitor Device
« Reply #6 on: May 15, 2017, 07:18:35 PM »

Hey Brian:

       Thanks, that did it! The documentation I have only has specs for the low order bits of byte 6.

       (0:timer purge, 1:monitor clear, 3:battery clear)

       And even that appears to be incorrect from the protocol file you uploaded, or at least the battery clear flag seems to be wrong.

       7 to 4      Monitored house code
       3      Reserved
       2      Battery timer clear flag
       1      Monitored status clear flag
       0      Timer purge flag

       I already have it coded and works like dream, can't thank you enough for the help and protocol file.
Logged
 

X10.com | About X10 | X10 Security Systems | Cameras| Package Deals
© Copyright 2014-2016 X10.com All rights reserved.