Help power on/off Xbox One

Looking for assistance to use Xbone One component to power on/off XBox One device.

Here is what I have done so far:

  1. Install XBone One component from https://github.com/ericleb010/hassio-addons
  2. Used http://hassio.local:5557/auth/login to authenticate
  3. Used http://hassio.local:5557/device to get device id
  4. Added Configuration for xbox one component in configurator.yaml:
media_player:
 - platform: xboxone
   device: 'XXXXXXXXXXX' (used real device id here)
   name: 'Family Room Xbox One'
  1. Restarted Hass.IO
  2. Checked logs to make sure connection is successful:
127.0.0.1 - - [2020-01-24 20:58:31] "GET /device/XXXXXXXXXXXXXXXX/media_status HTTP/1.1" 200 145 0.002098
[2020-01-24 20:58:31,951] DEBUG in protocol: Received DiscoverResponse from 192.168.1.30
  1. I can power XBox on and off using Media Player UI controller.

I am running into issues setting up automation to power XBox on/off :

  1. Can not power xbox off using media_player.turn_off service. Is this correct service to use to power it off? Should I used another service?

  2. If xbox is not on, I can not use media_player.turn_on service to power it back on. Again, is there a different service I should use?

Any ideas are appreciated!

Thank you

I don’t currently have that service installed, I keep meaning to install it as I’ve had it in a prior installation of HA. However, if I remember correctly, you have to have the xb1 in power mode where it accepts updates while powered off etc, which I think is the power mode that’s not power saving. I’m open to correction. Also, I think that sometimes it fails to turn on the xb1, not frequently, but occasionally.

You were correct. It was in power safe mode. I changed it to the instant-on mode. However, still not able to get my automation to work. media+player.turn_on / turn_off services are not working.

Ahh, instant on mode, that’s what it’s called. Sorry, I’m not at home and couldn’t check. I never used it in conjunction with any automations, so I don’t know if it ever worked. However, with the xb1 now in instant on mode, have you tried turning it on and off from home assistant first, to make sure that it’s actually working? Like I said, I did experience occasional problems with the service not working. As it was never part of an automation it didn’t bother me as it was only occasional. If you have checked, and it is working, maybe try rebooting home assistant? If it still doesn’t work, double check your automation trigger, condition etc. Also post your code so people can look at it. They may spot something you haven’t seen.

I am not sure there is an issue with automation. I am testing using Services tab in the Developer Tool section. There is no code.

media_player UI control does not seem to work either. At least not power on /power off.

Thank you