I'm trying to track down a solution to this exact same problem, does
anyone have any idea on how the default settings int he SQLITE3
database get created during an Android build??

Thanks
-- Ashwin



On Tue, Feb 2, 2010 at 12:05 AM, lvsei <lvseis...@gmail.com> wrote:
> Dear all~~
>
>    I am porting GPS in android 2.0.
>    I have encountered a problem about GPS fix mode.
>    In the code
>
>    public void startNavigating() {
>        if (!mStarted) {
>            if (DEBUG) Log.d(TAG, "startNavigating");
>            mStarted = true;
>            int positionMode;
>            if (Settings.Secure.getInt(mContext.getContentResolver(),
>                    Settings.Secure.ASSISTED_GPS_ENABLED, 1) != 0) {
>                positionMode = GPS_POSITION_MODE_MS_BASED;
>            } else {
>                positionMode = GPS_POSITION_MODE_STANDALONE;
>            }
>
>            if (!native_start(positionMode, false, mFixInterval)) {
>                mStarted = false;
>                Log.e(TAG, "native_start failed in startNavigating
> ()");
>                return;
>            }
>
>            // reset SV count to zero
>            updateStatus(LocationProvider.TEMPORARILY_UNAVAILABLE, 0);
>            mFixCount = 0;
>            mFixRequestTime = System.currentTimeMillis();
>            // set timer to give up if we do not receive a fix within
> NO_FIX_TIMEOUT
>            // and our fix interval is not short
>            if (mFixInterval >= NO_FIX_TIMEOUT) {
>                mAlarmManager.set
> (AlarmManager.ELAPSED_REALTIME_WAKEUP,
>                        SystemClock.elapsedRealtime() + NO_FIX_TIMEOUT
> * 1000, mTimeoutIntent);
>            }
>        }
>    }
>
>
>    it always run positionMode = GPS_POSITION_MODE_MS_BASED;
>
>    but if I want to run positionMode = GPS_POSITION_MODE_STANDALONE;
>    How/Where do I configure the settings about GPS fix mode.
>
>    I use sqlite command to check /data/data/
> com.android.providers.settings/databases/settings.db, it shows message
> below
>
> 1|bluetooth_on|0
> 2|data_roaming|0
> 5|assisted_gps_enabled|1
> 6|network_preference|1
> 7|usb_mass_storage_enabled|1
> 8|wifi_on|0
> 9|wifi_networks_available_notification_on|1
> 10|preferred_network_mode|0
> 11|cdma_cell_broadcast_sms|1
> 12|preferred_cdma_subscription|1
> 15|backup_transport|
> 21|device_provisioned|1
> 23|install_non_market_apps|1
> 108|enabled_accessibility_services|
> 127|backup_enabled|0
> 128|adb_enabled|1
> 161|enabled_input_methods|com.android.inputmethod.latin/.LatinIME
> 162|default_input_method|com.android.inputmethod.latin/.LatinIME
> 164|mock_location|1
> 167|location_providers_allowed|gps,network
>
>
>    The assisted_gps_enabled always set to 1. How do I set it to 0 to
> use GPS fix mode to standalong;
>
>
> Best Regard
>
> --
> unsubscribe: android-porting+unsubscr...@googlegroups.com
> website: http://groups.google.com/group/android-porting

-- 
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-porting

Reply via email to