mpbzh / homebridge-plex Goto Github PK
View Code? Open in Web Editor NEWPlex plugin for homebridge: https://github.com/nfarina/homebridge
License: MIT License
Plex plugin for homebridge: https://github.com/nfarina/homebridge
License: MIT License
I have the plugin installed and config.json configured. My logs show plex registering but the device never appears in homekit. any ideas? belows a snip of my json and logs
[2018-1-14 21:07:32] Registering platform 'homebridge-config-ui-x.config'
[2018-1-14 21:07:32] ---
[2018-1-14 21:07:32] Loaded plugin: homebridge-plex
[2018-1-14 21:07:32] Registering accessory 'homebridge-plex.Plex'
[2018-1-14 21:07:32] ---
}
],
"accessory": "Plex",
"name": "PlexLivingRoom",
"host": "10.5.5.2",
"port": 32400,
"plex_token": "XXXXXXXXXXXX REDACTED",
"filter": [
{
"player": "Living Room"
}
],
Hello, is there a way to change what type of sensor is used in homekit?
So that you could be able to switch between a presence sensor or a movement sensor?
Hi
can't get homebridge-plex to work. Everything looks OK in config file. Harmony remote Hub works fine in Homebridge.
Log:
[Plex] Getting current state...
[Plex] Error getting state (status code 1): TypeError [ERR_INVALID_CHAR]: Invalid character in header content ["X-Plex-Token"]
I'm pretty sure I have the right Token
Hi
Today, I notice that if I have multiple current streaming from my PMS, my sensor will always report "Plex is not playing". No matter which user and device is being used.
My filter looks like this:
"user": "Noben",
"player": "Apple TV - Vardagsrum"
My hope with filters was that this sensor would only respond to my user when I see through device "Apple TV - Vardagsrum". Is this a bug or have I misunderstood how the filters work?
This is the logfile from where I first is playing from "Apple TV - Vardagsrum" and the user Noben, and everything works fine. homebridge-plex is reporting Plex is playing.
As soon as I starting a new stream from "Nobens iPhone 7" and the user [email protected], homebridge-plex is first reporting "Plex is playing" @ [2/5/2018, 10:36:15 PM], and then "Plex is not playing" two rows later (also @ [2/5/2018, 10:36:15 PM])
As soon as I stop playing stream number two, homebridge-plex correctly reports Plex is playing.
[2/5/2018, 10:36:12 PM] [Plex is playing] Getting current state...
[2/5/2018, 10:36:12 PM] [Plex is playing] There is one active session:
[2/5/2018, 10:36:12 PM] [Plex is playing] Apple TV - Vardagsrum vs Apple TV - Vardagsrum
[2/5/2018, 10:36:12 PM] [Plex is playing] Noben vs Noben
[2/5/2018, 10:36:12 PM] [Plex is playing] → Noben [Apple TV - Vardagsrum]: playing
[2/5/2018, 10:36:12 PM] [Plex is playing] Plex is playing.
[2/5/2018, 10:36:15 PM] [Plex is playing] Getting current state...
[2/5/2018, 10:36:15 PM] [Plex is playing] There are 2 active sessions:
[2/5/2018, 10:36:15 PM] [Plex is playing] Apple TV - Vardagsrum vs Apple TV - Vardagsrum
[2/5/2018, 10:36:15 PM] [Plex is playing] Noben vs Noben
[2/5/2018, 10:36:15 PM] [Plex is playing] → Noben [Apple TV - Vardagsrum]: playing
[2/5/2018, 10:36:15 PM] [Plex is playing] Plex is playing.
[2/5/2018, 10:36:15 PM] [Plex is playing] Apple TV - Vardagsrum vs Nobens iPhone 7
[2/5/2018, 10:36:15 PM] [Plex is playing] Noben vs [email protected]
[2/5/2018, 10:36:15 PM] [Plex is playing] → [email protected] [Nobens iPhone 7]: playing (ignored)
[2/5/2018, 10:36:15 PM] [Plex is playing] Plex is not playing.
[2/5/2018, 10:36:18 PM] [Plex is playing] Getting current state...
[2/5/2018, 10:36:18 PM] [Plex is playing] There are 2 active sessions:
[2/5/2018, 10:36:18 PM] [Plex is playing] Apple TV - Vardagsrum vs Apple TV - Vardagsrum
[2/5/2018, 10:36:18 PM] [Plex is playing] Noben vs Noben
[2/5/2018, 10:36:18 PM] [Plex is playing] → Noben [Apple TV - Vardagsrum]: playing
[2/5/2018, 10:36:18 PM] [Plex is playing] Plex is playing.
[2/5/2018, 10:36:18 PM] [Plex is playing] Apple TV - Vardagsrum vs Nobens iPhone 7
[2/5/2018, 10:36:18 PM] [Plex is playing] Noben vs [email protected]
[2/5/2018, 10:36:18 PM] [Plex is playing] → [email protected] [Nobens iPhone 7]: playing (ignored)
[2/5/2018, 10:36:18 PM] [Plex is playing] Plex is not playing.
[2/5/2018, 10:36:21 PM] [Plex is playing] Getting current state...
[2/5/2018, 10:36:21 PM] [Plex is playing] There is one active session:
[2/5/2018, 10:36:21 PM] [Plex is playing] Apple TV - Vardagsrum vs Apple TV - Vardagsrum
[2/5/2018, 10:36:21 PM] [Plex is playing] Noben vs Noben
[2/5/2018, 10:36:21 PM] [Plex is playing] → Noben [Apple TV - Vardagsrum]: playing
[2/5/2018, 10:36:21 PM] [Plex is playing] Plex is playing.
Is it possible to add a status check by pinging the server first?
At the moment the whole Homebridge gets nearly locked when the server is not online.
Is this possible with an external server that has been shared to me???
did everything, user name, media player and token
but its not responding at homekit
Hi, this is working for me perfectly well when I back video however when i play music the plugin crashes Homebridge with the following error.
18:25:14] [Plex Audio Sensor] There is one active session:
Feb 14 18:25:14 raspberrypi homebridge[25473]: /opt/node/lib/node_modules/homebridge-plex/index.js:83
Feb 14 18:25:14 raspberrypi homebridge[25473]: data.Video.forEach(function (e)
Thank you for developing this however is it possible to enable this to work for music as well as video. And as a feature request is it possible to add that as a filter so that it is possible in HomeKit to have two triggers, one for music and one for video. In my situation I would want to trigger different scenes based upon the content that is playing.
Many Thanks
The sensors are triggering when using Plex with my Sonos which doesn't seem to use a player name. I have had to disable my home automations based on this pug in because of this. Any ideas?
I have 2 Apple TV, and I want to add 2 HB-Plex.
My config:
"accessories": [
{
"accessory": "Plex",
"name": "Living Room Plex",
"host": "192.168.1.3",
"plex_token": "123qweasdzxc",
"filter": [
{
"user": "Alex",
"player": "Apple TV LR"
}
]
},
{
"accessory": "Plex",
"name": "Bedroom Plex",
"host": "192.168.1.3",
"plex_token": "123qweasdzxc",
"filter": [
{
"user": "Alex",
"player": "Apple TV BR"
}
]
}
],
The problem is if I watching Plex in Living Room both of the sensor is enabled. And if I start watching the Plex in Bedroom, both of sensors in Apple HomeKin works. How can I fix it?
Hi, after installing the plugin the automation is only triggered when I am in in homekit app or when updating favorites in control-center.
Thanks in advance
Hello,
Just installed the plugin (great idea BTW) im getting following error:
[PlexTV] Getting current state...
[PlexTV] Error getting state (status code 1): TypeError: The header content contains invalid characters
My configs are as follows:
{
"accessory": "Plex",
"name": "PlexTV",
"host": "192.168.0.1",
"plex_token": "XXXXXXXXXXXX (redacted)",
"filter": [
{
"user": "XXXXXXXXXXX (redacted)",
"player": "TV UE55KU6000"
}
]
}
Any ideas on were im going wrong? Thanks
I'm getting an error previously closed/discussed:
\homebridge-plex\index.js:83
data.Video.forEach(function (e) {
^
TypeError: Cannot read property 'forEach' of undefined�
I'm not sure where it's going wrong.
Hi,
I tried installing it, and after checking the json file and starting the homebridge program, I get this error :[Plex] Error getting state (status code 1): Error: socket hang up
What can I do to fix it ?
Hey there
I am getting a "Error getting state (status code 401): null" error. I have input a valid token, so not sure why this would be.
Line 60 in b9795fb
The server is not local so may be that's why.
Config looks like:
{
"accessory": "Plex",
"name": "Plex",
"plex_token": "xxxxxx",
"host": "XXX-XXX-XXX-XXX.929ed44XXXXXXXXX10de7d1017f33.plex.direct"
}
Hi there,
I'm trying to get this set up but I keep getting the error "[Plex] Error getting state (status code 401): null"
I have verified the token is correct and renewed it. I have also debugged the token and it is giving me the correct media container response. I have tried manually specifying the server IP (even though it is on the localhost) and I have also tried deleting my config.json and recreating it using nano and li in an attempt to prevent formatting issues, but the issue remains.
Please help!
What host setting is used if you're a guest of a remote plex server? is that possible to configure?
I apologize if this is premature, and fully acknowledge that I haven't given my system enough time to prove anything to me one way or the other, but I updated to the latest commit this morning (b542c39) and noticed that with each poll there is a set of lines that get written to the homebridge.log file (which I believe is a capture of stdout?).
For my system, which is a homebridge docker container, the status is being written every 3 seconds (I know I can change this default) to /var/log/homebridge.log. I've been watching the file size grow at ~100KB/hr. Doing some rough (and probably poor) math, I'll be looking at a 15MB log file for each full week the plugin runs. Not the end of the world, but you can see how it'll add up quickly.
I'll keep checking on it over the next day or two to see if these logs rollover, and I know I could setup a cron job or something to periodically clear things out, but I wanted to bring it up for discussion. Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.