• Thanks for visiting the Kaleidescape Owners' Forum

    This forum is for the community of Kaleidescape owners, and others interested in learning about the system, equipment, services, and the company itself.

    It is run by a group of enthusiastic Kaleidescape owners and dealers purely as a service to this community.

    This board is not affiliated in any way with Kaleidescape, Inc.
    For official technical support, product information, or customer service, please visit www.kaleidescape.com

  • You are currently in "Guest" mode and not logged in with a registered account.

    The forum is free to use and most of the forum can be used by guests who are not registered....

    ... but we strongly encourage you to register for a full account. There is no cost to register for a full account.

    Benefits of registering for a full account:

    • Participate in the discussions! You must have a registered account to make posts on the forums. You will be able to start your own thread on a topic or question, or you can reply to other threads/discussions.
    • Use the "Conversation" feature (known as "private messaging" on other forums) to communicate directly with any of the other users here.
    • Access the Files area. The "resources" area of the forum contains many "Favorite Scene" and Script files that can dramatically increase the enjoyment of your Kaleidescape system. Go directly to great scenes in your favorite movies, created by other owners, and add automation to playback of your system with Scripts.
    • You won't see this annoying notice at the top of every screen!😊

    It's easy and free to register for the forum. Just click the "Register" button in the upper right corner of this page, and follow the instructions there.

OpenHAB for Kaleidescape

AlienWarlock

Well-known member
Here is a small write up on getting OpenHAB talking to your Kaleidescape. OpenHAB is an open source home automation system that is capable of interfacing all manner of technologies and systems into one integrated interface. I have configured my OpenHAB instance to interface with my Kaleidescape to retrieve and react to information about what is playing as well as send commands to the system. Utilizing various rules, OpenHAB has the ability to react to Kaleidescape's updates. While it would be nice to have a full OpenHAB binding for K instead of just this rule set, I find that this works fine for my needs. The 'tcp' binding must be loaded for this to work.


I have the following items of information populated when a movie is playing:

Title name
Play status
Chapter
Aspect ratio
Movie location
Media type
Title length
Title location

The following files (see attached zip) are used for OpenHAB to interface with K:

items/kaleidescape.items - set ip address of K server on first line
rules/kaleidescape.rules- set kZoneId to CPDID or serial number of kaleidescape zone to control
transform/k_*.map - lookup tables of various K status codes
transform/k_get_hour_minute.js - js to transform # of minutes integer to friendly display string
sitemaps/k_items.txt - items to add to sitemap for Kaleidescape


Rules specified in kaleidescape.rules:

rule "Handle Kaleidescape Event rule" - main rule to process status update messages from Kaleidescape
rule "Send K ENABLE_EVENTS rule" - call this rule once to enable event updates from Kaleidescape
rule "Send K DISABLE_EVENTS rule" - call this rule once to disable event updates from Kaleidescape
rule "K credits rolling" - this rule fires when credits roll and the movie was over 75 minutes long
rule "K movie night script" - called by switch 'K_movie_night' to start the script called 'Movie Night'
rule "K movie covers" - call this rule to make K go to movie covers screen, I use this from another rule that fires when I turn on my projector
rule "K screen saver off" - call this rule to turn off the K screen saver
rule "Handle K User Event" - handle K script action 'Send command to control system', the string is what was specified in the script create ui

Enjoy!
 

Attachments

Croptop

Well-known member
Thanks for posting this. I keep looking at OpenHAB but never seem to take the leap. This might be the push I needed.
 

Croptop

Well-known member
Finally took the plunge and got OpenHAB installed on a RPi2 that I had kicking around. Just starting to work my way through the configuration and setup so expect lots of dumb questions over the next little bit.

First one: What are you using as your OpenHAB server? I'm feeling like a RPi2 -- whilst suitable for experimenting -- is just a little bit too fragile for long term use. Any suggestions?
 

AlienWarlock

Well-known member
I started out my OpenHAB journey with a RPi2. I am currently running a RPi3 as my main rig. I haven't had any issues with reliability. While it does take several minutes for OpenHAB to start up fully, it is remarkably fast after that. Just make sure and use a good quality SD card.
 

Croptop

Well-known member
Thanks for the reply. As you hint at, it's the long term viability of the uSD card that I'm concerned about. I'll probably be keeping my eye out for a suitable replacement for long term but in my current phase of learning, the RPi2 will suffice.

