Legrand Nuvo multi-room audio support

Hi,
Just wondering if anyone knows whether it is possible to control a Nuvo system from HA?

Thanks,
Neil

1 Like

Bump for visibility. Iā€™d be interested in this as well.

No visibility. iā€™d be interested as well. i think this protocol would control my Autonomic Media Server. I created a post and will update you guys if anyone is kind enough to shine some light on mine.

Totally agree. Iā€™d be interested as well.

Hi Dan,
Any update on this?

Iā€™ve had my Nuvo running as a serial connection for a couple of years now but have always thought it would be great if it could run on IP instead. I did some searching and found that you can connect to Port 5004 and issue a few commands before getting dumped with the message:
Error: Your license does not permit this unauthorized client.

I opened wireshark and watched the traffic and between the web nuvo client and the server found that it after it connects to port 5004 and issues a bunch of commands it then opens a connection to port 5006 and sends:

*autonomic

which then gives you:

Autonomic Controls NuVo Bridge version 3.0.16725.0 Release.
More info found on the Web http://www.Autonomic-Controls.com

Type ā€˜?ā€™ for help or 'help ā€™ for help on .

where you can run command and follow events. I have had this connection open for about 20 minutes without being dropped where the connection to port 5004 always drops within 30 seconds.

Iā€™m really hoping someone can run with this info and get an integration made. Iā€™ll probably eventually get around to it if no one else makes any progress but I donā€™t have a ton of free time for a project like this.

edit: If you donā€™t send *autonomic you can send and receive the same commands as the serial interface.

I have a Nuvo system as well, add my vote for some good HA integration. Right now I have a Pi connected to it via usb to serial adapter. The Pi runs Node Red, and there is a node for serial connections. There is a good reference for all the serial based commands. So I wrote a pretty simple flow(s) that lets me turn zones on/off, set the volume, and pick the source. You can build an interface right there Node Red. Itā€™s pretty clunkyā€¦ We really need a good media_player integration. I just donā€™t have the programming skills.

Joe.

I just started using Home Assistant today for the first time so my experience is pretty limited to the entire project and the community. Iā€™ve been able to connect a surprising number of things already in just a few hours. One of the big ones would be my older Nuvo system. I happened to find this: https://github.com/ejonesnospam/hass.media_player.nuvo/ which is exactly what we need!

@ejonesnospam seems to be on here so maybe he could comment on the future of the project. I can understand why there was a number of problems, both technical and non technical, getting it merged in earlier in the year from looking at things, but it would be nice if it could still be used to the benefit of the entire community.

I have an older Essentia D that for whatever reason, refuses to respond to *ZxxSTATUS but does respond to *ZxxCONSR which is documented in an older NV-A4D protocol document I found. Maybe newer Nuvo products still will accept that command as well. It does the same thing as the STATUS command it looks like.

I was able to get the nuvo integration installed that I mentioned above into an older version of HA. I had to make a few changes to make the Simplese protocol work and for it to work with my system but it works great! I hope to see this project continue!! It is certainly a very much needed project and I am extremely appreciative of the work done so far! For the time being Iā€™m going to work on it and attempt, as I understand HA more, to make it work with newer versions and address a few issues I found. Thatā€™s all I know to do at this point.

How does one add this integration? I re-did my RPI to run HA instead of node-red, so I am ready to test.

I had to downgrade my new install to 0.92.2 to get it to work. It might work with newer releases, but certainly not the latest. I think after that version some things changed in how the integrations were packaged. I havenā€™t had time yet to look into exactly what.

If youā€™re still running an older release though, itā€™s not too bad but you need to do a little work.
Go to your base homeassistant directory and install pynuvo and make a directory ./lib/python3.7/site-packages/homeassistant/components/nuvo for the other files. This will be wherever you have HA installed. I think for the Pi itā€™s at /srv/homeassistant but I did my install manually on a Debian server so Iā€™m not sure.

Youā€™ll also need to download nuvo.py at https://github.com/ejonesnospam/hass.media_player.nuvo and transfer it over to your Pi. There is a text file as well that shows you what changes to make to your configuration.yaml file to make it work.

It should go something like this I guess though:

sudo -u homeassistant -H -s
cd /srv/homeassistant
python3 -m venv .
source bin/activate

You should now see a prompt like:
(homeassistant) homeassistant@raspberrypi:/srv/homeassistant $

Then run:
python3 -m pip install pynuvo
mkdir ./lib/python3.7/site-packages/homeassistant/components/nuvo
cp <nuvo.py you downloaded> ./lib/python3.7/site-packages/homeassistant/components/nuvo/media_player.py

You also need an init.py but you can just copy one from something else for the time being, like:
cp ./lib/python3.7/site-packages/homeassistant/components/ziggo_mediabox_xl/__init__.py ./lib/python3.7/site-packages/homeassistant/components

After you do this and edit your configuraton.yaml file you should be good to go. Donā€™t put the ā€œmodel:ā€ line in though.

I hope this works and I apologize in advance, Iā€™m not the best at writing out directions, but Iā€™ll try to help if I can.

Well that was a longer journey than I expected. Not your instructions, just getting an older version of HA installed and running.

