Cambridge Audio Azur 351R RS-232 (serial port) to MQTT using and ESP8266 or ESP32.
Azur 351R Receiver is a classic receiver without any network/smart functionalities. But it does have a serial port (RS-232) which can be used to send commands and receive responses. You can find more information about the serial commands at Cambrige Audio Azur 351R support page or directly in the pdf here. In case those pages will not be available in the future, the same file can he found here I wanted to have the receiver integrated with my HomeAssistant so i decided to use an ESP8266 and communicate with my HA using MQTT.
Clone this repository, rename include/definitions.example.h to include/definitions.h, edit it to your needs.
- on/off
- volume up/down
- mute/unmute
- select input source
- select audio source for input
You can also send raw commands, if you need something else that the ones above.
{"status":"on","volume":"up","input":"Aux","source":"Analogue", "rawCommand":"#5,01,"}
{"rawCommand":"#5,01,"}
{"volume":"up"}
{"mute":"on"}
{"status":"off"}
the response is going to look like this:
{"status":"on","volume":-33,"isMute":false,"selectedInput":"CD/Video1","sourceType":"Analogue"}
- create HomeAssistant custom component
- create 3D printed case for the ESP
My C kung fu is not that strong, so please excuse any badly written code. If you think you can improve and want to do so, please open a PR.