Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Best Way to map IOLink for Garage Door Opening #121

Open
jjschwarz opened this issue Oct 28, 2018 · 11 comments
Open

Best Way to map IOLink for Garage Door Opening #121

jjschwarz opened this issue Oct 28, 2018 · 11 comments

Comments

@jjschwarz
Copy link

I have an I/O-Linc Controller setup in Indigo 7.2 which acts as both a garage door opener on output 1 and a garage door status detector on the binary input. I added it as a "garage door opener" homekit type object in HomeKit Bridge, however that seems to have no effect on anything.

Is there a better way I should map this object that would allow for open/close and sensor functionality?

@dscottbuch
Copy link

Jason,

I have 3 of these set up as Garage doors and all work well. My goodnight scene makes sure they're closed. While there might be an easier way this is was worked for me. For EACH door I had to set up 2 devices, 1 variable and 3 actions. Below are screen shots of the setup. When I was running Homebridge myself the sense of the variables was reversed, i.e. false was closed and true was open but with HomeKit-Bridge I had to reverse the sense. Not sure why but this is but it works this way. I add the Virtual Device, Truck Garage, to HomeKit-Bridge as a garage door opener.

screen shot 2018-10-28 at 10 30 12 am
screen shot 2018-10-28 at 10 29 51 am
screen shot 2018-10-28 at 10 29 44 am
screen shot 2018-10-28 at 10 29 22 am
screen shot 2018-10-28 at 10 29 07 am
screen shot 2018-10-28 at 10 29 00 am
screen shot 2018-10-28 at 10 28 25 am
screen shot 2018-10-28 at 10 27 44 am

@jjschwarz
Copy link
Author

OK, our setups seem very different and I really don't want to change what is working in every other place to make homekit work.

I have the input sensor and legacy sensor settings opposite of your settings.

I assume you did all of the virtual device setup just to get HomeKit working with these devices? I ask because I haven't needed that with just regular Indigo, so I wanted to make sure you were using them just for integration purposes. My understanding was you created an action group and virtual device just to map these, but they seem to maintain state based on the action not on the sensor, is that correct?

I really want to make sure on that, because I want to only maintain the open/close state based on the input sensor because we have had issues with the door closed being interrupted before.

@jjschwarz
Copy link
Author

When I mention maintained state above, I meant it appears the variable contains the state, but I do not see anything linking the variable to the door sensor.

@Colorado4Wheeler
Copy link
Collaborator

Colorado4Wheeler commented Oct 28, 2018 via email

@jjschwarz
Copy link
Author

I collected all of the logs, but I put them on the other door ticket. I will update them on this one too.

@jjschwarz
Copy link
Author

Versions

  • Plugin: v1.0.2

Configuration

"platforms": [
        {
                "protocol": "http", 
                "name": "HomeKit Bridge Server", 
                "listenPort": "8445", 
                "platform": "Indigo2", 
                "host": "127.0.0.1", 
                "debug": false, 
                "serverId": REMOVED, 
                "port": "8558"
        }
], 
"bridge": {
        "username": "REMOVED", 
        "name": "HomeBridge", 
        "pin": "XXX-YY-ZZZ", 
        "port": "51826"
}, 
"accessories": [], 
"description": "HomeKit configuration generated by HomeKit Bridge on 2018-10-28 13:21:08.655000 for device HomeBridge"

Homebridge Log / Command Output

[2018-10-28 13:21:09] Registering platform 'homebridge-camera-ffmpeg.Camera-ffmpeg'
[2018-10-28 13:21:09] ---
[2018-10-28 13:21:09] Loaded plugin: homebridge-indigo2
[2018-10-28 13:21:09] Registering platform 'homebridge-indigo2.Indigo2'
[2018-10-28 13:21:09] ---
[2018-10-28 13:21:09] Loaded config.json with 0 accessories and 1 platforms.
[2018-10-28 13:21:09] ---
[2018-10-28 13:21:09] Loading 1 platforms...
[2018-10-28 13:21:09] [HomeKit Bridge Server] Initializing Indigo2 platform...
[2018-10-28 13:21:09] [HomeKit Bridge Server] HomeKit Bridge base URL is http://127.0.0.1:8558
[2018-10-28 13:21:09] [HomeKit Bridge Server] HomeKit Bridge serverId is REMOVED
[2018-10-28 13:21:09] Loading 0 accessories...
Load homebridge-camera-ffmpeg.Camera-ffmpeg
[2018-10-28 13:21:09] [HomeKit Bridge Server] Listening on port 8445
[2018-10-28 13:21:09] [HomeKit Bridge Server] HomeKit Bridge request: http://127.0.0.1:8558/HomeKit?cmd=deviceList&serverId=REMOVED
[2018-10-28 13:21:09] [HomeKit Bridge Server] Discovered Device GarageDoorOpener (ID cf7bc734d2bf3726aaf6a6d4d45f22933198fd1d7b4c2b2248a1dcf0673f020a): Garage Door
[2018-10-28 13:21:09] [HomeKit Bridge Server] Initializing platform accessory 'Garage Door'...

