Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keee player and chromecast almost synced #30

Open
Ciao121 opened this issue Mar 14, 2018 · 0 comments
Open

Keee player and chromecast almost synced #30

Ciao121 opened this issue Mar 14, 2018 · 0 comments

Comments

@Ciao121
Copy link

Ciao121 commented Mar 14, 2018

Hi everyone,
I have a player playing a video. I push a button and the video is sent to chromecast, with actual time so it starts the video at the same time (the player is still playing it). Chromecast get some seconds to start and in the meanwhile video on the player continues to play. So when both are playing there is a big difference in time of what player and chromecast are playing.
E.g. player is at 1:10 and Chromecast is at 1:00. I'd like to reduce this gap.
What I was thinking to do is.
When I push the button i send the video to chromecast and pause the video on the player.
When chromecast really starts playing the video I restart it also on the player... so player and chromecast are almost synced.

But I cannot find a way to understand when chromecast starts playing. I tried to get the chromecast status but I cannot. Maybe related to #22, But I'm not getting undefined.
The command I use is chromecasts.players[0].status() (player[0] is the chromecast I'm using)
I'm getting this error:

Uncaught TypeError: callback is not a function at C:\Users\ivan\Desktop\Myapp\chromecast\node_modules\castv2-client\lib\controllers\media.js:41 at fn.onmessage (C:\Users\ivan\Desktop\Myapp\chromecast\node_modules\castv2-client\lib\controllers\request-re…:27) at emitTwo (events.js:130) at fn.emit (events.js:213) at Channel.onmessage (C:\Users\ivan\Desktop\Myapp\chromecast\node_modules\castv2-client\lib\controllers\controller…:16) at emitTwo (events.js:125) at Channel.emit (events.js:213) at Client.onmessage (C:\Users\ivan\Desktop\Myapp\chromecast\node_modules\castv2\lib\channel.js:23) at emitMany (events.js:151) at Client.emit (events.js:223)

Any idea about this error? Or any other way to solve my sync "issue"?
Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant