Hi folks.
I am new to yaml, I am running an up to date HA on RPI4 and trying to do as much as possible without writing script, but you know how that will pan out.
I am not entirely sure but I think my original config option was ‘0’ config, either way all my basic kit is working and configuration.yaml is, well, sparce.
Having decided I needed to get under the hood, as it were, I picked turning on my TV, and subsequently playing with it, as a place to tinker… No risk!
Its an LG running WebOS so there is an integration for that but it cant turn the thing ON just Off.
I know the TV supports WOL so I added that and was extremely pleased when the first switch I ever added, without the UI configuring it for me worked… Silly me…
The pre configured integration for WebOS will happily turn the TV Off as designed.
WOL will turn it On…
My switch will only turn it On and I cant figure out what I am doing wrong.
switch:
- platform: wake_on_lan
mac: e4:75:dc:8f:fa:ec
name: "Lounge TV switch"
turn_off:
service: media_player.turn_off
target:
entity_id: media_player.lounge_tv
I copied the identity, config check is good… Has to be either structure or complete lack of understanding, and I expect the latter is most likely.
I don’t understand why there is no turn_on but I am guessing it is replaced bu the platform WOL.
I don’t understand why the indents below platform don’t seem to be required.
mmmm…
Whilst typing this I realised that there is no indent below ‘target:’ fixed that, restarted and now it works!!
Given that I don’t know if the indent, or possible me not restarting earlier, fixed the issue I am leaving this post. Seems I have way more than even I thought to learn, and I am well aware of just how little I know right now.
Starting with… Where the hell is my config anyway?
Whilst trying to trouble shoot these few lines I went looking for the code associated with the code associated Wirth the LG integration that was working, and couldn’t find it.
Any and all comments will be much appreciated.