what I did for this in terms of the connections was I created a kind of a pass through.. The issue with Denon/Marantz network control is that only a single device can be connected at a time. So if you had say an app on your phone you wanted to use to control the thing. if EG was connected to it.. you would not be able to use the app on the phone.
So what I did was I have the plugin connect to the AVR.. and do the things a plugin normally does receiving information parsing it and producing events if needed. and also sending commands to the AVR.. The lightbulb went on. why can't we have the application connect to the PC running EG instead of the the AVR. The plugin will pass the information over to the AVR and vice versa.
so when a connection is made from another application to your PC to control the AVR a new thread gets made. that threads sole purpose is to read data coming from the application and places that information in a send queue for the AVR. another thread reads that queue and sends the data to the AVR. there is a 3rd thread that reads the data from the AVR. it passes that data to the plugin then it will send the data to the application via that conenction to the PC.. the application has not a clue this is taking place.
It's actually a fairly complex process using queues thread locks and code that stalls a thread without sleeping or endlessly looping causing high CPU use. this is done so the application and the plugin are not able to write the data to the AVR at the same time if that occurred I am sure some ugly things could happen.
The largest problem is their API. It SUCKS!. there is no consistency with it. You can actually tell when responsibility for adding to it was given to a new person in the company. The other problem is I do not even think that Denon\Marantz knows all of the commands across all of the models and then across all of the firmware versions for each model. There is no single document that contains this information. There are things the AVR spits out that I am not able to locate anywhere in the API for any of the devices they have. and the company is horribly disorganized it took me almost a month to actually get to someone that knew what I was asking for when I asked for the IP API documentation. and that person was not able to provide me with all of the API information.. The WebUI that is on these things does not utilize the full API either so no love can be found in the source code for the WebUI.
If I remember correctly where I left off was writing the 1000 actions. this is because of the command variations. Here is an example...
You have commands for Zone1. Zone1 is the Master Zone. Zone2, Zone3, Zone4 have commands for them to set the volume. Zone1 does not. Zone 1 you have to use a separate volume command. and if memory servs the response gotten from setting the master volume is not the same when you set the volume for a zone..It's bat shit crazy. I think they use completely different measurements scales. one is db the other is % and the step rates are different. The AVR volume can be set in increments of 0.5 DB but the thing only reports back in 1db increments. so if you use the remote to up the volume a 1/2 a DB no event for the change can get generates because we simply do not know if the volume went up 0.5 or a whole db...
For my own home I was going to buy these Marantz components for my house
AV8001
MM7055
MM8077
MM7025 * 4
I started working on this plugin and said forget that.. if they can't get an API right what makes me think they are going to build the equipment correctly LOL. It was a shame too because I could have gotten a hell of a deal on the components at the time 50% or 60% off retail. I also realized that I do not have the room to fit a second rack next to my existing one. It was 1 inch to wide and I didn't want to have to go through the process of moving a wall and redoing my laundry room in order to make everything fit properly.. I may end up doing it anyway because my washer and dryer are to deep for the space they are in I need to move the wall back to make more room.
I did wire the house up with 4 conductor 14ga speaker wire to each room. 2 runs per room. This is the wire I used
http://www.katerno.com/detail/s/291067/ ... NAQAvD_BwE
dirt cheap at 40 cents a foot. I got it less then that because someone ordered it at the microcenter near me and they never paid for it and never came and got it. I paid like 100 bucks for the 500 foot roll.