coolweb / org.openhab.binding.mystromecopower

Openhab binding for MyStrom Eco Power Adapter
1 stars 2 forks source link

device is not in discovery table #8

Open jgovoni opened 8 years ago

jgovoni commented 8 years ago

Hello,

I tried to use this binding but I'm not able to connect to my power switch.

1) enabled the binding in openhab.cfg file 2) copy the org.openhab.binding.mystromecopower-1.8.0.jar in addons folder 3) create a new items file Switch SalonLampe_Switch "Lampe Salon" {mystromecopower="SalonLampe"} 4) create a new sitemap sitemap Gen label="House" { Frame label="Home" icon="house" { Switch item=SalonLampe_Switch } }

when I tried to use my new switch I got this:

18:47:48.052 [DEBUG] [o.b.m.i.MyStromEcoPowerBinding:196 ] - internalReceiveCommand() is called! 18:47:48.055 [DEBUG] [o.b.m.i.MyStromEcoPowerBinding:203 ] - item 'SalonLampe_Switch' is configured as 'SalonLampe' 18:47:48.056 [ERROR] [o.b.m.i.MyStromEcoPowerBinding:280 ] - Unable to send command to 'SalonLampe_Switch' device is not in discovery table 18:47:48.064 [INFO ] [runtime.busevents :22 ] - SalonLampe_Switch received command ON

I checked the device name in mystrom.ch and SalonLampe exists.

Thanks for your help, Jos

coolweb commented 8 years ago

Hello, the discovery of the devices is done on the start of openhab, so if you define a new item you need to restart openhab. You should see all of your discovered devices into the log file.

Le dim. 17 janv. 2016 18:57, jgovoni notifications@github.com a écrit :

Hello,

I tried to use this binding but I'm not able to connect to my power switch

1) enabled the binding in openhabcfg file 2) copy the orgopenhabbindingmystromecopower-180jar in addons folder 3) create a new items file Switch SalonLampe_Switch "Lampe Salon" {mystromecopower="SalonLampe"} 4) create a new sitemap sitemap Gen label="House" { Frame label="Home" icon="house" { Switch item=SalonLampe_Switch } } when I tried to use my new switch I got this:

18:47:48052 [DEBUG] [obmiMyStromEcoPowerBinding:196 ] - internalReceiveCommand() is called! 18:47:48055 [DEBUG] [obmiMyStromEcoPowerBinding:203 ] - item 'SalonLampe_Switch' is configured as 'SalonLampe' 18:47:48056 [ERROR] [obmiMyStromEcoPowerBinding:280 ] - Unable to send command to 'SalonLampe_Switch' device is not in discovery table 18:47:48064 [INFO ] [runtimebusevents :22 ] - SalonLampe_Switch received command ON

I checked the device name in mystromch and SalonLampe exists

Thanks for your help, Jos

— Reply to this email directly or view it on GitHub https://github.com/coolweb/org.openhab.binding.mystromecopower/issues/8.

jgovoni commented 8 years ago

Hello,

Thanks for your prompt reply. I did it, but it didn't fix the problem. I don't see the list of devices in the openhab.log, even if I added the org.openhab.binding.mystromecopower.MyStromEcoPowerBinding logger in the logback.xml file.

I missed something, for sure, but I'm not able to identify what i did wrong.

Regards, Jos

coolweb commented 8 years ago

Could try the logging with this:

<logger name="org.openhab.binding.mystromecopower" level="INFO"> <appender-ref ref="STDOUT" /> </logger>

jgovoni commented 8 years ago

Nothing after restart.

I then added

to logback_debug.xml file.

The only two lines referencing MyStrom:

22:09:31.026 [DEBUG] [b.m.i.MyStromEcoPowerActivator:34 ] - MyStromEcoPower binding has been started. 22:09:35.403 [DEBUG] [i.internal.GenericItemProvider:341 ] - Start processing binding configuration of Item 'SalonLampe_Switch (Type=SwitchItem, State=Uninitialized)' with 'MyStromEcoPowerGenericBindingProvider' reader.

