iobroker-community-adapters / ioBroker.lgtv

LG WebOS SmartTV adapter for ioBroker
http://iobroker.net/
MIT License
22 stars 21 forks source link

Launching Amazon Prime Video not working #8

Closed davidmartin1860 closed 6 years ago

davidmartin1860 commented 6 years ago

Hi there,

first I want to thank you for your great work on this adapter!

But currently I got one problem while using it -> I can't launch the Amazon Prime Video app with the launch command.

The issue is that "lovefilm.de" is send as id, but my lg-tv expects the id to be "amazon".

So could you please add something like this

case 'amazon':
    adapter.log.debug('Switching to Amazon Prime App on WebOS TV: ' + adapter.config.ip);
    sendCommand('ssap://system.launcher/launch', {id: "amazon"}), function (err, val) {
        if (!err) adapter.setState('launch', state.val, true);
    }
break;

to your launch-switch-statement in the lgtv.js-file (or give me the permission to create a Pull Request 😀 )

Thanks in advance, David

Edit: Of course it should also be added to io-package.json:

"states": {
            "livetv": "LiveTV",
            "smartshare": "Smart share",
            "tvuserguide": "TV User Guide",
            "netflix": "Netflix",
            "youtube": "You tube",
        "prime": "Amazon Prime",
            "amazon": "Amazon Prime Video"
          },
SebastianSchultz commented 6 years ago

Hi David,

It's possible that in germany the command is "lovefilm.de". On my TV this works. There do you come from? Maybe in other countries the command is "amazon".

Can you please reinstall the adapter from github? I've added your code :)

Thank you

davidmartin1860 commented 6 years ago

I'm from Germany 😬

Thanks for adding the code, now it is working.