denon-mqtt 0.0.3 → 0.0.4-beta.20545140501.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +100 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -86,7 +86,7 @@ Theater" is the configuration for a Denon X4500H and "Office" is the configurati
|
|
|
86
86
|
]
|
|
87
87
|
```
|
|
88
88
|
|
|
89
|
-
### Install with yarn
|
|
89
|
+
### Install with yarn or npm
|
|
90
90
|
|
|
91
91
|
This method requires [installing Node.js first](https://nodejs.org/en/download).
|
|
92
92
|
|
|
@@ -169,12 +169,110 @@ services:
|
|
|
169
169
|
- ./mosquitto-users.txt:/mosquitto/config/mosquitto-users.txt
|
|
170
170
|
```
|
|
171
171
|
|
|
172
|
+
## MQTT Syntax
|
|
173
|
+
|
|
174
|
+
In addition to the below topics and payloads, you can request updated status data from the receiver by posting a text
|
|
175
|
+
payload of `REFRESH` to topic `{prefix}/device/command`. Note that this command will requery all configured receivers.
|
|
176
|
+
|
|
177
|
+
### Command Topics
|
|
178
|
+
|
|
179
|
+
The following topics are supported. In each topic name below, `{prefix}` is the global prefix (default: `denon`) and
|
|
180
|
+
`{zone}` is the zone identifier (`main_zone`, `zone1`, `zone2`).
|
|
181
|
+
|
|
182
|
+
- `{prefix}/switch/{zone}_power/command`
|
|
183
|
+
- `{prefix}/switch/{zone}_mute/command`
|
|
184
|
+
- `{prefix}/volume/{zone}_volume/command`
|
|
185
|
+
- `{prefix}/select/{zone}_source/command`
|
|
186
|
+
|
|
187
|
+
### Command Payloads
|
|
188
|
+
|
|
189
|
+
The following payloads formats are required for each command topics:
|
|
190
|
+
|
|
191
|
+
- power: `{ text: "value" }` where `value` is `ON` or `OFF`
|
|
192
|
+
- mute: `{ text: "value" }` where `value` is `ON` or `OFF`
|
|
193
|
+
- volume: `{ numeric: value }` where `value` is between 1 and the max volume set for the AVR
|
|
194
|
+
- source: `{ text: "value" }` where `value` is a valid source identifier (ex: `BD`, `CD`, `DVD`, `AUX1`, `AUX2`)
|
|
195
|
+
|
|
196
|
+
### State Topics
|
|
197
|
+
|
|
198
|
+
NOTE: While the interface maintains state based on the latest messages received from the AVR, it is possible that not
|
|
199
|
+
all states will always be available.
|
|
200
|
+
|
|
201
|
+
The messages are published to the following topics each time a related command is received from the receiver:
|
|
202
|
+
|
|
203
|
+
- `{prefix}/switch/{zone}_power/state`
|
|
204
|
+
- `{prefix}/switch/{zone}_mute/state`
|
|
205
|
+
- `{prefix}/volume/{zone}_volume/state`
|
|
206
|
+
- `{prefix}/select/{zone}_source/state`
|
|
207
|
+
- `{prefix}/select/{zone}_state/state`
|
|
208
|
+
|
|
209
|
+
### State Payloads
|
|
210
|
+
|
|
211
|
+
The following text (**NOT** JSON) payloads are published when the interface receives a related command from the receiver:
|
|
212
|
+
|
|
213
|
+
- power: `ON`|`OFF`
|
|
214
|
+
- mute: `ON`|`OFF`
|
|
215
|
+
- volume: 2-digit number (ex: `01`)
|
|
216
|
+
- source: valid source identifier (ex: `BD`, `CD`, `DVD`, `AUX1`, `AUX2`)
|
|
217
|
+
|
|
218
|
+
The state topic publishes the full comprehensive state of the AVR in JSON format as an object of key/value pairs. The
|
|
219
|
+
following keys are supported:
|
|
220
|
+
|
|
221
|
+
- ChannelSetting
|
|
222
|
+
- ChannelVolume
|
|
223
|
+
- DigitalInput
|
|
224
|
+
- ECOMode
|
|
225
|
+
- MainPower
|
|
226
|
+
- MaxVolume
|
|
227
|
+
- Mute
|
|
228
|
+
- Parameters
|
|
229
|
+
- Power
|
|
230
|
+
- SD
|
|
231
|
+
- Sleep
|
|
232
|
+
- Source
|
|
233
|
+
- SSLevels
|
|
234
|
+
- SSSpeakers
|
|
235
|
+
- Standby
|
|
236
|
+
- SurroundMode
|
|
237
|
+
- VideoSelect
|
|
238
|
+
- VideoSelectSource
|
|
239
|
+
- HPF
|
|
240
|
+
- QuickSelect
|
|
241
|
+
- Volume
|
|
242
|
+
|
|
243
|
+
For settings that support multiple parameters (`ChannelVolume`, `Parameters`, `SSLevels`, etc.), the value will be a
|
|
244
|
+
JSON object with multiple key/value pairs with text format for all values. `Volume` and `MaxVolume` values are numeric
|
|
245
|
+
(integer). All other values are text.
|
|
246
|
+
|
|
247
|
+
For example, the following is a valid main zone status payload:
|
|
248
|
+
|
|
249
|
+
```json
|
|
250
|
+
{
|
|
251
|
+
"ChannelVolume": { "FL":"50", "FR":"50", "C":"50", "SL":"50", "SR":"50" },
|
|
252
|
+
"DigitalInput": "AUTO",
|
|
253
|
+
"MainPower": "ON",
|
|
254
|
+
"MaxVolume": 98,
|
|
255
|
+
"Mute": "OFF",
|
|
256
|
+
"Parameters": { "DRC": "OFF", "LFE": "00", "BAS": "50", "TRE": "50", "TONE CTRL": "OFF", "CLV": "50", "SWL": "50" },
|
|
257
|
+
"Power": "ON",
|
|
258
|
+
"SD": "AUTO",
|
|
259
|
+
"Sleep": "OFF",
|
|
260
|
+
"Source": "SAT/CBL",
|
|
261
|
+
"SSLevels": { "C": "50", "FL": "50", "FR": "50", "SL": "50", "SR": "50", "SBL": "50", "SBR": "50" },
|
|
262
|
+
"SSSpeakers": { "FRO": "LAR", "CEN": "SMA", "SUA": "SMA", "SBK": "2SP", "FRH": "NON", "TFR": "NON", "TPM": "NON",
|
|
263
|
+
"FRD": "NON", "SUD": "NON", "TPR": "NON", "RHE": "NON", "BKD": "NON", "SHE": "NON", "TPS": "NON", "SWF": "NON" },
|
|
264
|
+
"SurroundMode": "DOLBY AUDIO-DD+ +DSUR",
|
|
265
|
+
"VideoSelect": "OFF",
|
|
266
|
+
"Volume": 51
|
|
267
|
+
}
|
|
268
|
+
```
|
|
269
|
+
|
|
172
270
|
## Contributing
|
|
173
271
|
|
|
174
272
|
### Clone the repository
|
|
175
273
|
|
|
176
274
|
```bash
|
|
177
|
-
git clone https://github.com/douglampe/denon-
|
|
275
|
+
git clone https://github.com/douglampe/denon-mqtt.git
|
|
178
276
|
```
|
|
179
277
|
|
|
180
278
|
### Install dependencies
|