So it looks like I have the integration installed and I can see the media player entities in the frontend. Nothing really works though. I am getting this in the logs (form all zones)

[pynuvo] Sending "Z01STATUS" 
[pynuvo] Expected response from command but no response before timeout

From my previous work, I know I need an * before each command. Looks like that might be missing. Iā€™ll continue to research.

Since I am brand new to HA, I didnā€™t have to worry about losing much, but yes, it was a pain for me to downgrade too. Do you know if your Nuvo responds with #Z0xPWRppp,SRCs,GRPt,VOL-yy? The original code will not work if yours responds with a GRP. I can send you one that I fixed that in, and a few other little things. It still needs a lot of work before Iā€™ll maybe submit a pull request. My system must be too old to even respond to the STATUS command. I finally found another command CONSR which does the same thing. I think all Essentia and Simplese models have the GRP.

I have a NV-I8GM, says Concerto on the front. When I issue *Z1STATUS?, I get this

#Z1,ON,SRC1,VOL60,DND0,LOCK0

So sounds like we have different systems.

When I have HA running and a screen running, all I see is #? on the screen output. Like itā€™s not recognizing the command HA is sending. Any way to see the string HA is sending to the serial port?

Yes, yours is certainly different. Iā€™ll send you a nuvo.py to try in a few minutes. Iā€™ve enabled all the logging as well so we can see what is happening. One of the main issues that remain is the original script had no zone checking and I havent fixed that yet, so if youā€™re pushing buttons on a keypad it can misinturpret the zone. and say one is on that really isnā€™t. Itā€™ll fix itself in a few seconds though.

I forgot to ask, would you care to do *Z1CONSR and see what happens?

That just gives me a ? at the console. So it doesnā€™t understand that.

Thanks! I found the documentation to the protocol yours uses. Thereā€™s several differences in the way the volume and so forth is handled as well, so itā€™s not going to be as quick as I first thought. Unfortunately Iā€™m working on a big project right now but Iā€™d be happy to see if I can put something together in the next couple of days.

Yeah no worries. I am just poking around since I really donā€™t know python.

All I have found so far is this

def _format_zone_status_request(zone: int) -> str:
     return 'Z{:0=2}STATUS'.format(zone)

should be

def _format_zone_status_request(zone: int) -> str:
    return 'Z{:0=2}STATUS?'.format(zone)

Now it actually returns the zone status but I think itā€™s timing out with the response.

edit: The baud rate in pynuvo was wrong too. It was set to 9600, while my amp is 57600.

edit 2: Turning my logging up to debug gives me this:

2019-11-02 16:41:39 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:39 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:39 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:39 DEBUG (SyncWorker_9) [pynuvo] Received: b'#Z5,OFF'
2019-11-02 16:41:39 DEBUG (SyncWorker_9) [pynuvo] Zone Status Request - Response Invalid - Retry Count: 2
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - No Data received
2019-11-02 16:41:40 INFO (SyncWorker_9) [pynuvo] Sending "Z05STATUS?"
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Received: b'#Z5,OFF'
2019-11-02 16:41:40 DEBUG (SyncWorker_9) [pynuvo] Zone Status Request - Response Invalid - Retry Count: 3
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - No Data received
2019-11-02 16:41:41 INFO (SyncWorker_9) [pynuvo] Sending "Z05STATUS?"
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Expecting response from command sent - Data received but no EOL yet :(
2019-11-02 16:41:41 DEBUG (SyncWorker_9) [pynuvo] Received: b'#Z5,OFF'

So something is adding a ā€œbā€ into the stringā€¦

Iā€™m far from an expert in Python myself! Iā€™ve learned the b is fine, that in Python just means a byte literal followsā€¦ Youā€™re going to have to change the pattern to make it work. I had to do some changes to get it to work with mine as it would not work with the GRP mine was sending and would also freak out when I had a zone muted.

The two big changes for yours is that the volume it sends and expects is 0 to 79 or MUTE, instead of MT. The others send that out as a negative value, that is 0 is the loudest and -78 is as low as itā€™ll go. the code expects to see a negative value then uses a float to convert that from a 0 to 1 range for HA. so like -40, midway, would be like 0.5 to HA.

So youā€™re going to need something like this to startā€¦ NEW_CONCERTO_PWR_ON_PATTERN = re.compile('Z(?P<zone>\d)'
'ON,'
'SRC(?P<source>\d),'
'VOL(?P<volume>\d\d|MUTE),'
'DND(?P<dnd>\d),'
'LOCK(?P<lock>\d')

The other difference is that the other models send the same thing when they are off, but yours only sends #Z1, OFF so that will need to be matched up with a new pattern. The protocol yours uses seems to be the one at http://smarthomebus.com/dealers/Protocols/NUVO%20Protocol.pdf

Iā€™ve got a car in my garage with manifolds and fuel rails, etc off that I need to get drivable this weekend or Iā€™d have more time to spend on this right now haha. Thatā€™s at least a start of what needs to happen if you want to play around with it. If you can get the pattern to match, thereā€™s still some more work to be done but itā€™s not all that bad.