coolweb commented 8 years ago

Could you paste the section of your config file where you define the logging of the binding?

Le lun. 18 janv. 2016 22:32, jgovoni notifications@github.com a écrit :

Nothing after restart.

I then added

to logback_debug.xml file. The only two lines referencing MyStrom:

22:09:31.026 [DEBUG] [b.m.i.MyStromEcoPowerActivator:34 ] - MyStromEcoPower binding has been started. 22:09:35.403 [DEBUG] [i.internal.GenericItemProvider:341 ] - Start processing binding configuration of Item 'SalonLampe_Switch (Type=SwitchItem, State=Uninitialized)' with 'MyStromEcoPowerGenericBindingProvider' reader.

— Reply to this email directly or view it on GitHub https://github.com/coolweb/org.openhab.binding.mystromecopower/issues/8#issuecomment-172659881 .

jgovoni commented 8 years ago

<logger name="org.openhab.binding.mystromecopower" level="DEBUG" />

jgovoni commented 8 years ago

<logger name="org.openhab.binding.mystromecopower" level="DEBUG" />

coolweb commented 8 years ago

I don't know what's your problem but I think it's related with your configuration. You say that you add to logback.xml, and then to logback_debug.xml. Pay attention that openhab only use logback.xml. So if you want to use logback_debug.xml, you need to rename it to logback.xml.

I do a test with my file:

<logger name="org.openhab.binding.mystromecopower" level="DEBUG"> <appender-ref ref="STDOUT" /> </logger>

Then in the log: 2016-01-22 12:43:44.919 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Do mystrom discovery 2016-01-22 12:43:44.972 [DEBUG] [o.b.m.i.MyStromEcoPowerBinding] - execute() method is called! 2016-01-22 12:43:44.974 [DEBUG] [o.b.m.i.MyStromEcoPowerBinding] - Do login for user 'yyyyy@yyyyy' 2016-01-22 12:43:54.506 [DEBUG] [o.b.m.i.MyStromEcoPowerBinding] - Logon successfull 2016-01-22 12:43:54.586 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - get devices... 2016-01-22 12:43:56.336 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Devices discovery sucessfull, found '13' devices 2016-01-22 12:43:56.371 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Chauffe eau', mystrom device id:'0013C12AE829' 2016-01-22 12:43:56.377 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'backup', mystrom device id:'0013C12AE801' 2016-01-22 12:43:56.400 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Machine ? laver', mystrom device id:'0013C12DC940' 2016-01-22 12:43:56.406 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Chauffage v?randa int', mystrom device id:'64002D0001E4' 2016-01-22 12:43:56.465 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Chauffage v?randa fen?tre', mystrom device id:'0013C12DC938' 2016-01-22 12:43:56.483 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Ordinateur', mystrom device id:'0013C12DC647' 2016-01-22 12:43:56.508 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Camera', mystrom device id:'0013C12DC84C' 2016-01-22 12:43:56.517 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Vitrine', mystrom device id:'0013C12AE6F8' 2016-01-22 12:43:56.543 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Cong?lateur/Frigo', mystrom device id:'0013C12DC93A' 2016-01-22 12:43:56.548 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Autres/Cafeti?re', mystrom device id:'0013C12AE805' 2016-01-22 12:43:56.594 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Tv/HomeCin?ma', mystrom device id:'0013C12DC944' 2016-01-22 12:43:56.642 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'Halog?ne/Multi prises', mystrom device id:'0013C12DC939' 2016-01-22 12:43:56.654 [INFO ] [o.b.m.i.MyStromEcoPowerBinding] - Mystrom device name: 'BBoxTv', mystrom device id:'0013C12AE568'

coolweb commented 8 years ago

Also which version of openhab did you use?