Author Topic: climate control  (Read 7113 times)

klovell

  • Guru
  • ****
  • Posts: 205
    • View Profile
climate control
« on: May 16, 2011, 07:30:29 pm »
The idea hit me like truck Yesterday, There's a room in my house with a IR controllable AC plus I have an extra usb uirt i'm not using.  It only seems right that these two devices get put to use together. 

I created a template from scratch (to the best of my ability) for a window air conditioning unit and I configured it to be control VIA IR.  When I'm all said and done I do not see where I can add IR codes for the device I just created.  I even tried using a template that's already created, RAS-Series Air Conditioning, I figured I could just change the IR codes to those for my unit but I still don't see or understand how to add the IR codes.  This is how I setup some of my A/V devices (picked a template and changed the codes) but that made more sense to me.   

Can someone point me in the right direction?  I have the remote for the air conditioner so I'll just need to learn the codes.

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5549
  • DOES work for LinuxMCE.
    • View Profile
Re: climate control
« Reply #1 on: May 16, 2011, 09:36:24 pm »
The Climate plugin does not inherit from the infrared code, and thus climate devices can't currently be IR controlled (unless somebody has checked in code for this at some point...)

You wouldn't want to do this anyway, IR devices are a compromise for the A/V world, and as such, you'll run into all sorts of funky quirks because IR is unidirectional and incapable of communicating back its state to the system.

-Thom

klovell

  • Guru
  • ****
  • Posts: 205
    • View Profile
Re: climate control
« Reply #2 on: May 16, 2011, 10:48:00 pm »
The Climate plugin does not inherit from the infrared code, and thus climate devices can't currently be IR controlled (unless somebody has checked in code for this at some point...)

You wouldn't want to do this anyway, IR devices are a compromise for the A/V world, and as such, you'll run into all sorts of funky quirks because IR is unidirectional and incapable of communicating back its state to the system.

-Thom

Is that the only reason not to do it?  Are you saying Lmce may send a command to turn on the AC when it's already on, which will inadvertently turn it off?  As long as that's the only issue I could live with that.  I don't really want Lmce to automate anything with the AC like turning it on when the room gets to hot.  It would be more on demand, like i'm to lazy to get up to turn on the AC, i'll just use LMCE. 
 
I'm a little confused about your first statement.  The climate plugin does not inherit from the infrared code. You said climate devices can't be controlled by IR but then you said unless someone checked in codes.  How do I check in the codes?  I have the remote for the AC so I can probably create a dummy template or use an existing template for an IR controlled a/v device so I can get the codes.  Sorry if we're going in circles, I just want to understand this better.

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5549
  • DOES work for LinuxMCE.
    • View Profile
Re: climate control
« Reply #3 on: May 16, 2011, 11:01:52 pm »
I meant, unless a programmer checked in changes to the C++ code in the climate plugin.

-Thom

klovell

  • Guru
  • ****
  • Posts: 205
    • View Profile
Re: climate control
« Reply #4 on: May 17, 2011, 08:15:01 pm »
Thanks Thom.  I don't suppose there is a way to duct tape it?  I'm thinking I'll re-wrap my usb uirt and save it for another day, but I'm curious...

Kezza

  • Veteran
  • ***
  • Posts: 146
    • View Profile
Re: climate control
« Reply #5 on: May 18, 2011, 02:32:16 am »

I have http://wiki.linuxmce.org/index.php/Toshiba_RAS-series_Air_Condition which is controlled by IR but using ruby commands in template.

Maybe you could build a template similar to that? Template ID is 2131

IR seems the only option for this A/C (maybe a very expensive controller available somewhere) but as Thom pointed out its not able to communicate the state of the system which is extremely frustrating when others in the house use the A/C remote and LMCE does not know if its been turned on or off.

magner

  • Veteran
  • ***
  • Posts: 81
    • View Profile
Re: climate control
« Reply #6 on: May 18, 2011, 01:51:52 pm »
Hi Klovell,

Kooma and I have managed to get my IR lights working with the following method.

Be warned thou, its not ideal as the scenario will apper under the media group on your orbitor screen.

1. First go to the web admin. From the top menu select "Wizard" -> "Devices" -> "A/V equipment".

2. Scroll down to the bottom of the page, where you see buttons Add device.

