Python Plugin Beta testers - please read this

Python and python framework

Moderator: leecollings

zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

Go back there as not able to have a running plugin on my windows system.

Have tried Kodi plugin (last version) and got error on myconnect
Now Yamaha plugin give me same result :

2017-02-07 21:28:43.249 (test) Initialized version 1.0.0, author 'thomasvillagers'
2017-02-07 21:28:43.300 (test) Debug log level set to: 'true'.
2017-02-07 21:28:43.300 (test) onStart called
2017-02-07 21:28:43.300 (test) Creating device 'Status'.
2017-02-07 21:28:43.311 (test) Creating device 'Volume'.
2017-02-07 21:28:43.320 (test) Creating device 'Source'.
2017-02-07 21:28:43.330 (test) Transport set to: 'TCP/IP', 127.0.0.1:50000.
2017-02-07 21:28:43.330 (test) Protocol set to: 'Line'.
2017-02-07 21:28:43.331 PluginSystem: Starting I/O service thread.
2017-02-07 21:28:43.331 (test) Connect directive received, transport connect initiated successfully.
2017-02-07 21:28:43.331 (test) Heartbeat interval set to: 20.
2017-02-07 21:28:44.340 (test) Calling message handler 'onConnect'.
2017-02-07 21:28:44.340 Error: (test) 'onConnect' failed 'TypeError':'onConnect() missing 2 required positional arguments: 'Status' and 'Description''.
2017-02-07 21:28:52.774 (test) Calling message handler 'onHeartbeat'.
2017-02-07 21:28:52.774 (test) onHeartbeat called. Connected: True
2017-02-07 21:28:52.774 Error: (test) Transport is not connected, write directive ignored.

Something should be wrong somewhere but not able to find by myself !!!!

this is my configuration :
platform W10 x64
Python x86 v: 3.5.3

my boot log :
2017-02-07 21:26:10.511 Domoticz V3.6591 (c)2012-2017 GizMoCuz
2017-02-07 21:26:10.511 Build Hash: 0176f5fc, Date: 2017-02-03 10:30:02
2017-02-07 21:26:10.574 EventSystem: reset all events...
2017-02-07 21:26:10.761 PluginSystem: Started, Python version '3.5.3'.
2017-02-07 21:26:10.792 WebServer(HTTP) started on address: :: with port 8080
2017-02-07 21:26:11.042 WebServer(SSL) started on address: :: with port 443
2017-02-07 21:26:11.042 Proxymanager started.
2017-02-07 21:26:11.042 Camera: settings (re)loaded
2017-02-07 21:26:11.058 TCPServer: shared server started...
2017-02-07 21:26:11.058 RxQueue: queue worker started...
2017-02-07 21:26:13.089 Wunderground: Worker started...
2017-02-07 21:26:13.089 Http: Worker started...
2017-02-07 21:26:13.089 Kodi: Started
2017-02-07 21:26:13.089 EventSystem: reset all events...
2017-02-07 21:26:13.089 EventSystem: reset all device statuses...
2017-02-07 21:26:13.089 EventSystem: Started
2017-02-07 21:26:13.105 PluginSystem: Entering work loop.
2017-02-07 21:26:13.605 OpenZWave: Starting...
2017-02-07 21:26:13.605 OpenZWave: Version: 1.4.2340.g63fa7f6.dirty
2017-02-07 21:26:13.636 OpenZWave: using config in: C:\Program Files (x86)\Domoticz\Config/
2017-02-07 21:26:14.121 RFXCOM: Using serial port: COM6
2017-02-07 21:26:18.989 OpenZWave: Driver Ready

Domoticz x86 version is running as service.

Appreciate any help !!
micha_pr
Posts: 82
Joined: Friday 24 October 2014 12:26
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Germany, near Berlin
Contact:

Re: Python Plugin Beta testers - please read this

Post by micha_pr »

Hi,

using 3.6694 - compiled version.
Python is running fine.

Tried to create a plugin with SetPoint Thermostat - but something is wrong...

I have added a SetPoint device, all seems to be ok.

Changing the value in UI - using the "Edit" button - the value will be changed in UI - and in database.

