项目作者: jimmy93

项目描述 :
Home Assistant - Covid-19 Malaysia daily sensor
高级语言: Python
项目地址: git://github.com/jimmy93/Malaysia-Daily-Covid-19-Home-Assistant.git
创建时间: 2021-06-05T14:39:32Z
项目社区:https://github.com/jimmy93/Malaysia-Daily-Covid-19-Home-Assistant

开源协议:GNU General Public License v3.0

下载


Home Assistant Covid 19 Malaysia

Home Assistant - Covid-19 Malaysia daily sensor based on csv from this great repo

Intro

Default Covid-19 data for Home Assistant can get from this https://www.home-assistant.io/integrations/coronavirus
But i found it only display the cumulative data. Im thinking of how to display the data daily as seen on TV.
Just found this great repo who commit daily data for Malaysia as CSV.

How It Work

  1. Made the py code to read CSV (read the last row) and convert it to json format
  2. Extract the output json as sensor on Home Assistant configuration.yaml

How To Setup

  1. Download covid.py and put in on local folder as configuration.yaml
  2. copy code from configuration.yaml to our HA.

Sensor create from configuration.yaml

  1. covid_kes_baharu
  2. covid_kes_mati
  3. covid_jumlah_kes
  4. covid_jumlah_kes_mati
  5. covid_kes_sembuh
  6. covid_jumlah_kes_sembuh
  7. covid_icu
  8. covid_support

Additional Option

  1. You may vary your sensor accordingly such as to add unit_of_measurement or anything else.
  2. Check out csv data by state from source repo.

Thanks

Thanks to @wnarifin
FB: A Jimm Al
my fav community
Home Assistant Malaysia https://www.facebook.com/groups/homeassistantmalaysia
Kelab DIY Smart Home https://www.facebook.com/groups/694589921358327
Telegram Group: Smart Home Malaysia https://t.me/smart_home_malaysia