Giter Site home page Giter Site logo

elvenpath / cambridgeaudioazur351r-rs232tomqtt Goto Github PK

View Code? Open in Web Editor NEW
7.0 3.0 1.0 172 KB

Cambridge Audio Azur 351R RS-232 to MQTT using and ESP8266 or ESP32 for Home Assistant

License: MIT License

C++ 100.00%
esp32 esp8266 home-assistant mqtt

cambridgeaudioazur351r-rs232tomqtt's Introduction

CambridgeAudioAzur351R-RS232toMqtt with HomeAssstant

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.

Instalation

Clone this repository, rename include/definitions.example.h to include/definitions.h, edit it to your needs.

Commands implemented

  • 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.

MQTT payload examples

{"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"}

TODO:

  • create HomeAssistant custom component
  • create 3D printed case for the ESP
PS

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.

cambridgeaudioazur351r-rs232tomqtt's People

Contributors

elvenpath avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

iamdan77

cambridgeaudioazur351r-rs232tomqtt's Issues

Tuner spelled as Tunner

Thank you for your awesome component. I use it with Home Assistant to automatically switch on (and up in the right mode) while I switch on my TV, or stream something to my Chromecast Audio. This works so much faster (and more stable) than the IR way.

The only minor thing that I see as a down side, is that you spelled "Tunner" instead of "Tuner". Fix that and I am totally happy.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.