Requesting the value from Python it will not be changed - what I do wrong?
Only after restarting domoticz the last value will be shown.

I use normal debug while HeartBeat for testing:

Code: Select all

		Domoticz.Debug("Device:           " + str(x) + " - " + str(Devices[x]))
		Domoticz.Debug("Device ID:       '" + str(Devices[x].ID) + "'")
		Domoticz.Debug("Device Name:     '" + Devices[x].Name + "'")
		Domoticz.Debug("Device nValue:    " + str(Devices[x].nValue))
		Domoticz.Debug("Device sValue:   '" + Devices[x].sValue + "'")
		Domoticz.Debug("Device LastLevel: " + str(Devices[x].LastLevel))
and get only the old value for sValue

Code: Select all

2017-02-12 19:40:21.525  (hz11) onHeartbeat called
2017-02-12 19:40:21.525  (hz11) 'HardwareID':'9'
2017-02-12 19:40:21.525  (hz11) 'Port':'80'
2017-02-12 19:40:21.525  (hz11) 'Address':'127.0.0.1'
2017-02-12 19:40:21.525  (hz11) 'Version':'1.0.0'
2017-02-12 19:40:21.525  (hz11) 'HomeFolder':'/var/tmp/domo/dev-domoticz/plugins/Hzg/'
2017-02-12 19:40:21.525  (hz11) 'Mode3':'True'
2017-02-12 19:40:21.525  (hz11) 'Key':'Hzg1'
2017-02-12 19:40:21.525  (hz11) 'Mode6':'Debug'
2017-02-12 19:40:21.526  (hz11) 'Author':'nobody'
2017-02-12 19:40:21.526  (hz11) 'Name':'hz11'
2017-02-12 19:40:21.526  (hz11) Device count: 1
2017-02-12 19:40:21.526  (hz11) Device:           1 - ID: 7, Name: 'hz11 - Heizung2Set', nValue: 2, sValue: '25.00'
2017-02-12 19:40:21.526  (hz11) Device ID:       '7'
2017-02-12 19:40:21.526  (hz11) Device Name:     'hz11 - Heizung2Set'
2017-02-12 19:40:21.526  (hz11) Device nValue:    2
2017-02-12 19:40:21.526  (hz11) Device sValue:   '25.00'
2017-02-12 19:40:21.526  (hz11) Device LastLevel: 0
Value was set to 22 (as sample) - and is in SQLite database right.

How can I request the right sValue from Element?

Even if I update the nValue (19) for this Element in SQLite database, do not get the right one back...

Code: Select all

7|9|0000009|1|hz11 - Heizung2Set|1|242|1|0|0|12|255|19|22.00|2017-02-12 19:21:17|7|0.0|1.0|0.0|1.0|||0|0|0||
I think I miss something, any update for the Domoticz.Device - but do not get it.

Any idea?

Thanks in advance!
Michael Pruefer
----------------------------
http://www.zwave-review.com (German only)
http://www.SmartHome.Work (German only)
User avatar
G3rard
Posts: 669
Joined: Wednesday 04 March 2015 22:15
Target OS: -
Domoticz version: No
Location: The Netherlands
Contact:

Re: Python Plugin Beta testers - please read this

Post by G3rard »

G3rard wrote: @Dnpwwo,
I saw this post of @thomasvillagers describing the same issues.
He describes that Domoticz only freezes when a connection is established.

I can confirm that. I am using Domoticz v3.6630 and when the there is a connection with my Sonos, just changing a parameter in the hardware menu of the Sonos and pressing Update, will make Domoticz crash.
When the Sonos is not playing (so no info shown in the devices), then I can change and press Update without any problems.

Hopefully this gives you some more information to find the issue.
@Dnpwwo, were you able to reproduce this?
I am on Domoticz v3.6694 now and the issue still occurs.
This is the latest info the Domoticz log shows before Domoticz freezes.

Code: Select all

2017-02-12 21:55:48.509 (Sonos kantoor) Exiting work loop...
2017-02-12 21:55:53.344 (Sonos kantoor) Stopped.
Not using Domoticz anymore
User avatar
Dnpwwo
Posts: 820
Joined: Sunday 23 March 2014 9:00
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Melbourne, Australia
Contact:

