Starting the player

Please download the ambient-x.x.apk file here .

Running in the Android cellphone

Consult your phone manual on how to install third-party Android applications.

Evaluating Ambient on your PC

First, download and install the Android SDK .

We need to create a sd card with MP3 files. Go into the Android SDK /tools directory and run mksdcard -l sdcard 2000M sdcard.img .

  • Linux: run mkdir sdcard && sudo mount sdcard.img sdcard -o loop,uid=YOUR_USER_NAME,gid=users . The SD Card is mounted in the sdcard/ directory, just copy some mp3s there. Then, sudo umount sdcard .
  • Windows: get a LiveCD of Linux :-)

Running the pre-built APK file

Go into the Android SDK /tools directory and run

emulator -sdcard sdcard.img

when Android boots up, copy the ambient-x.x.apk file into the Android SDK /tools directory and run (in other shell):

adb install ambient-x.x.apk

The application should now be accessible from the Android menu.

Compiling from sources

If you want to try bleeding-edge, development unstable version running, read on.

Environment setup

You need to install:

  • Java 5 JDK or higher (not JRE)
  • Maven2 2.0.9 or higher . Add the bin/ directory to your path.
  • Subversion version 1.4 or higher

Then, add the Android SDK /tools directory to your PATH.

You need to generate a certificate as it is now required by Android. Just run

keytool -genkeypair -alias ambientcertss

Enter anything you want as your name etc, it doesn't matter. Remember the password you entered, you may use the same password two times.

To setup Maven2, edit the $HOME/.m2/settings.xml (create the file if it is missing):

<?xml version="1.0" encoding="UTF-8"?>
<settings>
        <profiles>
                <profile>
                        <id>default</id>
                        <activation><activeByDefault>true</activeByDefault></activation>
                        <properties>
                                <cert.keypass>THE KEY PASSWORD HERE</cert.keypass>
                                <cert.storepass>THE KEYSTORE PASSWORD HERE</cert.storepass>
                        </properties>
                </profile>
        </profiles>
</settings>

Then, checkout the project:

svn co https://ambientmp.svn.sourceforge.net/svnroot/ambientmp/Ambient/trunk
Building

Go into the trunk directory and enter

svn up
mvn clean install

The APK file should be located in the target/ directory. If a certificate mismatch error pops up while installing the APK, you'll need to uninstall previous Ambient installation.

Developing with Eclipse

  • Download Eclipse and install it. Install the Android Eclipse Plugin. Install Subclipse .
  • Run Eclipse, then select Window / Preferences / Android and enter correct Android SDK location.
  • Checkout the project: in Eclipse, File / Import / Other / Checkout project from SVN , select Create a new repository and enter https://ambientmp.svn.sourceforge.net/svnroot/ambientmp/Ambient/trunk . Then click Finish . Rightclick on the project in Package Explorer and select Android Tools / Fix project properties .
  • Back in Eclipse, Run / Run... , right-click Android Application / New , select the Ambient project and select the sk.baka.ambient.MainActivity . Click on the Emulator tab, then into the Additional Emulator Command Line Options field enter -sdcard FULL_PATH_TO_THE_sdcard.image_FILE
  • Click Apply button, then Run . Wait for the emulator to start. If the Ambient player won't start automatically, just click the Run button again.