Skip to content

Commit

Permalink
Added readme file
Browse files Browse the repository at this point in the history
  • Loading branch information
carldanley committed Aug 2, 2022

Verified

This commit was signed with the committer’s verified signature.
snyk-bot Snyk bot
1 parent d29d5f7 commit e2ca20f
Showing 1 changed file with 76 additions and 0 deletions.
76 changes: 76 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# ha-fpp-mqtt

> Home Assistant Falcon Player MQTT
## About

This is a project that monitors the state of the overlay models in any given controller running Falcon Player. The objective is to query the state of the overlay models on a regular interval and report status changes (if any). This project also accepts commands and translates them back into falcon player mqtt messages accordingly.

Another interesting thing is that Falcon Player doesn't currently have the ability to query for a specific overlay model's color but this project is also a state machine and will store the last known color (which helps fill in the gaps) for state-driven MQTT projects.

## Example JSON Payloads

### Turn on an Overlay Model

```json
{
"state": "on"
}
```

### Turn off an Overlay Model

```json
{
"state": "off"
}
```

### Turn on an Overlay Model and set the color to red

```json
{
"state": "on",
"color": [255, 255, 0]
}
```

### Status Update sent by this program

```json
{
"state": "on",
"color": [255, 0, 0]
}
```

## Home Assistant

Here is an example configuration for how to set up a light within Home Assistant.

```yaml
mqtt:
light:
- name: backyard_back_fence_palm_flood_middle
schema: template
state_topic: "alfred/backyard-back-fence-palm-flood-middle/status"
state_template: "{{ value_json.state }}"
command_topic: "alfred/backyard-back-fence-palm-flood-middle/set"
command_off_template: '{"state": "off"}'
command_on_template: >
{
"state": "on"
{%- if red is defined and green is defined and blue is defined -%}
, "color": [{{ red }}, {{ green }}, {{ blue }}]
{%- endif -%}
}
red_template: "{{ value_json.color[0] }}"
green_template: "{{ value_json.color[1] }}"
blue_template: "{{ value_json.color[2] }}"
```
## FAQs
### Why is brightness not supported?
This is simple: Falcon Player does not currently have an API call (or MQTT command) to set the brightness of a specific model. The brightness is handled when the controller configuration is either updated via Falcon Player or xLights.

0 comments on commit e2ca20f

Please sign in to comment.