I've managed to get all of my devices added to OpenHAB and have even successfully implemented rules to turn the lights on and off when playing, pausing and stopping in Plex.

I've attempted to integrate your sample files into my setup following your instructions above however I must have missed some key settings thing because I'm getting the following in my OpenHAB logs:

2018-07-29 19:43:26.779 [WARN ] [ui.internal.items.ItemUIRegistryImpl] - couldn't transform value in label because transformationService of type 'MAP' is unavailable

2018-07-29 19:43:26.794 [WARN ] [ui.internal.items.ItemUIRegistryImpl] - couldn't transform value in label because transformationService of type 'MAP' is unavailable

2018-07-29 19:43:26.810 [WARN ] [ui.internal.items.ItemUIRegistryImpl] - couldn't transform value in label because transformationService of type 'MAP' is unavailable

2018-07-29 19:43:26.822 [WARN ] [ui.internal.items.ItemUIRegistryImpl] - couldn't transform value in label because transformationService of type 'MAP' is unavailable

2018-07-29 19:43:26.838 [WARN ] [ui.internal.items.ItemUIRegistryImpl] - couldn't transform value in label because transformationService of type 'JS' is unavailable

2018-07-29 19:43:26.850 [WARN ] [ui.internal.items.ItemUIRegistryImpl] - couldn't transform value in label because transformationService of type 'JS' is unavailable
I copied the .map and .js files from your zipfile into my OpenHAB-conf/services directory. I have the TCP/UDP bindings installed and the IP address of my K Server entered in the "kaleidescape.items" file.

Any tips on where to start looking in order to figure out where I've messed up?
 
Last edited:

AlienWarlock

Well-known member
I guess for myself, OpenHAB was easier to get into having an IT background.

I think you need to install the MAP transform service to get the JS transformation errors to go away (see attached screen shot). Also if you haven't looked in the rules file yet, you will need to edit the kZoneId variable to be the CPDID (found in the 'Control' tab of the K component settings web interface) or the serial number of the zone that you want to control.
 

Attachments

o0OBillO0o

Well-known member
I guess for myself, OpenHAB was easier to get into having an IT background.

I think you need to install the MAP transform service to get the JS transformation errors to go away (see attached screen shot). Also if you haven't looked in the rules file yet, you will need to edit the kZoneId variable to be the CPDID (found in the 'Control' tab of the K component settings web interface) or the serial number of the zone that you want to control.
Thanks for replying.

Since you have an IT background, how did/do you address those who think they can build their own Kaleidescape?

I'll give this a shot. My hopes and dreams is to write an Apple Homekit implementation using Hombridge - https://github.com/nfarina/homebridge
 

AlienWarlock

Well-known member
how did/do you address those who think they can build their own Kaleidescape?
Ha, I gave up trying to convert people a long time ago ;) But if I did try to address those who would DIY their own K clone, I'm sure I would encounter the "I can setup a Plex server, NAS, and a bunch of Intel NUC clients for way less" attitude.

Yes it may be 'way less', but what is your spare time worth? For me, I don't want to constantly mess around with all that goes with the DIY route. Kaleidescape 'just works' and provides the best possible home theater experience. 'Nuff said!
 

Croptop

Well-known member
@AlienWarlock:
Thanks for the tip about installing the MAP transform service. I'm fairly certain that is the missing piece. I had already updated the .rules file and everything is working fine even with the MAP and JS warnings.

Now I just need to create a nice panel layout for my Android tablets and then it's on to the big project: writing a Kaleidescape binding. :)

@o0OBillO0o: For me, OpenHAB scratches my DIY itch. Plus it's about two orders of magnitude cheaper than Control4 (or AMX or Crestron). It's not as polished but it's also easier to roll up my sleeves and redo the programming on an OpenHAB system than it would be on Control4, AMX or Crestron (where I'd have to have a developer's account in order to have access to the software tools).

As for the Plex vs Kaleidescape argument, I actually have both and they co-exist very nicely. But my movies go on the Kaleidescape system and movie nights are always driven by K. Plex is just my DVR and music server.
 

o0OBillO0o

Well-known member
Gents - I couldn’t agree more.

Croptop- Plex is my system before Kaleidescape and now is a DVR only.

Keep us posted.
 
Top