chromecast and chromium not working out of the box

So I replaced Linux with FreeBSD on my desktop finally (having previously run it only for my home server). It works well enough, except Chromium doesn't seem to detect my Chromecast (Nexus Player). I used Chrome+Linux previously and it worked fine, and my phone has no trouble casting either. My firewall is not enabled on the desktop at this time, and I'm not sure why it isn't working. Google seems to indicate that Chromium *should* be able to see a Chromecast. Is there anything special I need to do to make it work? special group permissions or something?
 
I don't think it works in FreeBSD's Chromium, Google used to have an add-on, but then they discontinued it.
I use https://github.com/xat/castnow.
Also I use a simple script to watch youtube videos:
Code:
ARG=$1
if [ "x$ARG" = "xstop" ]
then
    curl -H "Content-Type: application/json" http://<CHROMCAST_IP_ADDRESS>:8008/apps/YouTube -X DELETE
    exit 0
fi
curl -H "Content-Type: application/json" http://<CHROMCAST_IP_ADDRESS>:8008/apps/YouTube -X POST -d v=`echo $ARG | sed 's/.*v=\(.*\)/\1/'`
I saved it as ~/bin/cast, to play a youtube video just supply either a full URL or just a video id (after v=), e.g.:
Code:
cast https://www.youtube.com/watch?v=HDBYFaRB5WI
or use cast stop to stop.
There is another useful project, I don't use it much though (just one script to control Chromcasts's volume):
https://github.com/Pat-Carter/stream2chromecast
It supports many things including transcoding.
 
Doesn't work for me either. I have specifically installed FreeBSD on a machine to Chromecast a monitoring dashboard in the office. Nothing. Can't find the device. I'm on the same network. Castnow works fine though, but it can't cast a web site. If anyone has an idea how to Chromecast a web site from FreeBSD, I would really appreciate it! (Or, I swear, I'll install Linux!)
 
multimedia/ffmpeg can capture the screen (if built with XCB option), e.g.:
Code:
ffmpeg -video_size 640x480 -framerate 18 -f x11grab -i :0.0 /tmp/output.mp4
Now I'd like to figure out a way to stream its output to Chromcast. It shouldn't be hard. I don't see any castnow's option to cast a local stream. Maybe it's easier to implement in stream2chromcast since it's written in Python (not in JS).
 
OpenBSD has recently added chromecast support:
Make Chromecast devices and casting work by doing several different things:

- The media router extension which handles chromecast is only enabled
on official Chrome builds so enable it on chromium as well.

- Our multicast implementation is a legacy one so patch it around
to make it work and use SO_REUSEADDR and SO_REUSEPORT on the socket
to make other clients able to bind to the same port and address so
that everything will work smoothly together and chromium will not
"block" the multicast ports.

- Enable a good amount of features that are used in the javascript extension
code that were only enabled for linux and used by the media router
extension.

Everything works from youtube casting, desktop casting to browser tab casting.
The only thing that does not work is the actual initial setup of the chromecast
device because that requires connecting to the device's wifi network and the browser
cannot do that on OpenBSD so another device has to be used for that, but I guess
everyone has a smartphone nowadays :)

http://openports.se/commit_files.php?messageId=09915a1c315145c2@openbsd.org
 
Now that is interesting. I wonder how hard it would be to get that working with the FreeBSD port of Chromium...
 
Back
Top