My problem described above about graphs not appearing seems to be gone after 0.117.6 update.
Hello everyone!
Is it possible to use a template instead of using a fixed number in the color_thresholds section?
So, instead of doing this:
color_thresholds:
- value: 0
color: "#4d68ff"
- value: 300
color: "#66ffe6"
Iād like to use a template, like this:
color_thresholds:
- value: '{{ states("input_number.value_1") | int }}'
color: "#4d68ff"
- value: '{{ states("input_number.value_2") | int }}'
color: "#66ffe6"
Iāve tried the code above but it does not work.
Try to add this option to the secondary sensor
y_axis: secondary
Great, thatās exactly what I needed. Thanks
Hello,
I am quite new to HomeAssintant, trying to implement mini graph card.
I successfully installed HACS and added the frontend āmini graph cardā.
But how do I get the card into my lovelace? I want to display the CPU temperature of the Pi.
Can anyone give me detailed instruction how to add the card???
Thanks
Mike
Hi,
thanks for the link.
I did install HACS according to the instructions, I am able to download the mini graph card, then I tried to add the respective custom card card by choosing the option at the bottom. I edited the following:
- type: custom:mini-graph-card
entities:- sensor.cpu_temperature
show:
icon: false
name: CPU
state: false
- sensor.cpu_temperature
But I still an error!
Any Idea?
Do I have to add a line to a .yaml file after HACS installation?
Mike
Sorry to bother, I was able to add a card to my locelace but I do not see any graph!
I used the examples, I see the value e. g. the Pi temperature but no graph at all!
Any idea folks
Mike
Everything is stated in the documentation.
Can you share your code?
Here is my code of the card:
type: ācustom:mini-graph-cardā
entities:
- sensor.cpu_temperature
name: CPU
hours_to_show: 12
points_per_hour: 6
Even without the last 2 lines it doesnāt work. As I said before, the temperature is shown but no graph!
Try this
type: 'custom:mini-graph-card'
name: CPU
entities:
- entity: sensor.cpu_temperature
I tried but get the following Error:
Error: No visual editor available for: custom:mini-graph-card
I even canāt save the card!
Thatās not an error. Itās information telling you there is no UI and you have to define the card using yaml. The reason you canāt save is because your configuration is incorrect.
Paste it correctly formatted and we will be able to help.
Do you have sensor.cpu_temperature configured to be recorded by recorder component? For me this type of symptoms indicate that graph have no data to draw the chart, only current state of sensor is available.
Hi,
no I havenāt configured the cpu sensor to be recorded! How do I do this?
I have this in config.yaml
sensor:
- platform: command_line
name: CPU
command: "cat /sys/class/thermal/thermal_zone0/temp"
unit_of_measurement: "Ā°C"
value_template: '{{ value | multiply(0.001) | round(1) }}'
The result of the code I wrote above
HI,
I changed my configuration.yaml like you posted above and I used the code for the card like you posted but still no help! It shows the current temperature, no background colour nor graph.
What about the recorder component mirekmal mentioned?
Find this sensor in the entities and use the entity of this sensor on the card.
Probably the sensor entity will be sensor.cpu
Thats what I did! I changed my config.yaml like you posted and of course I changed the entity to sensor.cpu! But still no graph
Again, what about he recorder component mirekmal mentioned?
You do not have a recorder set in config.yaml where sensors are excluded