From d2ec7259746d5f09f94c50709f88dceab9343d09 Mon Sep 17 00:00:00 2001 From: SteffoSpieler Date: Wed, 11 Sep 2024 21:53:00 +0200 Subject: [PATCH] feat(pishock): Add pishock docs --- docs/index.md | 1 + docs/samples/pishock.md | 48 +++++++++++++++++++++++++++++++++++++++++ mkdocs.yml | 5 +++-- 3 files changed, 52 insertions(+), 2 deletions(-) create mode 100644 docs/samples/pishock.md diff --git a/docs/index.md b/docs/index.md index e21297b1..12723c54 100644 --- a/docs/index.md +++ b/docs/index.md @@ -53,6 +53,7 @@ that's no problem you can head over to the - OBS - [OpenTTS](https://github.com/synesthesiam/opentts) - Philips Hue +- [PiShock](https://pishock.com) - RCON - Reddit - sACN Receiver diff --git a/docs/samples/pishock.md b/docs/samples/pishock.md new file mode 100644 index 00000000..2d021b5e --- /dev/null +++ b/docs/samples/pishock.md @@ -0,0 +1,48 @@ +## Using the PiShock sample bundle + +The PiShock example bundle in `samples/pishock` demonstrates the ability +to use the PiShock api to get the infos about the shockers. Here is a guide +to how to get it working. + +### Prerequisites + +You will need a working `nodecg-io` installation. If you have non yet take a +look at [installation guide](../getting_started/install.md). You may need to +install this bundle, so take a look at the +[“Try an included sample”](../getting_started/try_example_bundle.md)-Guide. It +will also tell you how to log in and how to use the GUI. + +**You also need:** + +- 1 PiShock Hub +- At least 1 Shocker +- An PiShock Account + +### Configure the PiShock sample bundle + +1. In NodeCG, create a new pishock service instance. + +2. Enter your authentication details like this + + ```json + { + "authentications": [ + { + "username": "myAwesomeUsername", + "apiKey": "12345678-1234-1234-1234-123456789012", + "code": "ABCDEFGHIJK", + "name": "nodecg-io-pishock-integration" + } + ] + } + ``` + + Multiple authentications may be provided to allow the using bundle + to access multiple devices. + Setting the client name is optional and defaults to `nodecg-io PiShock Service` if none is provided. + After entering it, click save. + +3. Set the sample's (`pishock`) dependency to be the newly created service + instance (of type `pishock`). + +4. View the NodeCG console log which should contain all information about the provided devices diff --git a/mkdocs.yml b/mkdocs.yml index f95dd4d9..554999dd 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,7 +1,7 @@ site_name: nodecg-io Documentation site_author: codeoverflow.org site_url: https://nodecg.io/ -copyright: "© 2020-2022 codeoverflow.org CC-BY-4.0" +copyright: "© 2020-2024 codeoverflow.org CC-BY-4.0" theme: palette: @@ -83,7 +83,8 @@ nav: - Nanoleaf: samples/nanoleaf.md - OBS: samples/obs.md - OpenTTS: samples/opentts.md - - Philips Hue sample: samples/philipshue.md + - Philips Hue: samples/philipshue.md + - PiShock: samples/pishock.md - Rcon sample: samples/rcon.md - Reddit sample: samples/reddit.md - sACN: