InputOutputDevice Class?

Posted on
Sat Jul 11, 2020 10:43 am
papamac offline
User avatar
Posts: 131
Joined: Jan 29, 2014

InputOutputDevice Class?

I would like to define plugin devices that have multiple binary inputs and outputs in a single device. The InputOutputDevice class (indigo.MultiIODevice) defined in the Indigo Object Model seems to have pre-defined states that will suit my needs. How do I define an InputOutputDevice in Devices.xml? What is the device type? If necessary, I can define a "custom" device and then add all the needed states manually. Is this the correct approach, or is there some other Devices.xml device type?

Posted on
Sat Jul 11, 2020 1:23 pm
matt (support) offline
Site Admin
User avatar
Posts: 21417
Joined: Jan 27, 2003
Location: Texas

Re: InputOutputDevice Class?

We will probably be deprecating the MultiIODevice / InputOutputDevice class at some point in the future. It is currently used only by some EZIO Insteon modules.

Instead we recommend creating multiple devices (SensorDevice and RelayDevice in this case). To group them together logically (which will show each device as tab panels in the device dialog) you can use the device factory APIs. This forum thread has some details (note the SDK has a factory example)

The EZIO modules were first implemented before Indigo had the factory APIs / device groups. If we ever fully deprecate the MultiIODevice we'll be migrating the EZIO devices over to the factory API.

Image

Posted on
Sat Jul 11, 2020 6:13 pm
papamac offline
User avatar
Posts: 131
Joined: Jan 29, 2014

Re: InputOutputDevice Class?

Thanks Matt,

The HomeKit Bridge plugin uses the INSTEON garage door opener as its model for a garage door controller. It requires the states in the InputOutputDevice Class. I have several contact sensors and actuator relays (as separate indigo devices) and my goal is to map these into a single virtual garage door opener plugin device that will emulate the INSTEON device and work with the HomeKit Bridge. I can probably make this happen with a custom device type, but HomeKit Bridge will not recognize it automatically. It looks for a device attribute "sensorInputs" to discover the INSTEON garage door opener. I think that I can force it categorize my device as an opener anyway, but it would be nice if I could simply use a different device type in the Devices.xml and get both the attribute and the states.

David Krause, aka papamac

Posted on
Sun Jul 12, 2020 10:12 am
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: InputOutputDevice Class?

That would be a change to the HomeKit Bridge plugin - it should be a little less strict when it comes to defining what a garage door opener should be. I've never looked at the code, but that would be the appropriate place to make the change (if/until we define a built-in garage door type).

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 2 guests