Skip to content

Commit

Permalink
Update readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
chmac committed Mar 18, 2022
1 parent 5013a00 commit 195f23a
Showing 1 changed file with 27 additions and 11 deletions.
38 changes: 27 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,38 @@
## lightflow
# lightflow

- Smooth lighting transitions with hue lights.
- Transition light colours and brightnesses gradually.
- Set a target brightness or colour, transition time, and let fly...

Create a config file at `server/src/config/private.ts` which looks like this:
## Usage

```typescript
export const HUE_USERNAME = "GET_ME_FROM_THE_HUE_DOCS";
Firstly, follow the [Hue developer
instructions](https://developers.meethue.com/develop/get-started-2/). Create a
new "app" on your bridge and save the `username` it generates for you.

export const STEP_INTERVAL_MS = 10 * 1e3; // seconds
```
Then run the `chmac/lightflow` docker container on the same network as your hue
bridge. It runs on port `4000`. If you're using docker-compose, this should be enough:

```yaml
version: "3.8"

To start run `./build.sh`.
services:
lightflow:
image: chmac/lightflow
environment:
- HUE_IP=192.168.0.XXX
restart: unless-stopped
ports:
- "4000:4000"
```
Then run `node server/build/`
### Advanced
Lightflow should now be running on port 4000.
Some aspects of the application can be controlled via environment variables set
via docker.
If you really want to use this and have challenges, open an issue here and I'll
do what I can to help out.
- If you have more than 1 bridge on your network, or if your bridge has had
multiple IP addresses, the server will log an error on startup. Figure out the
IP of your hue bridge (see the hue docs above) and then set it in `HUE_IP`.
- To enable debugging on the graphql server set `DEBUG_GRAPHQL` to a string.
- To enable debugging of the application set `DEBUG` TO `*` or `lightflow:*`.

0 comments on commit 195f23a

Please sign in to comment.