Re: Python Plugin Beta testers - please read this

Post by Dnpwwo »

@micha_pr,

Can I get you to create a new topic specific to your plugin? Questions in this topic get buried and you may not get answers.

Normally I would expect the Domoticz device values are set via hardware code (C++ or Python) because it owns the interaction with the external hardware. On that basis the devices dictionary is not continually updated for performance reasons.

That said, if you have a need to handle other things updating Domoticz values outside the plugin use:

Code: Select all

Devices[x].Refresh()
to force synchronization as required.

@G3rard,

To be brutally honest, until last weekend there were 3 things that caused crashes, now there are 2 (that I know of).
  • Having disabled plugins on a Domoticz system that had notifications. Notifications would cause seg faults - now resolved.
  • On plugin shutdown Python sometimes throws an exception and exits when the interpreter is being deleted
  • On plugin shutdown for a connected plugin boost sometimes throws an exception
I'm having issues tracking down the last 2 because they appear to be timing related. On my Windows PC and Unbuntu 16.04 VirtualBox VM I get an error around 1% of the time or less. The last version I put on my Raspberry Pi suffered one of these very regularly when I hit the Update button in the Hardware page. I need to get the latest beta on there and work out how to interpret core dumps.
The reasonable man adapts himself to the world; the unreasonable one persists to adapt the world to himself. Therefore all progress depends on the unreasonable man. George Bernard Shaw
micha_pr
Posts: 82
Joined: Friday 24 October 2014 12:26
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Germany, near Berlin
Contact:

Re: Python Plugin Beta testers - please read this

Post by micha_pr »

Dnpwwo wrote:@micha_pr,
Can I get you to create a new topic specific to your plugin? Questions in this topic get buried and you may not get answers.
Thanks, I made a new topic - with additional question: http://www.domoticz.com/forum/viewtopic ... 65&t=16099

Thank you for plugin and help!
Michael Pruefer
----------------------------
http://www.zwave-review.com (German only)
http://www.SmartHome.Work (German only)
User avatar
G3rard
Posts: 669
Joined: Wednesday 04 March 2015 22:15
Target OS: -
Domoticz version: No
Location: The Netherlands
Contact:

Re: Python Plugin Beta testers - please read this

Post by G3rard »

Dnpwwo wrote: @G3rard,
To be brutally honest, until last weekend there were 3 things that caused crashes, now there are 2 (that I know of).
  • Having disabled plugins on a Domoticz system that had notifications. Notifications would cause seg faults - now resolved.
  • On plugin shutdown Python sometimes throws an exception and exits when the interpreter is being deleted
  • On plugin shutdown for a connected plugin boost sometimes throws an exception
I'm having issues tracking down the last 2 because they appear to be timing related. On my Windows PC and Unbuntu 16.04 VirtualBox VM I get an error around 1% of the time or less. The last version I put on my Raspberry Pi suffered one of these very regularly when I hit the Update button in the Hardware page. I need to get the latest beta on there and work out how to interpret core dumps.
Can I be of any help? On my Ubuntu Server 14.04 the crash happens every time when I press the Update button and the Sonos plugin is connected.
Not using Domoticz anymore
oohlaf
Posts: 21
Joined: Monday 06 February 2017 0:57
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: Python Plugin Beta testers - please read this

Post by oohlaf »

Hi plugin writers.

To ease plugin development and easy logging, I have integrated Domoticz logging into the Python logging framework.

This allows one to configure multiple loggers at various levels, log DEBUG stuff to a dedicated plugin.log without spamming your Domoticz logs, or vice versa ;)

Benefit of using the python log framework is that you can use its flexible argument handling (only parsed when the log level is actually set), you get full python stack traces for exceptions. You can add module, function and linenumber details to the log output, etc.

Have a look at my in progress plugin at https://github.com/oohlaf/domoticz-pioneer-avr, which doesn't do much yet to control a Pioneer AVR. That's besides the point of this post.

