Plugin : read Type en subType of a device

Python and python framework

Moderator: leecollings

Post Reply
JonasF
Posts: 4
Joined: Saturday 18 March 2017 12:52
Target OS: Linux
Domoticz version: beta
Location: France
Contact:

Plugin : read Type en subType of a device

Post by JonasF »

Hi

I can not find how to read type and subtype of a device in python.

How to read it ? Via a sql request? If so what is the best way to access the sqlite database ?
User avatar
Dnpwwo
Posts: 819
Joined: Sunday 23 March 2014 9:00
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Melbourne, Australia
Contact:

Re: Plugin : read Type en subType of a device

Post by Dnpwwo »

@JonasF,

Pull Request #1370 has Added Type and SubType attributes to the Device object. Should be in beta in a day or so.
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
JonasF
Posts: 4
Joined: Saturday 18 March 2017 12:52
Target OS: Linux
Domoticz version: beta
Location: France
Contact:

Re: Plugin : read Type en subType of a device

Post by JonasF »

Oh ! Perfect !

Tanks !
ffes
Posts: 51
Joined: Thursday 26 January 2017 23:11
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: NL
Contact:

Re: Plugin : read Type en subType of a device

Post by ffes »

Dnpwwo wrote:Pull Request #1370 has Added Type and SubType attributes to the Device object. Should be in beta in a day or so.
That opens up possibilities!
moengiant
Posts: 28
Joined: Monday 25 January 2016 6:33
Target OS: Windows
Domoticz version:
Contact:

Re: Plugin : read Type en subType of a device

Post by moengiant »

Did you ever create a python script for type and subtype? I'm looking to do the same and store device per room by types in a user defined string variables as this is not possible via the API.
I'd rather have a bottle in front of me than a frontal lobotomy
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest