shi11 / RemoteControls

cordova 3 plugin for interacting with ios7 remote controls and metadata
57 stars 41 forks source link

Plugin not working on iOS #28

Open HrBayat opened 8 years ago

HrBayat commented 8 years ago

Hi, Thanks for your plugin. I've initialized in app.js deviceready event with the same data provided in readme. In console i get "RemoteControls plugin init." message, but nothing shows up on lock screen. This is my code in app.js:

var params = ["Daft Punk", "One More Time", "Discovery", "http://netahang.com/image/song-image/400", 200, 100];
        window.remoteControls.updateMetas(function(success){
            alert(JSON.stringify(success));
        }, function(fail){
            alert(JSON.stringify(fail));
        }, params);
DahliaWitt commented 8 years ago

What plugin are you using to play audio? An audio session needs to be initiated before this plugin will work.

HrBayat commented 8 years ago

Thanks for your response Drake. I'm using ionic-audio. Its based on cordova-media-plugin.

HrBayat commented 8 years ago

I also tested it with cordova-media-plugin alone. It didnt work too.

HrBayat commented 8 years ago

@DrakeWitt Do you have any advice ?

fenta23 commented 8 years ago

Same here, i'm using the cordova-media-plugin. The Play/Pause is working, but not the rest of the remote controls.

Something new here?

marcusforsberg commented 8 years ago

Has anyone had any luck here?

ermanisharma commented 7 years ago

Hello, I have created a hybrid ionic app in ios. I want that when my app is running, it can be shown in Control Center Music controller. Ans also I must access from there like play/pause feature. In my application I am using the Code provided in Readme file in App.js > .run >$ionicPlatform.ready(){.. here..}. But there is issue in accessing the remote-event. I debug it and found that this even is not being called. Please help me ... :(