Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


  • 0

XBMC for HCL


Question

Posted

Hello

I just got my HCL last week and i love it , had a couple of problems at first since i was a veralite user so it supports everything and has a lot of plugins , i'm not into LUA programming so i'm not missing much , for now i'm only missing the Danalock and Remotec AC IR extender compatibility with HCL which are things i can wait for but my main issue here actually is the XBMC plugin support since HCL doesn't use LUA

I saw this topic

Please login or register to see this link.

the virtual device and plugin that Shad did but it was done based on LUA , i believe all the commands are via http so i think it can be compatible with HCL , just need some adjustments to the plugin and the virtual device commands . convert all the LUA commands to HTTP commands ( if possible ) .

I just need a simple setup , i don't really looking for a full XBMC control from Fibaro ( it would be great though ) , but for now i'm looking for a simple lights actions ( turn off when start or play and turn on when pause and stop ) that's it .

So can this be done or the commands won't work unless it's LUA ? i have no programming experience so i don't really know

Any help would be appreciated

Thanks

Rami

Recommended Posts

  • 0
Posted

I didn't check because I don't have HCL for moment, but plugins on xbmc normally can work because it use API.

So you can create block for a scenario. But forget to do a remote control.

When I will have HCL, I will work on that

Please login or register to see this image.

/emoticons/default_wink.png" alt=";)" srcset="https://forum.fibaro.com/uploads/emoticons/[email protected] 2x" width="20" height="20" />

  • 0
  • Inquirer
  • Posted

    Yea , i totally understand , also you are busy with the new server , Currently i'm using my veralite as XBMC plugin and converted all the commands to be sent from vera to HCL using LUA in vera , so complicated and lots of work but it's the best i can do for now .

    I don't want the remote control for now but in order to use the block i have to configure the virtual device , right ? so for the block to turn off the light when XBMC start , what would be the trigger here ?

    • 0
    Posted

    No virtual device is for control and get information about media.

    You can start a scene in block. But you can't make different possibility.

    • 0
  • Inquirer
  • Posted

    Tried the API , for some reason it's not working , even from the browser , i have no idea why

    i'll wait till you get your HCL then , i'll use veralite as XBMC plugin for now

    [ Added: 2014-03-30, 01:21 ]

    I think i figured it out , Lights scenes are now working , and for it to be fully working i think i need to convert all HC2 LUA commands to non LUA and send them via HTTP

    anyone knows what's the non LUA format for this command ?

    Please login or register to see this code.

    and how to convert the others ?

    Thanks

    Rami

    • 0
    Posted

    add IP and port in your virtual device advanced panel and copy the code in a slider:

    Please login or register to see this code.

    not tested but i think it work

    Please login or register to see this image.

    /emoticons/default_icon_wink.gif" alt=";-)" />

    • 0
  • Inquirer
  • Posted

    Thanks Krikroff , but it didn't work

    The port in the virtual device should be 9090 in order for the virtual device to work , so the IP and port should be integrated in the code inside the button

    • 0
    Posted

    rmohsen, in HCL you can't use multiple IP and or port in the same virtual device, you can do that only with LUA (HC2), but i may have misunderstood your problem.

    • 0
  • Inquirer
  • Posted

    See the attached virtual device , if you can import it you will see what is my problem

    in order for this to work the vitrual device port should be 9090 but the http request should be with another port 8080 .

    I just made another virtual device with the port 8080 to test your code and it's working fine , problem would be integrating both .

    and since this is HCL all LUA commands ( like attached ) should be converted to non LUA

    Please login or register to see this attachment.

    • 0
    Posted

    rmohsen,

    No, you put lua code, and that don't work in HCL.

    • 0
    Posted

    Some code that should in the HCL:

    Turn off:

    Please login or register to see this code.

    Set volume in slider:

    Please login or register to see this code.

    Back Button:

    Please login or register to see this code.

    Home button:

    Please login or register to see this code.

    Info:

    Please login or register to see this code.

    Up:

    Please login or register to see this code.

    Left:

    Please login or register to see this code.

    Enter / OK:

    Please login or register to see this code.

    Right:

    Please login or register to see this code.

    Down:

    Please login or register to see this code.

    Show OSD:

    Please login or register to see this code.

    Play / Pause:

    Please login or register to see this code.

    Eject CD:

    Please login or register to see this code.

    Play music from file location:

    Please login or register to see this code.

    Open weather plugin:

    Please login or register to see this code.

    Post message:

    Please login or register to see this code.

    • 0
    Posted

    Hello, i'm new to fibaro as well. I got mine HCL this weekend.

    I was looking for something like this as well.

    I found the addon from Shad, but the addon doesn't work on the new XBMC 13 betaR2.

    i've done some tests this afternoon. And it works.

    Setting up the virtual device at port 9090 and the above codes of stevenvd work fine.

    The jsonrpc (http api) works on port 9090.

    only the code for volume isn't working.

    Please login or register to see this code.

    this is the correct one.

    Please login or register to see this code.

    if you like a list of all the jsonrpc codes just go to this link when xbmc is running

    :8080/jsonrpc and you get all the options.

    • 0
  • Inquirer
  • Posted

    Thanks Kime , i changed the volume command and now it's working .

    what's missing now is the duration and the ability to run the light scenes at night time only .

    • 0
    Posted

    the duration can be found here

    Please login or register to see this link.

    Don't know how to get the value in HC

    to get the night time only you will have te set in HC scene i guess. I'm new to that . But i guess its something to do with variables there.

    • 0
  • Inquirer
  • Posted

    Yea , but the thing is the XBMC is the trigger for the scene , the scene itself doesn't have any triggers so this must be done from XBMC some how , it needs plugin adjustments

    • 0
    Posted

    What you can do is, run a scene from XBMC.

    In that scene, set a variable (XBMC, playing) or (XBMC, paused).

    From another scene check if the variable has changed and if it is ... dark, evening, time, whatsover

    Please login or register to see this image.

    /emoticons/default_smile.png" alt=":)" srcset="https://forum.fibaro.com/uploads/emoticons/[email protected] 2x" width="20" height="20" /> and you have your check.

    • 0
  • Inquirer
  • Posted

    Thanks stevenvd , will try this tonight , hopefully it'll work .

    • 0
    Posted

    Like say stevend you can use global variable for set environment. But more difficult for pause and everything.

    I will do a release for that and new version of xbmc.

    • 0
  • Inquirer
  • Posted

    That's great news shad

    The guys at micasaverde had the same plugin. They implemented the day and night into the XBMC plugin. But veralite had a day or night plugin for it to check. I guess the XBMC plugin can check the status of a variable in HCL. Don't know if it's possible.

    Will be waiting for the update

    • 0
    Posted

    I already do that since a very long time and you also can do it.

    Juste make a scene to trigger variable for day or night.

    just add condition for two scene, day or night.

    • 0
  • Inquirer
  • Posted

    Yea , i did that already following your guide , i have a day or night variable working .

    Just tried what stevend suggested but it doesn't work , i don't think a variable can be used a trigger , only as a condition , right ?

    [ Added: 2014-04-02, 02:12 ]

    My bad , it's working now . Thanks a lot guys

    Hopefully the plugin update will make this a lot easier , i have 6 scenes just for XBMC

    Shad : Any idea how to start a scene when i start XBMC ? the plugin has some 1000 or 1001 values i don't know what they are for .

    Thanks

    Rami

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Answer this question...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    ×
    ×
    • Create New...