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

playing videos/audio from raspberry pi 3b fails, whilst working perfectly on windows. #242

Closed
olvrb opened this issue Nov 2, 2017 · 4 comments

Comments

@olvrb
Copy link

olvrb commented Nov 2, 2017

I have my discord bot with this:

            var stream = ytdl(url);
            var voiceChannel = message.member.voiceChannel;
            voiceChannel.join().then(connection => {
                console.log("joined channel and playing video");
                const dispatcher = connection.playStream(stream);
                dispatcher.on("end", end => {
                    console.log("left channel");
                    voiceChannel.leave();
                });
            }).catch(err => console.log(err));

(url is the user input)
And it runs prefectly on Windows 10 Version 1703 (OS Build 15063.674).

When i try to run it on my Raspberry Pi 3b, however, it joins the channel, and instantly leaves. Here's the output from console i get from the pi:

Bot has started, with 106 users, in 44 channels of 3 guilds.
joined channel and playing video
left channel
Now playing "Ultimate Best of 20Syl / 2011-2015 / HQ Audio quality (1080p)"
@fent
Copy link
Owner

fent commented Nov 2, 2017

Could the dispatcher be emitting an error?

Maybe an audio engine isn't installed on your pi?

@olvrb
Copy link
Author

olvrb commented Nov 2, 2017

I have all dependencies installed and listen in package.json, and am using the exact same files on my windows machine as on my pi. This issue describes pretty much the same thing.

@fent
Copy link
Owner

fent commented Nov 3, 2017

What about the possible error event from dispatcher, is that logged? What about errors from stream?

@olvrb
Copy link
Author

olvrb commented Nov 17, 2017

I found out that the version of FFMPEG i had didn't support Raspbian. FFMPEG itself doesn't actually support Raspbian.

@olvrb olvrb closed this as completed Nov 17, 2017
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

2 participants