To use the logging stuff:
  • Copy domologger.py and example logging.json config
  • Import logging in your plugin.py and other modules
  • log = logging.getLogger(__name__) and use this object for logging (log.debug(), log.error(), etc)
  • Initialize the logging framework by calling setup_logging(base_path=Parameters['HomeFolder']) from onStart() in plugin.py
You don't have to use a logging.json file, you can also define a dictionary in plugin.py and supply that to setup_logging.

You configure log messages like this in your Domoticz log, for example. Note the module, function name and line number.

Code: Select all

2017-02-14 00:17:43.744 (Pioneer) DEBUG [plugin:onStart:76] onStart called
User avatar
Dnpwwo
Posts: 820
Joined: Sunday 23 March 2014 9:00
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Melbourne, Australia
Contact:

Re: Python Plugin Beta testers - please read this

Post by Dnpwwo »

@oohlaf,

This is really great ! When the framework goes into a stable build we need to think about hope we capture developer tools like this to make them broadly available.

One thing I noticed is that, even though I developed the framework, you know way more Python than I do :lol:
The reasonable man adapts himself to the world; the unreasonable one persists to adapt the world to himself. Therefore all progress depends on the unreasonable man. George Bernard Shaw
oohlaf
Posts: 21
Joined: Monday 06 February 2017 0:57
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: Python Plugin Beta testers - please read this

Post by oohlaf »

Thanks :)

Some more tips on the python plugin base template:

Code: Select all

global _plugin
_plugin = BasePlugin()

def onXXX(...):
    global _plugin
    _plugin.onXXX(...)
The global keyword is unnecessary here. By defining _plugin at the module level it is already global. Referring to a module level variable (or function) will also work without redefining the variable locally with keyword global.

So the following code will also work:

Code: Select all

_plugin = BasePlugin()

def onXXX(...):
    _plugin.onXXX(...)
The only time you need the global keyword is when you want to assign a different value in a local context to a globally defined variable.

Code: Select all

_plugin = None

def onStart():
    global _plugin
    _plugin = BasePlugin()
    _plugin.onStart()
oohlaf
Posts: 21
Joined: Monday 06 February 2017 0:57
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: Python Plugin Beta testers - please read this

Post by oohlaf »

I see you're making some code breaking changes by improving onNotification.

I would prefer also for more Pythonic naming conventions.
In Python
  • Class names use CapWord
  • Module level functions use lower_case_with_underscores
  • Function arguments use short lower case names, underscores if needed
Which would give:

Code: Select all

def on_start():
    pass

def on_notification(name, subject, text, status, priority, sound, image_file):
    pass
This will improve readability a lot when people are used to PEP8 code conventions. See https://www.python.org/dev/peps/pep-0008/
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

So my onConnect error has been identified:
http://www.domoticz.com/forum/viewtopic.php?f=6&t=16168

Now, Im trying to create my first python plugin to manage my samsung TV.
Is based on samsungctl. I have done 'pip install samsungctl', this have put all py under C:\Program Files (x86)\Python35-32\Lib\site-packages.
When I want to import samsungctl into my plugin.py, got this error:

"
2017-02-19 13:22:41.007 (Samsung TV Salon) Exiting work loop...
2017-02-19 13:22:41.007 (Samsung TV Salon) Stopped.
2017-02-19 13:22:41.075 Error: (SamsungTV) failed to load 'plugin.py', Python Path used was 'C:\Program Files (x86)\Domoticz\plugins\SamsungTV\;C:\Program Files (x86)\Python35-32\python35.zip;C:\Program Files (x86)\Python35-32\Lib\;C:\Program Files (x86)\Python35-32\DLLs\;C:\Program Files (x86)\Domoticz'.
2017-02-19 13:22:41.076 Error: (Samsung TV Salon) Module Import failed, exception: 'ImportError'
2017-02-19 13:22:41.076 Error: (Samsung TV Salon) Module Import failed: ' Name: samsungctl'
2017-02-19 13:22:44.335 (RFX433E) Temp + Humidity (433-TempSDBE)
"
As we can see, the "site-packages" directory is not included into the search made by the Plugin framework.
One I have copied by myself the samsungctl folder under "site-packages" to "Lib", all is working well.

