Wednesday, 15 April 2015

java - How can an Android application function as a remote controller to a desktop application? (Spotify) -



java - How can an Android application function as a remote controller to a desktop application? (Spotify) -

i in planning stages of developing android application command spotify player. since running debian on system, options available on play store quite limited (i can't find functioning apps). therefore, programmer within me tells me build one. haven't built android application before, have experience working apis think pretty decent starter project me.

however, having difficulties grasping of concepts on how implement this. research of spotify api documentation, believe spotify apps api 1 should using command playback on desktop.

on android side of things, imagine utilize spotify apps api in conjunction libspotify api receive metadata , display application getting desktop playback.

what having troubles understanding how android application talk spotify desktop client? have few ideas, unsure...

my thought process far follows:

have local webserver on desktop open , begin listening on android application, connect desktop's webserver (how do this?) once connected, desktop sends metadata/other info populate android application from android ui, hitting ui button send request webserver, parses data, completes action, , returns response android application

i little lost on tools need larn , utilize working. suggestions implementation appreciated!

thank you!

your approach correct.

on host (desktop), open socket , hear on port 80 (or port if wish) , listen. doesn't need total web server.

on client (android), start send http request desktop' ip address. desktop responds simple web page.

that's how 2 communicating.

then can start posting info desktop , returning info in web page.

then can move communicating using json rather web pages.

you can programme both host , client using qt. can develop both on desktop , move client android (or ipad) when have got working.

java android spotify remote-access libspotify

No comments:

Post a Comment