Olimex Support Forum

OLinuXino Android / Linux boards and System On Modules => A13 => Topic started by: David Goadby on October 27, 2012, 05:47:53 AM

Title: a13 Android force startup application.
Post by: David Goadby on October 27, 2012, 05:47:53 AM
Is there a way to force the Android O/S to run an application at start-up? I don't really want my user playing with the system and need to create a configuration which boots my application only with restricted access to Android.

Any ideas?

David
Title: Re: a13 Android force startup application.
Post by: bernard on October 27, 2012, 04:37:13 PM
Yes, there are a few ways of doing this. The first step is replacing the Home application. The keyword here is "kiosk mode". Search the internet for "android" and "kiosk mode". 

Good luck and share your findings!
Title: Re: a13 Android force startup application.
Post by: David Goadby on October 30, 2012, 03:00:38 PM
Thanks for this. I will be trying it out and I will report back my success (or otherwise).

Regards

David
Title: Re: a13 Android force startup application.
Post by: murerten on November 02, 2012, 02:02:20 PM
The application that starts when you power on your device is Launcher2 app. If you make an activity with an intent filter on your manifest file like this:

        <activity
            android:name=".MainActivity"
            android:label="@string/x" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.LAUNCHER" />
                <category android:name="android.intent.category.HOME" />
            </intent-filter>
        </activity>

you make an alternative "launcher" application. At start if there are multiple launcher apps system asks you which one to start. If you want only your app to be launcher you can delete the Launcher2.apk file from root file system.