Looks like any new python package installation is put under "site-packages"

Don't know if it's possible to include the "site-packages" to the Python Path ?
User avatar
Dnpwwo
Posts: 820
Joined: Sunday 23 March 2014 9:00
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Melbourne, Australia
Contact:

Re: Python Plugin Beta testers - please read this

Post by Dnpwwo »

@zak45,

I think you just do something like:

Code: Select all

import sys
sys.path.append('folder to be added')
The reasonable man adapts himself to the world; the unreasonable one persists to adapt the world to himself. Therefore all progress depends on the unreasonable man. George Bernard Shaw
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

That's great
will give it a try...
thanks a lot.
ubee
Posts: 66
Joined: Tuesday 10 February 2015 20:38
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: Sweden
Contact:

Re: Python Plugin Beta testers - please read this

Post by ubee »

I had a similar problem with a different package on a Linux system. I added a folder to the path with sys.path.append and by that the module could load. However, by that I ran into other problems and the whole plugin system became unstable. I couldn't figure out what caused this problem and I had to change the design eliminating the need for the specific Python package.

This is just a warning. Hopefully it will work for you.


Skickat från min ONEPLUS A3003 via Tapatalk
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

Thanks for the warning !!

like that :
"
import sys
sys.path.append(sys.prefix+'/lib/site-packages')
"
work for me. No other trouble, cross fingers.
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

Have installed the last beta v.3.6775, now I have a new error , not seeing previously :

2017-02-24 19:24:18.795 (RFX433E) Temp + Humidity (433-TempSalon)
2017-02-24 19:24:22.263 User: Admin initiated a switch command (650/Samsung TV Salon - Source/Set Level)
2017-02-24 19:24:22.270 (Samsung TV Salon) Calling message handler 'onCommand'.
2017-02-24 19:24:22.270 (Samsung TV Salon) onCommand called for Unit 2: Parameter 'Set Level', Level: -273.1499938964844, Connected: True
2017-02-24 19:24:26.545 (Samsung TV Salon) Calling message handler 'onHeartbeat'.
User avatar
Dnpwwo
Posts: 820
Joined: Sunday 23 March 2014 9:00
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Melbourne, Australia
Contact:

Re: Python Plugin Beta testers - please read this

Post by Dnpwwo »

@zak45,

There was another beta in the last 12 hours that should have resolved that issue :!: Give it a go
The reasonable man adapts himself to the world; the unreasonable one persists to adapt the world to himself. Therefore all progress depends on the unreasonable man. George Bernard Shaw
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

confirmed. fixed with v 3.6784
Have some other problems on previous release, but will do indeep test with this version before any report.

Thanks @Dnpwwo
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

So...
Here are my findings:
when the devices are disconnected, the onCommand is executed delayed and even sometimes never...
Spoiler: show
2017-02-24 21:36:54.096 User: Admin initiated a switch command (643/SamSung - Volume/Set Level)
2017-02-24 21:37:04.000 (SamSung) Device has disconnected - Maybe PowerOff
2017-02-24 21:37:04.052 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:37:04.153 (RFX433E) Energy (Compteur EDF)
2017-02-24 21:37:17.129 (RFX433E) Temp + Humidity (433-TempSDB)
2017-02-24 21:37:24.795 (RFX433E) Temp + Humidity (433-TempSDBE)
2017-02-24 21:37:25.054 (SamSung) Device has disconnected - Maybe PowerOff
2017-02-24 21:37:25.054 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:37:33.261 (RFX433E) Temp + Humidity (433-TempSalon)
2017-02-24 21:37:46.056 (SamSung) Device has disconnected - Maybe PowerOff
2017-02-24 21:37:46.056 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:37:51.644 CLuaHandler (updateDevice from LUA) : idx=42 nvalue=1 svalue=De 21h40 à 22h40 : Pas de précipitations invalue=1 signallevel=12 batterylevel=255
2017-02-24 21:38:00.376 (RFX433E) Temp + Humidity (433-TempSDB)
2017-02-24 21:38:03.790 (RFX433E) Temp + Humidity (433-TempSDBE)
2017-02-24 21:38:04.155 (RFX433E) Energy (Compteur EDF)
2017-02-24 21:38:07.059 (SamSung) Device has disconnected - Maybe PowerOff
2017-02-24 21:38:07.059 (SamSung) Calling message handler 'onCommand'.
2017-02-24 21:38:07.059 (SamSung) onCommand called for Unit 3: Parameter 'Off', Level: 0, Connected: False
2017-02-24 21:38:07.060 Error: (SamSung) Not Connected
2017-02-24 21:38:07.060 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:38:14.501 (RFX433E) Temp + Humidity (433-TempSalon)

