I was, but after making sure that the manifest.json
and __init__.py
were in the right spot, a restart was sufficient. I used hassio homeassistant restart
specifically; doing it through the UI doesn’t work, probably because it checks your configuration file before it even bothers to restart.
Cheers Eric. That worked without any bother for me. I was beginning to suspect the base image as the culprit but hadn’t got as far as working out which one to use. Thanks.
Perfect. Thanks @ericleb010. Added the two missing files and properly restarted Hassio and I can now control the Xbox.
thanks ericleb010, it works
Ok I had a few issues with setting this up but finally got there. Although the source isn’t currently working for me (i’ve tried Netflix, Prime, Youtube) but i may investigate this a little more when i have some more time.
When i first set everything up all i got for the mediaplayer was unknown. To fix this I removed the media player from HA connecting my Xbox through the API http://hassio.local:5557/LIVEID/connect
then re-adding the media player. I guess it’s something to do with the paring state
@ericleb010 i’ve submitted a PR for your fork to fix the missing components for people.
Why your fork? simple it works. @hunterjm has a PR for this since april so I guess life got in the way for him?
Any suggestions from any one on how to handle multiple console in the home where my user is auto-login only on one of them? I’m able to issue /connect to my primary just fine all the time, however the other xboxs I can’t connect to at all. I’ve tried via HomeAssistant and by calling the RestAPI directly.
Thanks for the contribution! As a result, there’s no longer a need to create the manifest.json
and __init__.py
files manually. I’m not too familiar with HA, but I’m going to assume that there’s a way to get this registered as an official integration, so that the custom_components
folder isn’t involved anymore? Until then, this solution works fine.
After tuning my Xbox off, it still appears as turned on??
Need some advice very new to home assistant I was able to install using @ericleb010 took a long time to install but when I click start nothing happens. I created the folders needed but after the install it has no information in them is that correct?
Any advice would be great
when I click start nothing happens
Nothing happens at all? Do you get a “red button” after clicking? Please check the logs at the bottom of the page to see if the add-on spit anything out. Otherwise, check the logs under the System
tab. Do you see anything there?
but after the install it has no information in them
I’m not sure what you mean here. By “folders” you mean the custom_components
folder? Are the media_player.py
, etc, files empty?
I get a red button with a spinning circle then goes back to just ‘start’. Nothing in the logs at the bottom will check the system logs and post what I see later.
Yea I mean the custom_components folder they have no information in them.
Thanks for your response
I was throwing the “Integration xboxone not found when trying to verify its media_player platform” error and here is what I did to get it in the very least, NOT throw a config error: I went and added the init.py and manifest.json to HASSIO/config/custom_components/xboxone/ and filled it in with the same info above
{
"domain": "xboxone",
"name": "Xbox One",
"documentation": "https://github.com/hunterjm/hassio-addons/tree/master/xboxone",
"dependencies": [],
"requirements": [],
"codeowners": ["@hunterjm"]
}
and now at least it shows up without errors. It still hasn’t connected though.
Which repository were you using? You shouldn’t have had to add those files yourself with my fork.
jmhill1287
Brilliant! All I did was delete the add-on from the jmhill1287 repo and add yours (https://github.com/ericleb010/hassio-addons, for anyone that’s having trouble finding it), followed the instructions on the page, added the stuff back to my config, restarted hassio via ssh, and away we go! Thank you so much! I’ve been trying to get this thing working for months.
Still cannot get mine to work. Can i check did you have to make any files/folders mine just hangs on install I get no errors just a spinning cycle. I did have it install once but pressing start just got a spinning cycle
Hey there, unfortunately there’s very little we can do without some logs or a better picture of what your directories look like.
Ok so now installed and im able to start the application when i do:
- Surf to your Hass.io instance and use port
5557
(e.g.http://hassio.local:5557
).
i get alot of information
{"endpoints":["/","/auth","/auth/load","/auth/login","/auth/logout","/auth/oauth","/auth/refresh","/auth/store","/auth/url","/device","/device/<liveid>","/device/<liveid>/connect","/device/<liveid>/console_status","/device/<liveid>/disconnect","/device/<liveid>/gamedvr","/device/<liveid>/input","/device/<liveid>/input/<button>","/device/<liveid>/ir","/device/<liveid>/ir/<device_id>","/device/<liveid>/ir/<device_id>/<button>","/device/<liveid>/launch/<path:app_id>","/device/<liveid>/media","/device/<liveid>/media/<command>","/device/<liveid>/media/seek/<int:seek_position>","/device/<liveid>/media_status","/device/<liveid>/nano","/device/<liveid>/nano/start","/device/<liveid>/nano/stop","/device/<liveid>/poweroff","/device/<liveid>/poweron","/device/<liveid>/stump/headend","/device/<liveid>/stump/livetv","/device/<liveid>/stump/tuner_lineups","/device/<liveid>/text","/device/<liveid>/text/<text>","/static/<path:filename>","/versions","/web/pins","/web/title/<title_id>","/web/titlehistory"],"success":true}
This is what my logs say:-
`[s6-init] making user provided files available at /var/run/s6/etc…exited 0.
[s6-init] ensuring user provided files have correct perms…exited 0.
[fix-attrs.d] applying ownership & permissions fixes…
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts…
[cont-init.d] 00-banner.sh: executing…
Hass.io Add-on: Xbox One
Control your Xbox One from your Home Assistant device
Add-on version: 2.0.1
You are running the latest version of this add-on.
parse error: Expected string key before ‘:’ at line 1, column 4
[17:31:24] ERROR: Unknown HTTP error occured
System: (armv7 / raspberrypi3)
Home Assistant version: 0.97.2
Supervisor version: 184
Please, share the above information when looking for help
or support in, e.g., GitHub, forums or the Discord chat.
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing…
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[2019-08-29 17:31:30,959] INFO in rest_server: Starting Xbox Smartglass REST server started on 0.0.0.0:5557
[2019-08-29 17:31:30,960] DEBUG in rest_server: Setting tokenfile path to /root/.local/share/xbox/tokens.json
[2019-08-29 17:31:30,961] INFO in rest_server: Trying to load & refresh tokens
[2019-08-29 17:31:30,963] WARNING in rest_server: Failed to authenticate with tokenfile from /root/.local/share/xbox/tokens.json, error: Expecting value: line 1 column 1 (char 0)
Any ideas whats gone wrong and how to correct
Thanks
Yeah, looks like you either didn’t set up your Xbox token (there’s a step in the README for that), or the token file is malformed JSON. Otherwise, everything looks normal. Check /root/.local/share/xbox/tokens.json
if you’re not sure.
@ericleb010 got it working it was a oath problem, re logged in, i can turn the xbox off and on but not able to change the source any ideas?