55
293
1932
金牌会员
使用道具 举报
10
687
5802
论坛元老
switch: - platform: template switches: switch_nas: friendly_name: 'NAS开关' value_template: "{{ 'on' if is_state('binary_sensor.ping_nas', 'on') else 'off' }}" turn_on: service: xxx data: xxx turn_off: service: XXX data: xxx
33
1104
5176
switch: - platform: wake_on_lan mac: 40:B0:76:D1:A9:DA name: Gaming PC host: 192.168.1.9 turn_off: service: hassio.addon_stdin data: addon: core_rpc_shutdown input: gaming_pc
relliky 发表于 2022-5-11 21:59 也可以不用template。 WOL 集成开关自带ping功能,WOL命令发送后,电脑在几十秒左右会开启,指定固定ip地 ...
缥缈的孤鸿 发表于 2022-5-11 19:07 可以用ping传感器判断在线状态,然后自定义一个switch
2
71
519
高级会员
本版积分规则 发表回复 回帖后跳转到最后一页
Archiver|手机版|小黑屋|Hassbian
GMT+8, 2025-2-27 20:51 , Processed in 0.067516 second(s), 30 queries .
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.