This is the forum archive of Homey. For more information about Homey, visit the Official Homey website.

The Homey Community has been moved to https://community.athom.com.

This forum is now read-only for archive purposes.

Yamaha Receiver

I created an app for Yamaha receivers, based on https://github.com/PSeitz/yamaha-nodejs and https://github.com/jordenc/com.onkyo.

It can be found here: https://github.com/kruimel0/yamaha-app-homey

I will send it to athom today for official integration.

Currently working:
* Turning receiver on/off
* Mute/unmute receiver
* Increase/decrease volume
* Set volume to a certain value
* Change source of receiver
* Change music equaliser settings of receiver

Turning receiver on this way takes 10-20 seconds, take care of this when using in a flow with something else (i.e., delay a command to change the receiver input if you want 1 flow to both turn the receiver on and change the input).

Important!
Before you can use it to turn your receiver on, you should go to the settings on your receiver's webpage (enter the IP adres in a browser), and go to settings -> Network Standby -> Select 'On'.
If you do not find these settings, take a look at this site, which might help you: http://userscripts-mirror.org/scripts/show/182663

You need to have the (local) IP-address of your receiver to add the device to Homey (There is no discovery)

Use at your own risk, I accept no responsibility for any damages caused by using this script.
«1

Comments

  • Great Work !!!
  • Nice! Power to the Homey :)
  • That's fast!
  • SommoSommo Member
    what i want! :smiley:
    a question about "Turning receiver on this way takes 10-20 seconds".. could i know why it could take so long? u r talking about turning on/off or that delay is for every command sended to the yamaha?
    Thank you anyway!
  • Sommo said:
    what i want! :smiley:
    a question about "Turning receiver on this way takes 10-20 seconds".. could i know why it could take so long? u r talking about turning on/off or that delay is for every command sended to the yamaha?
    Thank you anyway!
    That's only for the command to turn on the receiver. Somehow (I don't know why) turning on the receiver via the network (if it is from the web interface or via Homey) just takes 10-20 seconds before the Receiver actually turns on.
    Turning the receiver off and changing all other settings are practically instantanious.
  • SommoSommo Member
    i will let you know, from the app (iphone) every command (also turning it on/off) is in realtime response.. only when i was out, i used webinterface to turning it off/on and never know that it take this time..
  • SommoSommo Member
    i'm waiting for the official release on store :)
  • Sommo said:
    i'm waiting for the official release on store :)
    Officially released on store!
  • works like a charm!

    any suggestions on how to automatically get a net station started? (now I have to browse through the list to get a station started, would be nice to say ok homey, radio and when the preset net radio is used automatically a default radio station starts playing)
    a bit between homey and receiver twilight on how to get this done :)

  • works like a charm!

    any suggestions on how to automatically get a net station started? (now I have to browse through the list to get a station started, would be nice to say ok homey, radio and when the preset net radio is used automatically a default radio station starts playing)
    a bit between homey and receiver twilight on how to get this done :)
    maybe include in the flow three times the ´enter´ button with some delay

    feature request :smile: would it be possible to add the enter button or some supported buttons as a flow card?

  • works like a charm!

    any suggestions on how to automatically get a net station started? (now I have to browse through the list to get a station started, would be nice to say ok homey, radio and when the preset net radio is used automatically a default radio station starts playing)
    a bit between homey and receiver twilight on how to get this done :)
    maybe include in the flow three times the ´enter´ button with some delay

    feature request :smile: would it be possible to add the enter button or some supported buttons as a flow card?
    WIll look into it.
    From the top of my head, the arrow keys were possible, so I'd assume enter is also possible...
  • SommoSommo Member
    edited April 2016
    installed..initially all seems ok, but now (for the second time) homey can't reach the yamaha..
    when i test the flow, the command stay in a spinning loop without sending any command to the avr... both time i rebooted homey and that did not resolve the issue.
    The yamaha has a static ip so there is no reachability problem (yamaha app on iphone works every time ok),
    so i removed the device, and when trying to add it again, i can't because when i fill the ip form, the button save is not working.
    I went to the app section, DISABLE-ENABLE the Yamaha APP, and all is working again... (button save now do the job), that's could be a bug maybe trigger by the fact i installed other app..maybe..(it's the only thing that i did in the meanwhile it was working.. hope this information could be helpfull to you!


    i checked, and somehow the yamaha was in DHCP, a bind the ip from the router,, also did a dhcp reservation and i give you a feedback, maybe it was only my problem, sorry i believed to haved configured it to static ip.

    but those points remains good, i changed in order of priorities (imho):
    I have some suggestions, if you want to make it better then ever :smile: 
    1)it could be possible to have the yamaha into the coloumn "WHEN" ?
    2)when testing flow, is it normal that (for ex changing input) the spinning still looping, can we have a feedback that the flows worked ok?
    3)volume trigger do not accept negative value, that is important for -db :wink: 
    4)it could be useful to change the yamaha ip parameters on the device list screen, because now the tag device can only be deleted, it not have setting parameters like for example hue lights/fibaro motion sensor... (you have to remove and add a yamaha avr again to change that)

    i didn't experience the 10-20seconds delay :open_mouth: when all works, and i test the flow o speaking to homey to trigger the Yamaha is seems like it's in realtime!

    anyway thank you for your Good Work KoenMartens!

  • Sommo said:
    I have some suggestions, if you want to make it better then ever :smile: 
    1)it could be useful to change the yamaha ip parameters on the device list screen, because now the tag device can only be deleted, it not have setting parameters like for example hue lights/fibaro motion sensor... (you have to remove and add a yamaha avr again to change that)
    2)it could be possible to have the yamaha into the coloumn "WHEN" ?
    3)when testing flow, is it normal that (for ex changing input) the spinning still looping, can we have a feedback that the flows worked ok?
    4)volume trigger do not accept negative value, that is important for -db :wink: 
    Thanks for the praise :)

    To answer your questions/remarks:
    1) I could look into this, but I will not make it a priority, because, as you said, receivers have a static IP address, so in theory, they should never be changed.
    2) It would be possible, but what would you like there? If the receiver is turned on/off or something?
    3) Yes, that's normal. I think feedback should be possible, but haven't read into it (this was my first time coding in JS)
    4) The set volume trigger works %-based, as I myself hate the fact that my receiver goes from -65 to + 35 dB or whatever. So I made it that the 0-100 value you put it in translated to a dB value suitable for the receiver.
  • SommoSommo Member
    1) you right! in fact i edited my post and put it to the last point, sorry for confusing when editing
    2) yes, it could be nice, if homey could checked what input is now (ex HDMI1/2/.. TUNER), if it is on or off, could be very usefull
    3) i know that, lot of respect :smile: , but also that could be very useful to check if homey and yamaha talk ok
    4) ok, 0-100, how can i convert to db, just to know: 0 means -65db and 100 means +35db, right?
  • SommoSommo Member
    maybe these setting, 0 means xdB and 100 means xdB could be a parameter that could be set according for the user personal experience (but if you use standard value could be very good also, no matters to spend time in this :wink: 

  • jordenjorden Member
    edited April 2016
    @KoenMartens 3) if you pass through the 'callback' to the function 'SendXMLToReceiver', you can send back a true or false, based on the output by your request.post

    For example:
    request.post({
    method: 'POST',
    uri: 'http://'+hostIP+'/YamahaRemoteControl/ctrl',
    body:xml},
    function(error, response, body){
    Homey.log(body);
    callback(null, false);})
  • Sommo said:
    maybe these setting, 0 means xdB and 100 means xdB could be a parameter that could be set according for the user personal experience (but if you use standard value could be very good also, no matters to spend time in this :wink: 

    For now, 0 means lowest dB, 100 means highest dB. I could indeed make these parameters quite easily, but I doubt the usefullness of that together with you :)

    jorden said:
    @KoenMartens 3) if you pass through the 'callback' to the function 'SendXMLToReceiver', you can send back a true or false, based on the output by your request.post

    For example:
    request.post({
    method: 'POST',
    uri: 'http://'+hostIP+'/YamahaRemoteControl/ctrl',
    body:xml},
    function(error, response, body){
    Homey.log(body);
    callback(null, false);})
    Thanks! Will implement this in the next update
  • You also need a callback true if there is no error (or try to log the response output of the receiver in the request.post)
  • jorden said:
    You also need a callback true if there is no error (or try to log the response output of the receiver in the request.post)
    That's what I expected already, but thanks anyhow :)
  • SommoSommo Member
    one of my flow idea is to lower the yamaha volume when homey is striggered (homey s listening tag), after that it put back to volume's value that was before, to do so we have to know (read that value, and maybe put it to better logic variable).. or a tricky way is to put to an higher medium volume, but that solution is not closed to a perfection :smile: 
     
  • Sommo said:
    one of my flow idea is to lower the yamaha volume when homey is striggered (homey s listening tag), after that it put back to volume's value that was before, to do so we have to know (read that value, and maybe put it to better logic variable).. or a tricky way is to put to an higher medium volume, but that solution is not closed to a perfection :smile: 
     
    Oh wauw very nice idea. Will look into implementing some upgrades this weekend.
  • SommoSommo Member
    glad you appreciate it! it could be awsome, and it is now, that i put the volume to 30% and after to 45% :smiley:

    but i still have problem with the yamaha communication, now it can't change ip (checked).. homey stopped to talk with the avr, the only solution was, disable the app, remove the device, enable app, add new yamaha, same ip (of course) => and all goes fine, like this morning, i only installed/removed new apps (also reboot homey wasn't enough)..
    that also appened to the hue, sometimes when u install apps it seems, homey lose control of them and you have to add device again (maybe i create a post for that).
  • That might have something to do with the 'to aggressive' garbage collection in Homey's software currently. Athom is working on this and next version should have this 'bug' solved, as well as a faster javascript engine and a much lower CPU load.
  • SommoSommo Member
    i have tested the flow, it really needs feedback of the yamaha's status, because (i don't know if it's only my case) i have a lot of false/fake trigger that wake up homey to listening and the volume switch down to up too many false time.

    for example exclude this "new" features if the input is on a specific source (like hdmi3)..

  • Version 0.1.1 submitted to app store (pending for approval now), fixes problems introduced at Homey v0.9.x
  • thank you!
  • is it taking too long? don't you think? r u planning to upgrade the app with the features that we've talking before?
  • KoenMartensKoenMartens Member
    edited September 2016
    @Sommo: What? I am doing this for free, I am not rewarded, financially or otherwise, in any way if I update this app or not. I do not like your tone at all. Feel free to fork the code at github and update it yourself if you want more functionality.
  • Is it take too long was referred to athom timeline to put your update online (pending approval) not for your work to update it with new features, sorry for the misunderstanding, i know u r doing it 4 free i'm only asking if you r planning to implement the app cause i have a yamaha too, anyway thank you for what have u done and i'm sorry if i don't express well myself
  • Sommo said:
    Is it take too long was referred to athom timeline to put your update online (pending approval) not for your work to update it with new features, sorry for the misunderstanding, i know u r doing it 4 free i'm only asking if you r planning to implement the app cause i have a yamaha too, anyway thank you for what have u done and i'm sorry if i don't express well myself
    If you check the app store, you can see that it has long been updated to 0.1.1.
Sign In or Register to comment.