├── res
├── public
│ └── config
│ │ ├── styles.css
│ │ ├── index.html
│ │ ├── scripts.js
│ │ ├── underscore-min.js
│ │ ├── backbone-min.js
│ │ ├── bootstrap.min.js
│ │ └── jquery.min.js
├── RootResponse.xml
└── config.yaml
├── src
├── ssdp.js
├── coreoutput.js
└── harmony-span.js
├── LICENSE
├── .gitignore
├── package.json
└── README.md
/res/public/config/styles.css:
--------------------------------------------------------------------------------
1 | /* Show it is fixed to the top */
2 | body {
3 | padding-top: 4.5rem;
4 | }
5 |
6 | table#buttonTable > tbody > tr > td:nth-child(3) {
7 | max-width: 400px;
8 | overflow: hidden;
9 | text-overflow: ellipsis;
10 | white-space: nowrap;
11 | }
12 |
13 | table#buttonTable > tbody > tr > td:nth-child(4) {
14 | max-width: 200px;
15 | overflow: hidden;
16 | text-overflow: ellipsis;
17 | white-space: nowrap;
18 | }
19 |
20 | tr.inactive td {
21 | color: grey;
22 | }
--------------------------------------------------------------------------------
/src/ssdp.js:
--------------------------------------------------------------------------------
1 | const Server = require('node-ssdp').Server;
2 | const colorout = require("./coreoutput");
3 |
4 | module.exports.run = async(httpServerUrl) => {
5 | ssdp = new Server({
6 | "location": httpServerUrl,
7 | "udn": "uuid:roku:ecp:HARMONYSPAN",
8 | "ssdpSig": 'Server: Roku/9.3.0 UPnP/1.0 Roku/9.3.0'
9 | });
10 |
11 | ssdp.addUSN("roku:ecp");
12 | ssdp.start();
13 | colorout.log("success", "[SSDP-Server] running and bound to all available network interfaces");
14 |
15 | process.on('SIGINT', function() {
16 | colorout.log("info", "[SSDP-Server] Shutting down SSDP server.");
17 | ssdp.stop();
18 | });
19 | };
--------------------------------------------------------------------------------
/src/coreoutput.js:
--------------------------------------------------------------------------------
1 | const colors = require("colors/safe")
2 |
3 | module.exports.log = async (status, message) =>
4 | {
5 | switch(status.toLowerCase())
6 | {
7 | case "regular":
8 | console.log("[ ] " + message);
9 | break;
10 | case "debug":
11 | console.log("[" + colors.magenta("~") + "] " + message);
12 | break;
13 | case "success":
14 | console.log("[" + colors.green(">") + "] " + message);
15 | break;
16 | case "info":
17 | console.log("[" + colors.blue("i") + "] " + message);
18 | break;
19 | case "warning":
20 | console.log("[" + colors.yellow("!") + "] " + message);
21 | break;
22 | case "error":
23 | console.log("[" + colors.red("X") + "] " + message);
24 | break;
25 | }
26 | }
--------------------------------------------------------------------------------
/res/RootResponse.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
[<%= action %>] <%= url %>[<%= action %>] <%= url %>[<%= action %>] <%= mqttTopic %>This service mimics a Roku device in a Logitech Harmony setup.
\n" +
65 | "Instead of controlling a Roku-device, you can assign custom actions to each of the functions available and then use a Harmony Remote to trigger those actions.
You can trigger remote actions by calling Webhooks, which helps integrating with services like IFTTT, Conrad Connect, Zapier.\n" + 67 | "You can also send MQTT-messages with each button-press. This helps you integrate with Home-Automation services like Node-RED. Lastly, you can run shell scripts.
" + 68 | "This tool helps you assign functions to actions." + 69 | "| ID | \n" + 78 | "Function | \n" + 79 | "Action | \n" + 80 | "Payload / Message | \n" + 81 | "Enabled | \n" + 82 | "\n" + 83 | " |
|---|