Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to json_infrared.md #245

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docs/interfaces/json-ir/json_infrared.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ The default sensor pin is GPIO4. It can be changed in the WLED settings.
### JSON IR Remote
The JSON IR remote allows users to customize IR remote behavior without writing custom C
code or compiling. Using the JSON IR remote, you can map buttons from any compatible
remote to any HTTP request API or JSON API command.
remote to any HTTP request API or JSON API command. **_NOTE: UDP Sync notifications on IR events will only work with JSON API commands last noted in v0.15.0_**

The map of IR codes to API commands is stored on your ESP's file system in `ir.json`.
From the "LED Preferences" page, set the IR pin and remote type to "JSON remote". Once "JSON remote" is selected,
Expand Down Expand Up @@ -101,6 +101,7 @@ IR recv
You should get a 24-bit hex encoded integer. If you get 0xFFFFFFFF, that means the button has been pressed repeatedly or held down. Try tapping quickly.

### Tips
* If enabling "Send notifications on button press or IR" use the JSON API in the `CMD` key, use of the HTTP request API will not initiate notifications on IR events last noted in v0.15.0.
* Map `play` or `auto` buttons to a playlist. They currently just turn on preset cycling `CY=1` or load a playlist of presets 1-5. You can define the playlist in ir.json as in the sample below, or save a playlist as a preset and load that.
* Save your 'every day' presets in one range of ids, maybe 1-30; your 'holiday' presets in another range, maybe 31-40. Then you can devote two buttons to cycle through presets. In our example, the command on the 'holiday cycle' button would be `P1=31&P2=40&PL=~`
* You can also group your presets by color; for instance reddish animations in 1-10, greenish in 11-20, bluish in 21-30. The 44-key remote has up and down arrows for red, green and blue. So the command on the 'blue down' button would be `P1=21&P2=30&PL=~-`
Expand Down