Compare commits
4 Commits
async-reqw
...
master
Author | SHA1 | Date | |
---|---|---|---|
77d8f0375c | |||
6202522acd | |||
|
66a7ec5127 | ||
|
8a898b5cf8 |
9
.github/workflows/rust.yml
vendored
9
.github/workflows/rust.yml
vendored
@ -15,6 +15,15 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name : Install ARM compiler
|
||||
run: sudo apt-get install gcc-arm-linux-gnueabihf -y
|
||||
- name: Set ARM compiler as environment variable
|
||||
run: export CC=arm-linux-gnueabihf-gcc
|
||||
- uses: actions-rs/toolchain@v1
|
||||
with:
|
||||
toolchain: stable
|
||||
target: armv7-unknown-linux-gnueabihf
|
||||
override: true
|
||||
- uses: actions/checkout@v2
|
||||
- name: Build
|
||||
run: cargo build --verbose
|
||||
|
23
README.md
23
README.md
@ -1,7 +1,5 @@
|
||||
![Bleak logo](docs/img/bleak_logo.png)
|
||||
|
||||
[![Build Status](https://cicd.wyattjmiller.com/api/badges/wyatt/bleak/status.svg)](https://cicd.wyattjmiller.com/wyatt/bleak)
|
||||
|
||||
Change the aura of the room with your smart TV!
|
||||
|
||||
This project is licensed by the [Mozilla Public License v2](https://www.mozilla.org/en-US/MPL/2.0/). A copy of this license is in the project's root directory for your convenience.
|
||||
@ -10,21 +8,18 @@ The logo is licensed by the [CC BY-NC-ND 4.0](https://creativecommons.org/licens
|
||||
|
||||
## What is this??
|
||||
|
||||
This came from an idea in high school where one could change a channel and some LEDs could change color. This project is just that, only with Smart TV's (Roku TV's and Roku devices supported). One changes the application to Netflix, the LEDs turn red. Another changes the application to Hulu, the LEDs turn green.
|
||||
This came from an idea in high school where one could change a channel and some LEDs could change color based on the channel selected. This project is just that, only with smart TV's (see the [supported devices](#smart-tv-support) for a list of supported devices). One changes the application to Netflix, the LEDs turn red. Another changes the application to Hulu, the LEDs turn green.
|
||||
|
||||
## How does it work?
|
||||
|
||||
`bleak` sends out a API request to your Roku TV/Roku device you specify in a JSON file, which is read by `bleak`, and based on that response, the LEDs will change color. These requests happen at one second intervals.
|
||||
|
||||
TL;DR
|
||||
|
||||
Read the source code.
|
||||
`bleak` sends out a network request to your smart TV's IP address that you specify in a JSON file, which is read by `bleak`, and based on that response, the LEDs will change color. These requests happen at one second intervals.
|
||||
|
||||
## Pre-requisites
|
||||
|
||||
* A Raspberry Pi (tested with a Raspberry Pi 4)
|
||||
* A WS2818 LED light strip (you can order this from [Amazon](https://www.amazon.com/s?k=ws2818+led+strip))
|
||||
* Rust 1.40+ (this is the version of Rust `bleak` was written in) However, any version of Rust 2018 will most likely be fine
|
||||
* [Supported](#smart-tv-support) smart TV
|
||||
|
||||
## Installation
|
||||
|
||||
@ -106,26 +101,30 @@ or you can:
|
||||
|
||||
to run this program as one is hacking away.
|
||||
|
||||
I wrote a systmed service file so starting and stopping would be like I'm starting and stopping any service on a Linux machine. I also didn't like `bleak` taking control of my terminal session :)
|
||||
I wrote a systemd service file so starting and stopping would be like I'm starting and stopping any service on a Linux machine. I also didn't like `bleak` taking control of my terminal session :)
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
Things that I've noticed:
|
||||
* ~~`bleak` will crash from time to time when grabbing responses. There's no error handling at this point.~~
|
||||
* `bleak` like to change color to some random color(s) when being told to change color to, say, green or red. I think that's just my light strip (or my breadboard I use for development) but I hav eno other light strips to test...
|
||||
* `bleak` like to change color to some random color(s) when being told to change color to, say, green or red. I think that's just my light strip (or my breadboard I use for development) but I have no other light strips to test...
|
||||
* ~~Roku TV's tend to be slow while `bleak` is running. Can't reproduce this problem, however~~ Doesn't seem to do this anymore
|
||||
|
||||
If you find any other issues with `bleak`, please send them my way in the form of a [new issue](https://scm.wyattjmiller.com/wyatt/bleak/issues/new).
|
||||
|
||||
## Smart TV support
|
||||
|
||||
In development:
|
||||
Supported:
|
||||
|
||||
* Roku devices and Roku TV's
|
||||
|
||||
In development:
|
||||
|
||||
* Apple TV 4K/HD
|
||||
|
||||
Future possibilities:
|
||||
|
||||
* Samsung SmartThings TV
|
||||
* Samsung TV (probably utilizing SmartThings API)
|
||||
* Android TV
|
||||
* Amazon's Fire TV
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user