3. From the next window, "LinuxMCE :: Pick Device Template", do the following

   a. As I want to create a totally new template, I first pressed "Add manufacturer", then another window opens where I wrote the manufacturer to be "NoName" and pressed "Add". Then close the window and select the newly added manufacturer from the previous window.
   b. Then I selected "Device Category" to be "LCD < TVs/Plasmas/LCD's/Projectors < AV" (this might not make a difference, though)
   c. As the device to be added is new and doesn't exist yet, press "Add device template".
4. Now you get a series of question windows to fill-in. They are quite well explained, but I'll walk them through here
4.1. "What is the name or model # *": "Imaginary model"
    "How do you control this model": Infrared
    "Create device": check the checkbox
    Press "Next".
4.2. Delays, used existing values expect for the first one, changed that from 7000 ms to 3000. And "Next"
4.3. This totally depend on your case, for the same of simplicity I used "no" and blank for the two fields.
4.4. Again, up to your case here. I used the "toggle" option.
4.5. Here going with #2, and checked "PC" as "external"/"VGA", and "TV" as "LiveTV"/"-Please select-".
4.6. No DSP modes...
4.7. Left these as default (4 and 2).
4.8. "Sorry that we don't already have codes for manufacturer noname, device category LCD. Please take a moment to add them so other users can benefit from your efforts. Thanks!
Type in a description for the infrared group and click Add i/r group: "testing 12-6-2010". Press "Add i/r group".
5. Now you can edit the ir codes. Make sure you have "The device is controlled via": "USB UIRT Embedded..."
5.1. From the "Power" section, "Toggle power not implemented:" press "Click to add".
6.1 After learning IR code and successfully testing code I scrolled down to the bottom of "edit IR codes" page and pressed update button.
6.2a Next I created a scenario for the template. Go to Wizard>Scenario>Media Scenarios. specify the entertainment area you would like to use device in.
6.2b Then choose device from the drop down menu. 
6.2c Now to do quick reload and you should see your scenario under the media section of MD screen.

Thanks to Kooma for most of these steps. Legend.

Hope this helps.

Please let me know if you manage to get this method working under the climate control group on orbitor screen. What I would like to do is move my ir lights away from media group to the lighting group.

I have a question, does anyone know if it is possible for me to change the climate control group. I have IR blinds I use, what I would like is a group for this instead of having blind scenario stuck under my media group.

Also is it possible to use my IR commands when building an events handler. last time I tried to create an action, to a sensor being tripped my IR template did not apper from the drop down menu for respond to event.

Cheers
Dan 

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5549
  • DOES work for LinuxMCE.
    • View Profile
Re: climate control
« Reply #7 on: May 18, 2011, 02:56:13 pm »
That is a nasty ass hack, and to do it right will require changes to the Climate plugin. As I am swamped, I can't do those changes, but somebody should.

-Thom

Marie.O

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 3676
  • Wastes Life On LinuxMCE Since 2007
    • View Profile
    • My Home
Re: climate control
« Reply #8 on: May 18, 2011, 03:44:17 pm »
I have a question, does anyone know if it is possible for me to change the climate control group. I have IR blinds I use, what I would like is a group for this instead of having blind scenario stuck under my media group.

Did you try to go into Webadmin / Show Devices Tree / My Scenarios / Media Scenarios, select the scenario in question, and change Array Type from Media Scenarios to Climate Scenarios followed by a quick reload and quick regen or full regen?

bugui

  • Veteran
  • ***
  • Posts: 70
    • View Profile
Re: climate control
« Reply #9 on: December 11, 2011, 09:51:56 am »
Ups, It works Posde!!!  ;)

klovell

  • Guru
  • ****
  • Posts: 205
    • View Profile
Re: climate control
« Reply #10 on: December 12, 2011, 07:01:42 pm »
Ups, It works Posde!!!  ;)

Yea, but Thom was right.  I tried this and it worked but It got really funky.  I would turn it off using Lmce not knowing that my wife already did so in reality I turned it on, so now it's just sitting there cooling a room that no one is using.  It sat there running for 3 days one weekend becuase of a mix up like that.  I guess if the AC is in a room that you're always in and you don't plan to automate it at all and just use Lmce as a over complicated remote control, it works.