Caution
This is the documentation for the current development branch of the CometVisu. It is possible that some of the described features are not yet available in the current release.
Also there might be lots of errors in this documentation as some parts of the content have been translated by an online translation service.
Power entity
Description
The <cv-power-entity>
component displays the electrical power of a specific device. It consists of an icon,
a value in the unit Watt and a colored circle around both, which can optionally also contain a progress bar
(e.g. to display the charge level of a battery).
The Power Entity is essentially a Svg round value with predefined
color scheme, icon and special mapping for the value. These presets are bound to the type
attribute.
There are the following Power entity types:
|
|
|
|
|
|
|
The following example:
<cv-power-entity type="pv">
<cv-address transform="DPT:5.001" mode="read">1/4/2</cv-address>
</cv-power-entity>
is the same as:
<cv-svg-round-value icon="knxuf-weather_sun" styling="tile-pv-power" mapping="tile-kilo-watts">
<cv-address transform="DPT:5.001" mode="read">1/4/2</cv-address>
</cv-svg-round-value>
Adding values
It is also possible to display multiple values added in this component. If you have multiple individual PV modules, you can sum them up with an Address-Group and the quantity of values that are not equal to 0 will be displayed next to the icon.
<cv-power-entity type="pv">
<cv-address-group operator="+">
<cv-address transform="DPT:12.001" mode="read">1/4/2</cv-address>
<cv-address transform="DPT:12.001" mode="read">1/4/3</cv-address>
</cv-address-group>
</cv-power-entity>
Connections
Multiple Power Entities can be connected to each other. This is represented by a line between 2 entities. This line can have an arrowhead at one of the two ends to represent a direction. The direction then represents the flow of energy, e.g. from the PV module to the house.
More information about the connections can be found in the Energy-Widget.
Allowed attributes
Element |
Attribute |
|||
---|---|---|---|---|
Name |
Content |
Description |
||
cv-power-entity |
id |
string |
ID of this element. |
|
title |
string |
Title of this element. |
||
icon |
string |
Defines the icon, usually the icon is pre-defined by the type, but can be overridden by this attribute. |
||
radius |
integer |
Radius of the circle. |
||
stroke |
integer |
Stroke width of the circle border. |
||
min |
decimal |
Minimum value. |
||
max |
decimal |
Maximum value. |
||
foreground-color |
string |
Color of the value bar. |
||
background-color |
string |
Color of the background bar. |
||
styling |
string |
Change the color of the displayed value depending on its value. See also styling |
||
mapping |
string |
Map the bus value to a different value, text or symbol for displaying. See also mapping |
||
format |
string |
Formatting of the value (printf syntax). |
||
x |
integer |
Position of this element on the x-axis. |
||
y |
integer |
Position of this element on the y-axis. |
||
row |
decimal |
Row this element is placed in. |
||
column |
decimal |
Column this element is placed in. |
||
rowspan |
decimal |
Number of rows this element spans |
||
colspan |
decimal |
Number of columns this element spans |
||
type |
pv, battery, grid, consumer, charger, heatpump or house |
Type of this entity. |
||
connect-to |
string |
Connect to another cv-power-entity. |
||
connect-from |
string |
Connect from another cv-power-entity. |
||
connection-points |
string |
Define where the connection line should start and end. |
Allowed child elements and their attributes
Element |
Attribute |
|||
---|---|---|---|---|
Structure |
Name |
Content |
Description |
|
|
transform |
string |
Defines the datatype in the backend, e.g. DPT:1.001 for KNX datapoint type 1.001. |
|
mode |
disable, read, write or readwrite |
Defines if this address is only used to |
||
value |
string |
Fixed value sent to this address. |
||
on |
click, down or up |
Event on which a |
||
target |
string |
Target in the parent widget the value if this address should be use for. The possible values depend on the parent widget. |
||
format-pos |
decimal |
Position for format string when multiple addresses are used. |
||
qos |
decimal |
Only MQTT: QoS |
||
retain |
true or false |
Only MQTT: retain flag |
||
selector |
string |
Only MQTT: JSON selector |
||
backend |
string |
Optional name of the backend this address belongs to. |
||
mapping |
string |
Map the bus value to a different value, text or symbol for displaying. See also mapping |
||
format |
string |
Formatting of the value (printf syntax). |
||
delay |
positiveInteger |
Optional delay in milliseconds that a write-request to this address is delayed. |
||
send-mode |
on-change or always |
Usually the elements that are using this address receive an update-event only when that value hast changed ( |
||
|
string |
The GA (like: 12/0/7) for KNX-backends, the item name for openHAB-backend or the MQTT topic |
Element |
Attribute |
|||
---|---|---|---|---|
Structure |
Name |
Content |
Description |
|
|
operator |
+, -, * or / |
Math operator used for calculation. |
|
round |
true or false |
Round the result. |
||
factor |
float |
Multiply the result with this value. |
||
|
transform |
string |
Transformation of the bus system value to be shown. |
|
mode |
disable, read, write or readwrite |
“disable” deactivates the communication, “read” will only fetch data from the backend, “write” will only write to it and an address with “readwrite” will be both, read from and written to. |
||
variant |
string |
|||
format-pos |
decimal |
Position for format string when multiple addresses are used. |
||
selector |
string |
Only MQTT: JSON selector |
||
qos |
decimal |
Only MQTT: QoS |
||
retain |
true or false |
Only MQTT: retain flag |
||
ignore-error |
true or false |
Only MQTT: ignore decode errors. |
||
|
string |
The GA (like: 12/0/7) for KNX-backends, the item name for openHAB-backend or the MQTT topic |