ChromeCast-Arduino icon indicating copy to clipboard operation
ChromeCast-Arduino copied to clipboard

ChromeCast Arduino

ChromeCast-Arduino

This Arduino sketch allows you to send YouTube videos to a ChromeCast device when a motion sensor is triggered.

This sketch requires an Arduino Ethernet shield and a PIR motion sensor.

To customize this sketch for your own YouTube video:

  1. Determine the IP address of your ChromeCast device and change the chromecast variable value in the sketch.
  2. Get the YouTube ID from the web site. It will be the URL parameter value after "v" (e.g. for http://www.youtube.com/watch?v=GWXLPu8Ky9k, v is "GWXLPu8Ky9k").
  3. Put the YouTube ID in the youtube variable value.

Use the Arduino IDE to upload the code onto an Arduino device. The code currently only loads the video once after the motion sensor is triggered, but it can easily be modified to trigger repeatedly.

Watch this video to see the sketch in action.

Other apps developed by Entertailion: