Python Scripting - Control Indigo Home Automation

Does anyone here have any experience using KM and Indigo home automation together?

I use Indigo (https://www.indigodomo.com) software along with different switches and plugin modules to control various studio lighting and equipment power. Indigo can utilize Python to trigger and/or control various aspects of the software. I've been able to RECEIVE python script triggers IN Keyboard Maestro to trigger macros but I haven't been successful at sending to Indigo to trigger elements in it.

I've been going through a number of Python postings in the forum here but nothing has helped. I've looked at official Python tutorials but what I need to do is simple and specific yet this is like looking for a needle in a haystack.

Hey Troy,

You likely have some configuration in your macOS shell environment that is not replicated in Keyboard Maestro.

KM does not pick up alterations in the macOS environment – the user has to manage that.

-Chris

Hi Chris,

Thank you for the response. Unfortunately, I don't know anything about Python yet. It's on my list of things to learn from the ground up, but that's going to require time that I don't currently have. Any thoughts about a direction I can take to just focus in on the basics for this type of need?

Troy

For this problem, start at the other end. You want to send "something" from KM to Indigo -- what "inputs" does Indigo accept? Python may be one way to generate and send "something" to Indigo, but it probably isn't the only way.

If all that's needed is to submit some data from KM to an Indigo API endpoint, there's simpler ways than learning Python!

Hi Nieg,

Unfortunately, the previous method was AppleScript until Indigo deprecated it and replaced with Python to add more sophisticated development options for third-party plugins. I WAS able to send simple commands up until that point.

I'm trying to start a post within the Indigo Support Forum but can't login for some incomprehensible reason so I'll move forward from that direction to find solutions once that issue is resolved.

This is just one out of half a dozen unique tech bridges I need to cross for what I'm currently doing and is the lowest priority, but I figured I should get the dialogs started to eventually figure it out one way or another.

-Troy

Ah -- so you mean you want to write your own Indigo triggers, rather than call an existing trigger from KM? Then yes, that would appear to require Python.

Be aware that, apparently, they're still using Python 2.7 -- so don't get caught out by learning all the new-fangled python3 stuff!

Exactly. Thank you. I've been reviewing various articles about Python to be able to use it within various graphics apps as well, so I know that this is probably gonna be a sizable endeavor. And I understood the reasons for Indigo switching to Python, but was very disappointed to see AppleScript dumped after having just figured out how to do the simple things that I needed.

I know this can be done and I'm guessing that the answer will be found over at Indigo. I'll update content here in case it's helpful to other KM users.

Newest versions of indigo use Python 3.

https://www.indigodomo.com/blog/2022/05/10/announcing-indigo-20221/

Success!

With help/instruction from the Indigo support forum we got it working. Just in case anyone else using KM also uses Indigo, following is the Indigo forum post:

https://forums.indigodomo.com/viewtopic.php?f=123&t=27048&p=217224#p217224

Thanks to everyone for their input on this KM post. I'll definitely have more questions and seek answers in the forum as I dive into Python and other KM related topics moving forward.

-Troy

1 Like