Create virtual hardware
Moderator: leecollings
-
- Posts: 25
- Joined: Monday 08 December 2014 13:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Create virtual hardware
In the Domoticz API/JSON documentation:
https://www.domoticz.com/wiki/Domoticz_ ... 7s#Counter
there is a command to create virtual hardware:
/json.htm?type=command¶m=addhardware&htype=15&port=1&name=Sensors1&enabled=true
Is there a reason to use type=15 or are other types possible and is a list available with alternatives in order to create other types of hardware like general etc.
https://www.domoticz.com/wiki/Domoticz_ ... 7s#Counter
there is a command to create virtual hardware:
/json.htm?type=command¶m=addhardware&htype=15&port=1&name=Sensors1&enabled=true
Is there a reason to use type=15 or are other types possible and is a list available with alternatives in order to create other types of hardware like general etc.
-
- Posts: 40
- Joined: Friday 29 January 2016 16:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Netherlands
- Contact:
Re: Create virtual hardware
Type 15 = dummy hardware layer. In the GUI this is like adding it manually. If you have the sources look at RFXnames.h in main for the list of htypes (~67 these days) A number of other htypes looks to be supported with this Json command: look at webServer.cpp:: Cmd_AddHardware. I have no experience with handling other htype hardware. Dummy works great 

- gizmocuz
- Posts: 2484
- Joined: Thursday 11 July 2013 18:59
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Top of the world
- Contact:
Re: Create virtual hardware
Just create the hardware via the hardware page (dummy) and not via the json call... much easier
Quality outlives Quantity!
-
- Posts: 25
- Joined: Monday 08 December 2014 13:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware
And the next step in order to create a Plugwise device with Lan interface, is that also possible to do in a similar way?
-
- Posts: 25
- Joined: Monday 08 December 2014 13:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware + device
Hi,
I’m a little bit confused about how to setup a hardware and device to connect a Plugwise Smile and Stretch to my Domoticz server.
In order to do this I can setup a dummy device or I can add new hardware as P1 Smart Meter with LAN interface and complete this with IP and port. So far so good.
The next step is to setup/correct the settings of a device. By creating a dummy device there is no new device created, by adding a new P1 Smart Meter LAN hardware a temp+humidity device is created.
Both are wrong because I like to monitor my energy consumption.
My question is how the change my device settings like type to general and subtype to kWh and m3 etc.
I’m a little bit confused about how to setup a hardware and device to connect a Plugwise Smile and Stretch to my Domoticz server.
In order to do this I can setup a dummy device or I can add new hardware as P1 Smart Meter with LAN interface and complete this with IP and port. So far so good.
The next step is to setup/correct the settings of a device. By creating a dummy device there is no new device created, by adding a new P1 Smart Meter LAN hardware a temp+humidity device is created.
Both are wrong because I like to monitor my energy consumption.
My question is how the change my device settings like type to general and subtype to kWh and m3 etc.
-
- Posts: 115
- Joined: Sunday 11 January 2015 16:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware
Search the forum on how to setup Plugwise. It isn't supported by Domoticz directly.
-
- Posts: 25
- Joined: Monday 08 December 2014 13:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware
This has basically nothing to do with a setup of Plugwise itself. It is a the way to setup in general new dummy hardware and needed and correct device in Domoticz what troubles me .
-
- Posts: 115
- Joined: Sunday 11 January 2015 16:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware
I meant how to setup Plugwise within Domoticz. There are several threads about this subject. Dummy hardware has nothing to do with Plugwise (and wont work), neither has the P1 hardware in Domoticz.
-
- Posts: 25
- Joined: Monday 08 December 2014 13:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware
I'm created a dummy hardware with a device. I can see that the data is displayed as data in the list.
In utility the data is displayed only in small characters in the second line and in my dashboard not at all.
I've tried a lot of differed hardware settings, P1 Smart Meter, RFX Meter, General, etc, but without results and I'm looking for suggestions-
- Posts: 40
- Joined: Friday 29 January 2016 16:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Netherlands
- Contact:
Re: Create virtual hardware
I have done the same. I update the gas (and electricity) values with a separate daemon. I already made an interface to collect the P1 values and store that in an Access database. I want to keep that for now, hence i did not use P1 hardware interface in Domoticz.
Where it shows 35.036 for you, it shows my gasmeter value and where it shows 0.000m3 for you it will show the delta to the previous reading (calculated in Domoticz).
You may have a brand new gasmeter, but your value looks low to me. My value is 2200.863. Are you sending your gasmeter values as a float ?
I have attached the daemon (written in Python) and documentation as it might help you. The deamon takes input from a file and has flexible configuration options for the information to parse (often needed to capture the gas information).
regards,
Paul
Where it shows 35.036 for you, it shows my gasmeter value and where it shows 0.000m3 for you it will show the delta to the previous reading (calculated in Domoticz).
You may have a brand new gasmeter, but your value looks low to me. My value is 2200.863. Are you sending your gasmeter values as a float ?
I have attached the daemon (written in Python) and documentation as it might help you. The deamon takes input from a file and has flexible configuration options for the information to parse (often needed to capture the gas information).
regards,
Paul
- Attachments
-
- domo-up.gz
- (80 KiB) Downloaded 223 times
-
- Posts: 25
- Joined: Monday 08 December 2014 13:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Create virtual hardware - kWh instead of Watt
Thanks, almost everything is now working fine.
The only thing I like is to change is the text : "Watt" into "kWh" for a regular Usage type device with Electric subtype
(I use these settings because this gives me the overall and correct information from my P1 Smart Meter and no daily incemental data.)
Is it possible to change the text in the DB directly of with a JSON command?
Unfortunately /json.htm?type=command¶m=getuservariables gives no list of values neither does
/json.htm?type=command¶m=getuservariable&idx=IDX
Just
{
status: "OK",
title: "GetUserVariable"
}

The only thing I like is to change is the text : "Watt" into "kWh" for a regular Usage type device with Electric subtype
(I use these settings because this gives me the overall and correct information from my P1 Smart Meter and no daily incemental data.)
Is it possible to change the text in the DB directly of with a JSON command?
Unfortunately /json.htm?type=command¶m=getuservariables gives no list of values neither does
/json.htm?type=command¶m=getuservariable&idx=IDX
Just
{
status: "OK",
title: "GetUserVariable"
}
Who is online
Users browsing this forum: No registered users and 1 guest