[2018-10-28 13:21:10] Homebridge is running on port 51826.
[2018-10-28 13:21:12] [HomeKit Bridge Server] Garage Door: get(TargetDoorState) => 1
[2018-10-28 13:21:12] [HomeKit Bridge Server] Garage Door: get(CurrentDoorState) => 1
[2018-10-28 13:21:12] [HomeKit Bridge Server] Garage Door: get(ObstructionDetected) => false
[2018-10-28 13:21:55] [HomeKit Bridge Server] Garage Door: set(TargetDoorState) 1 -> 0
[2018-10-28 13:21:55] [HomeKit Bridge Server] HomeKit Bridge request: http://127.0.0.1:8558/HomeKit?objId=905523190&serverId=35246918&jkey=cf7bc734d2bf3726aaf6a6d4d45f22933198fd1d7b4c2b2248a1dcf0673f020a&cmd=setCharacteristic&TargetDoorState=0
[2018-10-28 13:21:55] [HomeKit Bridge Server] Garage Door: updateCharacteristicValue(TargetDoorState): 0 -> 1
[2018-10-28 13:48:18] [HomeKit Bridge Server] Garage Door: get(ObstructionDetected) => false
[2018-10-28 13:48:18] [HomeKit Bridge Server] Garage Door: get(CurrentDoorState) => 1
[2018-10-28 13:48:18] [HomeKit Bridge Server] Garage Door: get(TargetDoorState) => 1
[2018-10-28 13:56:15] [HomeKit Bridge Server] Garage Door: get(TargetDoorState) => 1
[2018-10-28 13:56:15] [HomeKit Bridge Server] Garage Door: get(CurrentDoorState) => 1
[2018-10-28 13:56:15] [HomeKit Bridge Server] Garage Door: get(ObstructionDetected) => false

Device Simulation Report

[code]
##### DEVICE DATA DUMP #####

address : 15.19.E2
analogInputCount : 0
analogInputs : []
batteryLevel : None
binaryInputCount : 1
binaryInputs : [True]
binaryOutputCount : 1
binaryOutputs : [False]
buttonGroupCount : 1
configured : True
description : 
deviceTypeId : 
displayStateId : binaryOutputsAll
displayStateImageSel : PowerOff
displayStateValRaw : 0
displayStateValUi : 0
enabled : True
energyAccumBaseTime : None
energyAccumTimeDelta : None
energyAccumTotal : None
energyCurLevel : None
errorState : 
folderId : 1666810870
globalProps : MetaProps : (dict)
id : 905523190
lastChanged : 2018-10-27 20:49:33
lastSuccessfulComm : 2018-10-27 20:49:33
model : I/O-Linc Controller
name : Garage Door
ownerProps : emptyDict : (dict)
pluginId : 
pluginProps : com.eps.indigoplugin.homekit-bridge : (dict)
protocol : Insteon
remoteDisplay : True
sensorInputCount : 0
sensorInputs : []
states : States : (dict)
     analogInputsAll : no analog input values (string)
     binaryInput1 : on (on/off bool)
     binaryInput1.ui : closed (string)
     binaryInputsAll : 1 (string)
     binaryOutput1 : off (on/off bool)
     binaryOutputsAll : 0 (string)
     sensorInputsAll : no sensor input values (string)
subModel : 
supportsAllLightsOnOff : False
supportsAllOff : False
supportsStatusRequest : True
version : 54

##### DEVICE SIMULATION DATA #####

Service : 
	alias : Garage Door
	model : 
	subModel : 
	indigoType : indigo.MultiIODevice
	pluginType : Built-In
	type : GarageDoorOpener
	desc : Garage Door Opener
	objId : 905523190
	serverId : 35246918
	invertOnState : False
	convertFahrenheit : False
	required : (List)
		ObstructionDetected : False
		TargetDoorState : 1
		CurrentDoorState : 1
	optional : (List)
		LockTargetState
		Name
		LockCurrentState
	native : True
	requiresPlugin : (List)
	actions : (List)
		Action : (HomeKitAction)
			Characteristic : TargetDoorState
			When : equal
			Value : 0 (int)
			Value2 : 0 (int)
			Command : iodevice.setBinaryOutput
			Arguments : [905523190, 0, True]
			monitors : {905523190: 'state_binaryInput1'}
		Action : (HomeKitAction)
			Characteristic : TargetDoorState
			When : equal
			Value : 1 (int)
			Value2 : 0 (int)
			Command : iodevice.setBinaryOutput
			Arguments : [905523190, 0, True]
			monitors : {905523190: 'state_binaryInput1'}
		Action : (HomeKitAction)
			Characteristic : CurrentDoorState
			When : equal
			Value : STUB (str)
			Value2 : 0 (str)
			Command : STUB
			Arguments : [905523190, 0]
			monitors : {905523190: 'state_binaryInput1'}
	loadOptional : False
	characterDict : (Dict)
		ObstructionDetected : False
		TargetDoorState : 1
		CurrentDoorState : 1


[/code]

@dscottbuch
Copy link

dscottbuch commented Oct 28, 2018 via email

@dscottbuch
Copy link

Regarding the state I forgot the triggers. Here they are.
screen shot 2018-10-28 at 12 06 09 pm
screen shot 2018-10-28 at 12 06 05 pm
screen shot 2018-10-28 at 12 05 56 pm
screen shot 2018-10-28 at 12 05 51 pm

@dscottbuch
Copy link

Again, this is what I needed for homebridge and homebridge-indigo. I did not try to change it with HomeKit-Bridge

@dscottbuch
Copy link

So, I apologize but I didn't realize I could just use the IO linc as a garage control in HomeKit-Bridge. I just reconfigured them a bit and they work great, as is. I did have to use the Invert State checkbox and also change my configuration of the Link for the sense of the 'Input Sensor' On/Off to Off. but it work just great now with only the IO linc device.

@jjschwarz
Copy link
Author

dscottbuch: Sounds like you and I have the same settings now, but I am still having no luck with my setup actually working. I think this might be related to another case, which is I found none of my doors are actually updating in HomeKit since I upgraded from the NPM module to the integrated software. I hope Colorado4Wheeler can assist me in tracking down the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants