English    Deutsch

Why only CalenGoo’s database can be moved to the SD card:

Sometimes users ask if CalenGoo can be installed on their SD card instead of the internal memory of their phone, because a few phones have only a small amount of internal memory. The reason why the app itself cannot be moved to the SD card is described in Android’s official documentation here:

http://developer.android.com/guide/appendix/install-location.html#ShouldNot

The important parts are
  • Services
    Your running Service will be killed and will not be restarted when external storage is remounted. You can, however, register for the ACTION_EXTERNAL_APPLICATIONS_AVAILABLE broadcast Intent, which will notify your application when applications installed on external storage have become available to the system again. At which time, you can restart your Service.
  • Alarm Services
    Your alarms registered with AlarmManager will be cancelled. You must manually re-register any alarms when external storage is remounted.
Both are used to display alarms for your event reminders at the appropriate time, please see Background Process.
  • App Widgets
    Your App Widget will be removed from the home screen. When external storage is remounted, your App Widget will not be available for the user to select until the system resets the home application (usually not until a system reboot).
This would mean CalenGoo’s widgets could vanish and wouldn’t even appear in the widget list any more, which is probably very confusing for most users.
  • Broadcast Receivers listening for "boot completed"
    The system delivers the ACTION_BOOT_COMPLETED broadcast before the external storage is mounted to the device. If your application is installed on the external storage, it can never receive this broadcast.
As mentioned above, CalenGoo uses a background process for different purposes (e.g. to display alarms for your event’s reminders). This background process has to be automatically started on startup, otherwise the user would have to remember to start CalenGoo every time he reboots the phone. Certainly most users don’t want to have to remember to start all their apps manually after starting their phone, certain services should be run automatically.

So it isn’t possible to move the CalenGoo app to the SD card, but you can move its database to the SD card, then it will only use about 5 MB of internal memory.

How to move CalenGoo’s database to the SD card

To move CalenGoo’s database to the SD card, you just have to turn “Settings”, “Display and Use”, “Maintenance”, “Move DB to SD card” on. Then only the app itself will remain in the internal memory of your phone and it needs only a few MB.

Why the SD card isn’t the SD card on some devices

CalenGoo uses the official Android command

getExternalStorageDirectory

to get the SD card directory where it will write certain files into. However on some devices this isn’t really the SD card, but a special part of the internal memory that emulates what used to be the SD card. It is a decision of the device’s manufacturer, which directory is returned by this command. However this is the only command that the Android SDK offers to find the SD card directory, so CalenGoo can use only this command to find the directory. But even if it doesn’t point to your device’s SD card, it should nevertheless point to a directory that can be accessed from your computer when connecting the device via USB.