Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Home

barbeau edited this page · 24 revisions
Clone this wiki locally

Media Remote ME

Media Remote Micro Edition (ME) is a Java Micro Edition (Java ME) project that allows you to control different types of media players (e.g., iTunes, Yahoo Launchcast streaming music player) from your Java ME mobile phone.

Media Player Interfaces

Media Remote ME provides two ways for the server to interact with media players: tightly-coupled via APIs to the media player, or loosely-coupled via general mouse pointer movement and click commands issued via the Java Robot API.

The follow paragraphs explain the current interfaces implemented for several media players.

iTunes control is tightly-coupled via the iTunes COM APIs.

To control iTunes on Windows using this app, you'll need:

  • iTunes Windows SDK - Allows a Windows app to send commands to iTunes via the COM API
  • JACOB (Java COM Bridge) - Provides an interface between the Java-based server code running in a server such as Glassfish and the iTunes COM API

Yahoo Launchcast Media player is an browser-based internet streaming radio player. Launchcast control is loosely-coupled and controlled via the Java Robot API. Therefore, while no additional downloads are required, Media Remote ME assumes that the upper left corner of the Launchcast window is positioned at the upper-left corner of your main computer screen. This ensures that the postion of the play, next-track, etc. commands is the correct (x,y) location on your screen when issued to the Java Robot API.

Using Media Remote ME to control your computer

You must point the mobile client to the IP address of your computer running Glassfish and the iTunesServer Java app. This is done by modifying the IP address in the WebToMobileClient class. Note that if you're not using your Java ME phone on your local WiFi network and your phone only has a cellular data connection (i.e., WAN), you'll need to use the IP address of your cable modem in the WebToMobileClient class and add port forwarding rules to your router to pass the commands on the Glassfish port (e.g., 8080) to the address and port number of the machine on your local network running Glassfish.

For iTunes control, you must add the Jacob.jar file to the classpath of your Glassfish server so Glassfish can pass the COM commands to iTunes.

Using Media Remote ME on your phone

Media Remote ME has been tested using Sanyo 7050 and Sanyo Pro 200 cell phones on the Sprint network. The current code implements the Sprint Extensions-specific ExternalCanvas functionality to allow the user to enter commands when the phone is flipped closed, as seen to the right.

The general code should be usable on any non-Sprint Java ME phone if the ExternalCanvas code is removed.

Note that the mobile app currently listens to key codes specific to Sanyo phones in the KeyEventCanvas. If the key codes on your phone are different, you'll need to change these constants to the proper key codes for the directional key pad on your phone. Check the System.out.println() printouts when pressing keys on your phone to see what the key codes for your phone are.

Something went wrong with that request. Please try again.