Sinclair81 / Homebridge-Logo-Platform

Homebridge Platform Plugin for Siemens LOGO!s, written in TypeScript.
9 stars 2 forks source link

Logo Platform not appearing in Apple Home #5

Closed NikVandewouwer closed 2 years ago

NikVandewouwer commented 2 years ago

Hi All,

Currently my 2 blinds are controlled via a LOGO! (0BA8) from Niko up/down switches installed by my electrician when we build the house (2016) (I don't know anything about programming a PLC).

Now I would like to to control my blinds with Apple Homekit (Apple Home, Siri,..) which I think is possible with this homebridge plugin but I'm struggling a lot, but making small progress. Here's what I already achieved:

However whatever I do, I see nothing appearing in Apple Home (so I don't even know what I'm looking for!!)

This is my config file (I now configured a switch as device, maybe that has to be blinds, but also that does not work)

{ "bridge": { "name": "Homebridge 6F4E", "username": "0E:AB:BE:9B:6F:4E", "port": 51207, "pin": "031-45-154" }, "accessories": [], "platforms": [ { "name": "Config", "port": 8581, "platform": "config" }, { "platform": "SamsungTizen", "devices": [ { "name": "Samsung QLED", "ip": "10.2.1.205", "mac": "70:B1:3D:8F:BF:0C", "delay": 500, "inputs": [ { "type": "input", "name": "Telenet", "value": "digitalTv" }, { "type": "app", "name": "Netflix", "value": "3201907018807" }, { "type": "app", "name": "Youtube", "value": "111299001912" }, { "type": "app", "name": "Plex", "value": "3201512006963" }, { "type": "input", "name": "Playbox", "value": "HDMI2" } ] } ] }, { "platform": "LogoPlatform", "name": "Siemens Logo", "interface": "snap7", "ip": "10.2.1.5", "logoType": "0BA8", "remoteTSAP": "0x0200", "localTSAP": "0x0200", "queueInterval": 100, "updateInterval": 10000, "debugMsgLog": 1, "retryCount": 5, "pushButton": 1, "devices": { "name": "Q1", "type": "switch", "switchGet": "Q1", "switchSetOn": "V1.0", "switchSetOff": "V1.1" } } ] }

I really would appreciate some help to get to the next steps and start configuring it properly!

Sinclair81 commented 2 years ago

Hi, The LOGO settings are incorrect. -> "devices": must be an array! So everything in "[...]" -> remove: "queueInterval": 100, With your settings, you should see an error message in the Homebride console that the plugin cannot be loaded.

It should work like this: { "platform": "LogoPlatform", "name": "Siemens Logo", "interface": "snap7", "ip": "10.2.1.5", "logoType": "0BA8", "remoteTSAP": "0x0200", "localTSAP": "0x0200", "updateInterval": 10000, "devices": [ { "name": "Q1", "type": "switch", "debugMsgLog": 1, "pushButton": 1, "switchGet": "Q1", "switchSetOn": "V1.0", "switchSetOff": "V1.1" } ] }

NikVandewouwer commented 2 years ago

HI @Sinclair81

Thanks for the swift response!

I created the config with the UI, so now I changed it directly in the JSON file (not an issue for me, I know JSON very well - know that now the UI config does not show the devices properly, so something for you to improve :-)).

"devices" is now an array with 1 object and now I see an accessory (type=blind) in Apple Home however nothing happens when I press it, but this was to be expected since I use the default values, but at least one step closer to success!!

Now I need your help again, how can I figure out what values I need to put for the different attributes of the device? I'm assuming now I'm entering the domain of the LOGO! PLC, which I don't know ANYTHING about.. Any advice? (I was able to download the programme via Soft Comfort application)

This is now my config (I completely started from scratch, now using type: blind { "bridge": { "name": "Homebridge DF25", "username": "0E:6C:AC:D7:DF:25", "port": 51628, "pin": "817-50-455", "advertiser": "bonjour-hap" }, "accessories": [], "platforms": [ { "name": "Config", "port": 8581, "platform": "config" }, { "devices": [ { "name": "Blind-1", "type": "blind", "blindConvertValue": 1, "blindSetTargetPos": "VW26", "blindGetTargetPos": "VW28", "blindGetPos": "VW28", "blindGetState": "VW30" } ], "name": "LOGO", "interface": "snap7", "ip": "10.2.1.5", "logoType": "0BA8", "localTSAP": "0x0200", "remoteTSAP": "0x0200", "platform": "LogoPlatform" }, { "devices": [ { "name": "Samsung QLED", "ip": "10.2.1.205", "mac": "70:B1:3D:8F:BF:0C", "delay": 500, "inputs": [ { "type": "input", "name": "Telenet", "value": "digitalTv" }, { "type": "app", "name": "Youtube", "value": "111299001912" }, { "type": "app", "name": "Plex", "value": "3201512006963" }, { "type": "app", "name": "Netflix", "value": "3201907018807" }, { "type": "input", "name": "Playbox", "value": "HDMI2" } ] } ], "platform": "SamsungTizen" } ] }

Sinclair81 commented 2 years ago

Config UI, worked at the beginning. But now something has changed.

I've already changed the ReadMe, it now says that the Config UI doesn't work.

I'm happy to help you. Can you email me the program for the LOGO? Have you downloaded the original LOGO program to your PC? Or just loaded a new one from your PC onto the LOGO? In the worst case you have to look in the distribution box what exactly is connected where to the LOGO, all inputs and outputs.

NikVandewouwer commented 2 years ago

I've reached out to you via email, much appreciated!