but when devices are connected: response time is immediate, which is great !!!
Spoiler: show
2017-02-24 21:45:19.859 (SamSung) Exiting work loop...
2017-02-24 21:45:24.621 (SamSung) Stopped.
2017-02-24 21:45:28.293 () Device has disconnected - Maybe PowerOff
2017-02-24 21:45:28.419 (SamSung) Initialized version 1.0.0, author 'zak45'
2017-02-24 21:45:28.420 (SamSung) Debug log level set to: 'true'.
2017-02-24 21:45:28.420 (SamSung) 'HomeFolder':'C:\Program Files (x86)\Domoticz\plugins\SamsungTV\'
2017-02-24 21:45:28.420 (SamSung) 'Mode6':'Debug'
2017-02-24 21:45:28.420 (SamSung) 'Address':'192.168.1.20'
2017-02-24 21:45:28.420 (SamSung) 'Name':'SamSung'
2017-02-24 21:45:28.420 (SamSung) 'HardwareID':'11'
2017-02-24 21:45:28.420 (SamSung) 'Key':'SamsungTV'
2017-02-24 21:45:28.420 (SamSung) 'Mode5':'http://192.168.1.38:9876/send?deviceMac ... 3&repeat=3'
2017-02-24 21:45:28.420 (SamSung) 'Mode2':'samsungctl'
2017-02-24 21:45:28.420 (SamSung) 'Author':'zak45'
2017-02-24 21:45:28.420 (SamSung) 'Mode1':'legacy'
2017-02-24 21:45:28.420 (SamSung) 'Mode4':'0'
2017-02-24 21:45:28.420 (SamSung) 'Version':'1.0.0'
2017-02-24 21:45:28.420 (SamSung) 'Port':'55000'
2017-02-24 21:45:28.420 (SamSung) Device count: 3
2017-02-24 21:45:28.421 (SamSung) Device: 1 - ID: 641, Name: 'SamSung - Status', nValue: 0, sValue: ''
2017-02-24 21:45:28.421 (SamSung) Device ID: '641'
2017-02-24 21:45:28.421 (SamSung) Device Name: 'SamSung - Status'
2017-02-24 21:45:28.421 (SamSung) Device nValue: 0
2017-02-24 21:45:28.421 (SamSung) Device sValue: ''
2017-02-24 21:45:28.421 (SamSung) Device LastLevel: 0
2017-02-24 21:45:28.421 (SamSung) Device: 2 - ID: 642, Name: 'SamSung - Source', nValue: 0, sValue: ''
2017-02-24 21:45:28.421 (SamSung) Device ID: '642'
2017-02-24 21:45:28.421 (SamSung) Device Name: 'SamSung - Source'
2017-02-24 21:45:28.421 (SamSung) Device nValue: 0
2017-02-24 21:45:28.421 (SamSung) Device sValue: ''
2017-02-24 21:45:28.421 (SamSung) Device LastLevel: 0
2017-02-24 21:45:28.421 (SamSung) Device: 3 - ID: 643, Name: 'SamSung - Volume', nValue: 0, sValue: ''
2017-02-24 21:45:28.421 (SamSung) Device ID: '643'
2017-02-24 21:45:28.421 (SamSung) Device Name: 'SamSung - Volume'
2017-02-24 21:45:28.421 (SamSung) Device nValue: 0
2017-02-24 21:45:28.421 (SamSung) Device sValue: ''
2017-02-24 21:45:28.421 (SamSung) Device LastLevel: 0
2017-02-24 21:45:28.421 (SamSung) Connecting to: 192.168.1.20:55000
2017-02-24 21:45:28.425 (SamSung) Devices are connected - Initialisation
2017-02-24 21:45:28.426 (SamSung - Status) Updating device from 0:'' to have values 1:''.
2017-02-24 21:45:28.490 (SamSung) Update 1:'' (SamSung - Status)
2017-02-24 21:45:28.490 (SamSung - Source) Updating device from 0:'' to have values 1:''.
2017-02-24 21:45:28.547 (SamSung) Update 1:'' (SamSung - Source)
2017-02-24 21:45:28.547 (SamSung - Volume) Updating device from 0:'' to have values 1:''.
2017-02-24 21:45:28.608 (SamSung) Update 1:'' (SamSung - Volume)
2017-02-24 21:45:28.608 (SamSung) Heartbeat interval set to: 10.
2017-02-24 21:45:34.577 User: Admin initiated a switch command (642/SamSung - Source/Set Level)
2017-02-24 21:45:34.598 (SamSung) Calling message handler 'onCommand'.
2017-02-24 21:45:34.598 (SamSung) onCommand called for Unit 2: Parameter 'Set Level', Level: 10, Connected: True
2017-02-24 21:45:34.809 (SamSung) Send key : KEY_TV
2017-02-24 21:45:37.494 User: Admin initiated a switch command (642/SamSung - Source/Set Level)
2017-02-24 21:45:37.524 (SamSung) Calling message handler 'onCommand'.
2017-02-24 21:45:37.524 (SamSung) onCommand called for Unit 2: Parameter 'Set Level', Level: 10, Connected: True
2017-02-24 21:45:37.736 (SamSung) Send key : KEY_TV
2017-02-24 21:45:37.937 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:45:37.943 (SamSung) Devices connected - re-init
2017-02-24 21:45:45.238 (RFX433E) Temp + Humidity (433-TempSalon)
2017-02-24 21:45:47.970 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:45:47.975 (SamSung) Devices connected - re-init
2017-02-24 21:45:49.230 User: Admin initiated a switch command (643/SamSung - Volume/Set Level)
2017-02-24 21:45:49.231 (SamSung) Calling message handler 'onCommand'.
2017-02-24 21:45:49.231 (SamSung) onCommand called for Unit 3: Parameter 'Off', Level: 0, Connected: True
2017-02-24 21:45:49.441 (SamSung) Send key : KEY_MUTE
2017-02-24 21:45:49.441 (SamSung) Number of Mute activation: 1
2017-02-24 21:45:49.441 (SamSung - Volume) Updating device from 1:'' to have values 0:''.
2017-02-24 21:45:50.773 User: Admin initiated a switch command (643/SamSung - Volume/Set Level)
2017-02-24 21:45:50.823 (SamSung) Calling message handler 'onCommand'.
2017-02-24 21:45:50.823 (SamSung) onCommand called for Unit 3: Parameter 'Off', Level: 0, Connected: True
2017-02-24 21:45:51.036 (SamSung) Send key : KEY_MUTE
2017-02-24 21:45:51.036 (SamSung) Number of Mute activation: 2
2017-02-24 21:45:51.036 (SamSung - Volume) Updating device from 0:'' to have values 1:''.
2017-02-24 21:45:51.796 (RFX433E) Temp + Humidity (433-TempSDBE)
2017-02-24 21:45:53.104 (RFX433E) Temp + Humidity (433-TempSDB)
2017-02-24 21:45:57.989 (SamSung) Calling message handler 'onHeartbeat'.
2017-02-24 21:46:04.153 (RFX433E) Energy (Compteur EDF)
2017-02-24 21:46:07.990 (SamSung) Calling message handler 'onHeartbeat'.
When I click on the log buton for the device, no data are stored into DB, only Date&Time
Attachments
Capture.JPG
Capture.JPG (80.58 KiB) Viewed 2902 times
zak45
Posts: 953
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin Beta testers - please read this

Post by zak45 »

After removed HW, restart service, re-create HW: all is working on 3.6784 except still no data in log.
Thanks a lot.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest