Advertisement
abeksis

shekel

Apr 16th, 2022
1,379
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 13.04 KB | None | 0 0
  1. input_text:
  2.   energy_total_steam_collector_yesterday:
  3.     name: ' קולט אדים - אנרגיה אתמול'
  4.  
  5.   energy_total_washing_machine_yesterday:
  6.     name: ' מכונת כביסה - אנרגיה אתמול'
  7.  
  8.   energy_total_laundry_dryer_yesterday:
  9.     name: ' מייבש כביסה - אנרגיה אתמול'
  10.  
  11.   energy_total_dishwasher_yesterday:
  12.     name: ' מדיח כלים - אנרגיה אתמול'
  13.  
  14.   power_monthly_cost:
  15.     name: 'תשלום חודשי - מוצרי חשמל'  
  16.  
  17. input_select:
  18.   power_bill_socket_cutoff_for_month:
  19.     name: Power Bill Socket Cutoff for Month
  20.     options:
  21.      - Odd
  22.       - Even
  23.  
  24. #################################################################
  25. #   קולט אדים - צריכת חשמל בכסף                                 #
  26. #################################################################
  27. sensor:
  28.   - platform: template
  29.     sensors:
  30.       power_calc_total_steam:
  31.         friendly_name: "קולט אדים - תשלום חודשי"
  32.         value_template: "{{ ((states('sensor.tasmota_energy_total') | float) * (states('input_text.power_nis_per_kwh') | float) + (states('input_text.power_monthly_cost') | int ))|round(1)}}"
  33.         unit_of_measurement: "₪"
  34.  
  35.  
  36.   - platform: template
  37.     sensors:
  38.       power_calc_today_steam:
  39.         friendly_name: "קולט אדים - תשלום יומי"
  40.         value_template: "{{ ((states('sensor.tasmota_energy_today') | float) * (states('input_text.power_nis_per_kwh') | float))|round(1) }}"
  41.         unit_of_measurement: "₪"
  42.  
  43.  
  44.   - platform: template
  45.     sensors:
  46.       power_calc_yesterday_steam:
  47.         friendly_name: "קולט אדים - אתמול"
  48.         value_template: "{{ ((states('sensor.tasmota_energy_yesterday') | float) * (states('input_text.power_nis_per_kwh') | float))|round(2) }}"
  49.         unit_of_measurement: "₪"      
  50.  
  51. #################################################################
  52. #    מכונת כביסה - צריכת חשמל בכסף                              #
  53. #################################################################
  54.  
  55.   - platform: template
  56.     sensors:
  57.       power_calc_total_washing_machine:
  58.         friendly_name: "מכונת כביסה - תשלום חודשי"
  59.         value_template: "{{ ((states('sensor.washing_machine_energy_total') | float) * (states('input_text.power_nis_per_kwh') | float) + (states('input_text.power_monthly_cost') | int ))|round(1)}}"
  60.         unit_of_measurement: "₪"
  61.  
  62.   - platform: template
  63.     sensors:
  64.       power_calc_today_washing_machine:
  65.         friendly_name: "מכונת כביסה - תשלום יומי"
  66.         value_template: "{{ ((states('sensor.washing_machine_energy_today') | float) * (states('input_text.power_nis_per_kwh') | float))|round(1) }}"
  67.         unit_of_measurement: "₪"
  68.  
  69.   - platform: template
  70.     sensors:
  71.       power_calc_yesterday_washing_machine:
  72.         friendly_name: "מכונת כביסה - אתמול"
  73.         value_template: "{{ ((states('sensor.washing_machine_energy_yesterday') | float) * (states('input_text.power_nis_per_kwh') | float))|round(2) }}"
  74.         unit_of_measurement: "₪"
  75.        
  76.  
  77. #################################################################
  78. #  מייבש כביסה - צריכת חשמל בכסף                                #
  79. #################################################################
  80.  
  81.   - platform: template
  82.     sensors:
  83.       power_calc_total_laundry_dryer:
  84.         friendly_name: "מייבש כביסה - תשלום חודשי"
  85.         value_template: "{{ ((states('sensor.laundry_dryer_energy_total') | float) * (states('input_text.power_nis_per_kwh') | float) + (states('input_text.power_monthly_cost') | int ))|round(1)}}"
  86.         unit_of_measurement: "₪"
  87.  
  88.   - platform: template
  89.     sensors:
  90.       power_calc_today_laundry_dryer:
  91.         friendly_name: "מייבש כביסה - תשלום יומי"
  92.         value_template: "{{ ((states('sensor.laundry_dryer_energy_today') | float) * (states('input_text.power_nis_per_kwh') | float))|round(1) }}"
  93.         unit_of_measurement: "₪"
  94.  
  95.  
  96.   - platform: template
  97.     sensors:
  98.       power_calc_yesterday_laundry_dryer:
  99.         friendly_name: "מייבש כביסה - אתמול"
  100.         value_template: "{{ ((states('sensor.laundry_dryer_energy_yesterday') | float) * (states('input_text.power_nis_per_kwh') | float))|round(2) }}"
  101.         unit_of_measurement: "₪"
  102.  
  103.  
  104.  
  105. #################################################################
  106. #  מדיח כלים - צריכת חשמל בכסף                                  #
  107. #################################################################
  108.  
  109.   - platform: template
  110.     sensors:
  111.       power_calc_total_dishwasher:
  112.         friendly_name: "מדיח כלים - תשלום חודשי"
  113.         value_template: "{{ ((states('sensor.dishwasher_energy_total') | float) * (states('input_text.power_nis_per_kwh') | float) + (states('input_text.power_monthly_cost') | int ))|round(1)}}"
  114.         unit_of_measurement: "₪"
  115.  
  116.   - platform: template
  117.     sensors:
  118.       power_calc_today_dishwasher:
  119.         friendly_name: "מדיח כלים - תשלום יומי"
  120.         value_template: "{{ ((states('sensor.dishwasher_energy_today') | float) * (states('input_text.power_nis_per_kwh') | float))|round(1) }}"
  121.         unit_of_measurement: "₪"
  122.  
  123.  
  124.   - platform: template
  125.     sensors:
  126.       power_calc_yesterday_dishwasher:
  127.         friendly_name: " מדיח כלים - אתמול"
  128.         value_template: "{{ ((states('sensor.dishwasher_energy_yesterday') | float) * (states('input_text.power_nis_per_kwh') | float))|round(2) }}"
  129.         unit_of_measurement: "₪"
  130.  
  131. # automation:
  132.   # - alias: Energy save Per Day Steam
  133.   #   trigger:
  134.   #     - platform: time
  135.   #       at: "00:00:00"
  136.   #   action:
  137.   #     service: input_text.set_value
  138.   #     data:
  139.   #       entity_id: energy_total_steam_collector_yesterday
  140.   #       value: "{{ states('sensor.power_calc_total_steam') }}"
  141.  
  142.   # - alias: Energy save Per Day Washing Machine
  143.   #   trigger:
  144.   #     - platform: time
  145.   #       at: "00:00:00"
  146.   #   action:
  147.   #     service: input_text.set_value
  148.   #     data:
  149.   #       entity_id: energy_total_washing_machine_yesterday
  150.   #       value: "{{ states('sensor.washing_machine_energy_total') }}"
  151.  
  152.  
  153.  
  154.  
  155.  
  156. #### יובל - ישן #####
  157.  
  158. #################################################################
  159. #                                                               #
  160. #                          Customize                            #
  161. #                                                               #
  162. #################################################################
  163.  
  164. # homeassistant:
  165. #   customize:
  166. #     sensor.phaze_1_total:
  167. #       friendly_name: שימוש כללי
  168. #       icon: mdi:power-cycle
  169.    
  170. #     sensor.phaze_1_current:  
  171. #       friendly_name: Ampere
  172. #       icon: mdi:flash-circle
  173.    
  174. #     sensor.phaze_1_today:
  175. #       friendly_name: שימוש יומי
  176. #       icon: mdi:camera-timer
  177.      
  178. #     sensor.phaze_1_yesterday:
  179. #       friendly_name: שימוש בעבר
  180. #       icon: mdi:calendar-blank
  181.    
  182. #     sensor.phaze_1_voltage:
  183. #       friendly_name: מתח
  184. #       icon: mdi:alpha-v-box-outline
  185.  
  186. #     sensor.phaze_1_power_factor:
  187. #       friendly_name: הפרש הספק
  188. #       icon: mdi:altimeter
  189.    
  190. #     sensor.power_calc_total_phaze1:  
  191. #       icon: mdi:flash-circle
  192.      
  193. #     sensor.power_calc_today_phaze1:
  194. #       icon: mdi:cash
  195.    
  196. #     sensor.power_calc_yesterday_phaze1:
  197. #       icon: mdi:cash-usd
  198.  
  199. #     sensor.phaze_1_power:
  200. #       friendly_name: Electric power      
  201.  
  202. #     sensor.phaze_1_reactive_power:
  203. #       friendly_name: צריכה תגובתית      
  204. #       icon: mdi:arrow-decision-auto
  205.    
  206. #     sensor.phaze_1_apparent_power:
  207. #       friendly_name: צריכה הסתברותית
  208.      
  209. #     sensor.kwh_count_all:
  210. #       friendly_name: Total KWH
  211. #       icon: mdi:power-socket-eu
  212.    
  213. #     sensor.kwh_count_yesterday:
  214. #       friendly_name: קילוואט־שעה (קוט"ש) (kWh) - שעון בחוץ
  215. #       icon: mdi:power-socket-eu
  216.  
  217. #     sensor.shekel_count_all:    
  218. #       friendly_name: Total This Month
  219. #       icon: mdi:currency-usd
  220.  
  221. #     input_number.shekel_number:
  222. #       friendly_name: Total Day Before  
  223. #       icon: mdi:calendar-today    
  224.  
  225.  
  226. #################################################################
  227. #                                                               #
  228. #                          input number                         #
  229. #                                                               #
  230. #################################################################
  231. # input_number:
  232. #   kwh_number:
  233. #     name: KW/H Count
  234. #     initial: 27210
  235. #     min: 0
  236. #     max: 999999999
  237. #     step: 1
  238. #     mode: box
  239.  
  240. #   shekel_number:
  241. #     name: shekel Count
  242. #     min: 0
  243. #     max: 999999999
  244. #     step: 1
  245. #     mode: box
  246.  
  247. #   kwh_price:
  248.    
  249.  
  250. #################################################################
  251. #                                                               #
  252. #                          Sensors                              #
  253. #                                                               #
  254. #################################################################
  255.  
  256. # sensor:
  257. #   - platform: mqtt
  258. #     name: "Phaze 1 - Voltage"
  259. #     state_topic: "tele/electricity/SENSOR"
  260. #     value_template: "{{ value_json['ENERGY'].Voltage }}"
  261. #     unit_of_measurement: "V"
  262. #   - platform: mqtt
  263. #     name: "Phaze 1 - Current"
  264. #     state_topic: "tele/electricity/SENSOR"
  265. #     value_template: "{{ value_json['ENERGY'].Current }}"
  266. #     unit_of_measurement: "A"
  267. #   - platform: mqtt
  268. #     name: "Phaze 1 - Power"
  269. #     state_topic: "tele/electricity/SENSOR"
  270. #     value_template: "{{ value_json['ENERGY'].Power }}"
  271. #     unit_of_measurement: "W"
  272. #   - platform: mqtt
  273. #     name: "Phaze 1 - Power Factor"
  274. #     state_topic: "tele/electricity/SENSOR"
  275. #     value_template: "{{ value_json['ENERGY'].Period }}"
  276. #     unit_of_measurement: "PF"
  277. #   - platform: mqtt
  278. #     name: "Phaze 1 - Today"
  279. #     state_topic: "tele/electricity/SENSOR"
  280. #     value_template: "{{ value_json['ENERGY'].Today }}"
  281. #     unit_of_measurement: "kWh"
  282. #   - platform: mqtt
  283. #     name: "Phaze 1 - Yesterday"
  284. #     state_topic: "tele/electricity/SENSOR"
  285. #     value_template: "{{ value_json['ENERGY'].Yesterday }}"
  286. #     unit_of_measurement: "kWh"
  287. #   - platform: mqtt
  288. #     name: "Phaze 1 - Total"
  289. #     state_topic: "tele/electricity/SENSOR"
  290. #     value_template: "{{ value_json['ENERGY'].Total }}"
  291. #     unit_of_measurement: "kWh"
  292. #   - platform: mqtt
  293. #     name: "Phaze 1 - Apparent Power"
  294. #     state_topic: "tele/electricity/SENSOR"
  295. #     value_template: "{{ value_json['ENERGY'].ApparentPower }}"
  296. #     unit_of_measurement: "VA"
  297. #   - platform: mqtt
  298. #     name: "Phaze 1 - Reactive Power"
  299. #     state_topic: "tele/electricity/SENSOR"
  300. #     value_template: "{{ value_json['ENERGY'].ReactivePower }}"
  301. #     unit_of_measurement: "VAR"  
  302.  
  303. #   - platform: template
  304. #     sensors:
  305. #       power_calc_total_phaze1:
  306. #         friendly_name: "חישוב צריכה כללי"
  307. #         value_template: "{{(((states.sensor.phaze_1_total.state | float) * 52.46) / 100) | round(2) }}"
  308. #         unit_of_measurement: "₪"
  309.  
  310. #       power_calc_today_phaze1:
  311. #         friendly_name: "חישוב צריכה יומית"
  312. #         value_template: "{{(((states.sensor.phaze_1_today.state | float) * 52.46) / 100) | round(2) }}"
  313. #         unit_of_measurement: "₪"
  314.  
  315. #       power_calc_yesterday_phaze1:
  316. #         friendly_name: "חישוב צריכה יום קודם"
  317. #         value_template: "{{(((states.sensor.phaze_1_yesterday.state | float) * 52.46) / 100) | round(2) }}"
  318. #         unit_of_measurement: "₪"
  319.  
  320. #       kwh_count_all:
  321. #         friendly_name: "KWH Count Total"
  322. #         value_template: "{{((states.input_number.kwh_number.state | float) + (states.sensor.phaze_1_total.state | float)) | round(2) }}"
  323. #         unit_of_measurement: "kWh"
  324.  
  325. #       shekel_count_all:
  326. #         friendly_name: "shekel Count start"
  327. #         value_template: "{{((states.input_number.shekel_number.state | float) + (states.sensor.power_calc_yesterday_phaze1.state | float)) | round(2) }}"
  328. #         unit_of_measurement: "₪"        
  329.  
  330. #       kwh_count_yesterday:
  331. #         friendly_name: "KWH Count Yesterday"
  332. #         value_template: "{{((states.sensor.kwh_count_all.state | float) - (states.sensor.phaze_1_yesterday.state | float)) | round(2) }}"
  333. #         unit_of_measurement: "kWh"        
  334.        
  335.  
  336. #################################################################
  337. #   Automations                                                 #
  338. #################################################################
  339. # automation:
  340. #   - alias: Set shekel_number
  341. #     initial_state: 'on'
  342. #     trigger:
  343. #       platform: time
  344. #       at: '03:14:00'
  345.  
  346. #     action:
  347. #       service: input_number.set_value
  348. #       data_template:
  349. #         entity_id: input_number.shekel_number
  350. #         value: "{{ states.sensor.shekel_count_all.state | float }}"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement