Android->gps:support UBOX gps module
This commit is contained in:
@ -75,3 +75,7 @@ else
|
|||||||
ro.target.product=tablet
|
ro.target.product=tablet
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# product has GPS or not
|
||||||
|
BOARD_HAS_GPS := true
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -56,6 +56,25 @@ else
|
|||||||
device/rockchip/rk3288/fstab.rk30board.bootmode.emmc:root/fstab.rk30board.bootmode.emmc
|
device/rockchip/rk3288/fstab.rk30board.bootmode.emmc:root/fstab.rk30board.bootmode.emmc
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
PRODUCT_COPY_FILES += \
|
||||||
|
device/rockchip/rk3288/gps/gps.conf:system/etc/gps.conf \
|
||||||
|
device/rockchip/rk3288/gps/u-blox.conf:system/etc/u-blox.conf \
|
||||||
|
device/rockchip/rk3288/gps/gps.default.so:system/lib/hw/gps.default.so
|
||||||
|
|
||||||
|
########################################################
|
||||||
|
# this product has GPS or not
|
||||||
|
########################################################
|
||||||
|
ifeq ($(strip $(BOARD_HAS_GPS)),true)
|
||||||
|
PRODUCT_PROPERTY_OVERRIDES += \
|
||||||
|
ro.factory.hasGPS=true
|
||||||
|
PRODUCT_COPY_FILES += \
|
||||||
|
frameworks/native/data/etc/android.hardware.location.gps.xml:system/etc/permissions/android.hardware.location.gps.xml
|
||||||
|
else
|
||||||
|
PRODUCT_PROPERTY_OVERRIDES += \
|
||||||
|
ro.factory.hasGPS=false
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
# setup dalvik vm configs.
|
# setup dalvik vm configs.
|
||||||
$(call inherit-product, frameworks/native/build/tablet-10in-xhdpi-2048-dalvik-heap.mk)
|
$(call inherit-product, frameworks/native/build/tablet-10in-xhdpi-2048-dalvik-heap.mk)
|
||||||
|
|
||||||
|
|||||||
83
device/rockchip/rk3288/gps/gps.conf
Normal file
83
device/rockchip/rk3288/gps/gps.conf
Normal file
@ -0,0 +1,83 @@
|
|||||||
|
###############################################################################
|
||||||
|
#
|
||||||
|
# Copyright (C) u-blox AG
|
||||||
|
# u-blox AG, Thalwil, Switzerland
|
||||||
|
#
|
||||||
|
# All rights reserved.
|
||||||
|
#
|
||||||
|
# Permission to use, copy, modify, and distribute this software for any
|
||||||
|
# purpose without fee is hereby granted, provided that this entire notice
|
||||||
|
# is included in all copies of any software which is or includes a copy
|
||||||
|
# or modification of this software and in all copies of the supporting
|
||||||
|
# documentation for such software.
|
||||||
|
#
|
||||||
|
# THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR IMPLIED
|
||||||
|
# WARRANTY. IN PARTICULAR, NEITHER THE AUTHOR NOR U-BLOX MAKES ANY
|
||||||
|
# REPRESENTATION OR WARRANTY OF ANY KIND CONCERNING THE MERCHANTABILITY
|
||||||
|
# OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR PURPOSE.
|
||||||
|
#
|
||||||
|
###############################################################################
|
||||||
|
#
|
||||||
|
# Project: Android GNSS Driver
|
||||||
|
#
|
||||||
|
###############################################################################
|
||||||
|
# $Id: gps.conf 82175 2014-06-18 15:18:01Z jon.bowern $
|
||||||
|
# $HeadURL: http://svn.u-blox.ch/GPS/SOFTWARE/hmw/android/release/release_v2.3/gps/gps.conf $
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
|
#
|
||||||
|
# Configuration file for an Android GPS Driver
|
||||||
|
#
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
|
|
||||||
|
### Network Time Protocol (NTP) server
|
||||||
|
|
||||||
|
NTP_SERVER=europe.pool.ntp.org
|
||||||
|
# NTP_SERVER=uk.pool.ntp.org
|
||||||
|
# NTP_SERVER=asia.pool.ntp.org
|
||||||
|
# NTP_SERVER=oceania.pool.ntp.org
|
||||||
|
# NTP_SERVER=north-america.pool.ntp.org
|
||||||
|
# NTP_SERVER=south-america.pool.ntp.org
|
||||||
|
# NTP_SERVER=africa.pool.ntp.org
|
||||||
|
|
||||||
|
|
||||||
|
### AssistNow Offline (XTRA) Link
|
||||||
|
|
||||||
|
XTRA_SERVER_1=http://alp.u-blox.com/current_7d.bin
|
||||||
|
|
||||||
|
|
||||||
|
### AGPS SETTINGS ###
|
||||||
|
|
||||||
|
# Secure User Plane Location (AGPS-SUPL) - TLS connection
|
||||||
|
|
||||||
|
SUPL_HOST=supl.google.com
|
||||||
|
SUPL_PORT=7275
|
||||||
|
|
||||||
|
|
||||||
|
# Secure User Plane Location (AGPS-SUPL) - non-TLS connection
|
||||||
|
|
||||||
|
#SUPL_HOST=supl.google.com
|
||||||
|
#SUPL_PORT=7276
|
||||||
|
|
||||||
|
|
||||||
|
# sls1.sirf.com 7275 7276
|
||||||
|
# suplcn.sirf.com 7275 7276
|
||||||
|
# supl.nokia.com 7275
|
||||||
|
# supl.google.com 7275 7276
|
||||||
|
# supl.sonyericsson.com 7275
|
||||||
|
# lge.glpals.com
|
||||||
|
# 130.141.44.135
|
||||||
|
|
||||||
|
# uncomment and set the correct IP address for the SUPL test server
|
||||||
|
#SUPL_HOST=10.64.4.69
|
||||||
|
#SUPL_PORT=7275
|
||||||
|
|
||||||
|
#SUPL_HOST=supl.google.com
|
||||||
|
#SUPL_HOST=supl.nokia.com
|
||||||
|
#SUPL_HOST=supl.sonyericsson.com
|
||||||
|
#SUPL_HOST=sls1.sirf.com
|
||||||
|
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
BIN
device/rockchip/rk3288/gps/gps.default.so
Executable file
BIN
device/rockchip/rk3288/gps/gps.default.so
Executable file
Binary file not shown.
123
device/rockchip/rk3288/gps/u-blox.conf
Normal file
123
device/rockchip/rk3288/gps/u-blox.conf
Normal file
@ -0,0 +1,123 @@
|
|||||||
|
###############################################################################
|
||||||
|
#
|
||||||
|
# Copyright (C) u-blox AG
|
||||||
|
# u-blox AG, Thalwil, Switzerland
|
||||||
|
#
|
||||||
|
# All rights reserved.
|
||||||
|
#
|
||||||
|
# Permission to use, copy, modify, and distribute this software for any
|
||||||
|
# purpose without fee is hereby granted, provided that this entire notice
|
||||||
|
# is included in all copies of any software which is or includes a copy
|
||||||
|
# or modification of this software and in all copies of the supporting
|
||||||
|
# documentation for such software.
|
||||||
|
#
|
||||||
|
# THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR IMPLIED
|
||||||
|
# WARRANTY. IN PARTICULAR, NEITHER THE AUTHOR NOR U-BLOX MAKES ANY
|
||||||
|
# REPRESENTATION OR WARRANTY OF ANY KIND CONCERNING THE MERCHANTABILITY
|
||||||
|
# OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR PURPOSE.
|
||||||
|
#
|
||||||
|
###############################################################################
|
||||||
|
#
|
||||||
|
# Project: Android GNSS Driver
|
||||||
|
#
|
||||||
|
###############################################################################
|
||||||
|
# $Id: u-blox.conf 83773 2014-08-07 12:20:13Z marcel.baracchi $
|
||||||
|
# $HeadURL: http://svn.u-blox.ch/GPS/SOFTWARE/hmw/android/release/release_v2.3/gps/u-blox.conf $
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
|
#
|
||||||
|
# u-blox Android GNSS Driver configuration file
|
||||||
|
#
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
|
|
||||||
|
### Serial interface
|
||||||
|
# Device to be used by the driver
|
||||||
|
SERIAL_DEVICE /dev/ttyS3
|
||||||
|
#SERIAL_DEVICE /dev/s3c2410_serial2
|
||||||
|
#SERIAL_DEVICE /dev/i2c-4
|
||||||
|
#SERIAL_DEVICE /dev/ttyACM0
|
||||||
|
|
||||||
|
# The baudrate that should be used to communicate with the receiver and at
|
||||||
|
# which the receiver will output the NMEA messages.
|
||||||
|
BAUDRATE 9600
|
||||||
|
|
||||||
|
# The default baudrate the receiver is configured to after startup. The
|
||||||
|
# HAL interface will configure itself to this baudrate and send a command
|
||||||
|
# to the receiver to switch to the baudrate assigned to the BAUDRATE keyword
|
||||||
|
BAUDRATE_DEF 9600
|
||||||
|
|
||||||
|
### Assistance
|
||||||
|
# File path and name for aiding information
|
||||||
|
ALP_TEMP /data/aiding.ubx
|
||||||
|
|
||||||
|
# Timeout for stopping the receiver [in seconds]
|
||||||
|
STOP_TIMEOUT 5
|
||||||
|
|
||||||
|
# AssistNow Offline (AGPS-XTRA) Link interval [in hours]
|
||||||
|
XTRA_POLL_INTERVAL 20
|
||||||
|
|
||||||
|
# AssistNow Online (AGPS-UBX) Link
|
||||||
|
#UBX_HOST = agps.u-blox.com
|
||||||
|
#UBX_PORT = 46434
|
||||||
|
|
||||||
|
# Save aiding data to file system when engine stops
|
||||||
|
PERSISTENCE 1
|
||||||
|
|
||||||
|
### SUPL configuration
|
||||||
|
# SUPL requests configuration
|
||||||
|
SUPL_ALMANAC_REQUEST 0
|
||||||
|
SUPL_UTC_MODEL_REQUEST 0
|
||||||
|
SUPL_IONOSPHERIC_MODEL_REQUEST 1
|
||||||
|
SUPL_DGPS_CORRECTIONS_REQUEST 0
|
||||||
|
SUPL_REF_LOC_REQUEST 1
|
||||||
|
SUPL_REF_TIME_REQUEST 1
|
||||||
|
SUPL_AQUISITION_ASSIST_REQUEST 0
|
||||||
|
SUPL_TIME_INTEGRITY_REQUEST 0
|
||||||
|
SUPL_NAVIGATIONAL_MODEL_REQUEST 1
|
||||||
|
|
||||||
|
# The SUPL_CACERT keyword enables a TLS encryption to the SUPL server.
|
||||||
|
# It this keyword is missing, the communication will be unencrypted. If
|
||||||
|
# no value is assigned to this keyword every CA certificate will be
|
||||||
|
# accepted as valid. If a value is assigned to this keyword, this value
|
||||||
|
# will be interpreted as the path to a ca-certificate file. If the
|
||||||
|
# ca-certificate in this file does not match the root of the certificate
|
||||||
|
# chain the connection will be aborted.
|
||||||
|
#SUPL_CACERT /system/etc/ca-cert-google.pem
|
||||||
|
SUPL_CACERT
|
||||||
|
|
||||||
|
# uncomment the line below to use the certificate in SUPL test server
|
||||||
|
# SUPL_CACERT /system/etc/v1_slp_rs_de_cert.pem
|
||||||
|
|
||||||
|
# Number of retries for contacting the SUPL server
|
||||||
|
SUPL_CONNECT_RETRIES 0
|
||||||
|
|
||||||
|
# Maximum time to show the dialog for network initiated SUPL session [in seconds]
|
||||||
|
SUPL_NI_UI_TIMEOUT 10
|
||||||
|
|
||||||
|
# Maximum time for sending information to the SUPL server for network
|
||||||
|
# initiated SUPL session [in seconds]
|
||||||
|
SUPL_NI_RESPONSE_TIMEOUT 75
|
||||||
|
|
||||||
|
|
||||||
|
### Debugging aids
|
||||||
|
|
||||||
|
# Option to send fake mobile phone network information
|
||||||
|
# leave this as 0 unless you are testing
|
||||||
|
SUPL_FAKE_PHONE_CONNECTION 0
|
||||||
|
|
||||||
|
# Port number for the UDP debug server
|
||||||
|
UDP_SERVER_PORT 46434
|
||||||
|
|
||||||
|
# save decoded RRLP and UPL data to logcat
|
||||||
|
SUPL_LOG_MESSAGES 0
|
||||||
|
|
||||||
|
# create CMCC compatible A-GPS.LOG and GPS.LOG
|
||||||
|
SUPL_CMCC_LOGGING 0
|
||||||
|
|
||||||
|
# save decoded RRLP and UPL data to file SUPL-MESSAGE.LOG
|
||||||
|
SUPL_MSG_TO_FILE 0
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
@ -346,6 +346,10 @@ on boot
|
|||||||
# Tweak background writeout
|
# Tweak background writeout
|
||||||
write /proc/sys/vm/dirty_expire_centisecs 200
|
write /proc/sys/vm/dirty_expire_centisecs 200
|
||||||
write /proc/sys/vm/dirty_background_ratio 5
|
write /proc/sys/vm/dirty_background_ratio 5
|
||||||
|
|
||||||
|
#permissions for /dev/ttyS3
|
||||||
|
chmod 0666 /dev/ttyS3
|
||||||
|
|
||||||
|
|
||||||
# Permissions for System Server and daemons.
|
# Permissions for System Server and daemons.
|
||||||
chown radio system /sys/android_power/state
|
chown radio system /sys/android_power/state
|
||||||
|
|||||||
@ -462,7 +462,7 @@
|
|||||||
clock-frequency = <24000000>;
|
clock-frequency = <24000000>;
|
||||||
clocks = <&clk_uart3>, <&clk_gates6 11>;
|
clocks = <&clk_uart3>, <&clk_gates6 11>;
|
||||||
clock-names = "sclk_uart", "pclk_uart";
|
clock-names = "sclk_uart", "pclk_uart";
|
||||||
current-speed = <115200>;
|
current-speed = <9600>;
|
||||||
reg-shift = <2>;
|
reg-shift = <2>;
|
||||||
reg-io-width = <4>;
|
reg-io-width = <4>;
|
||||||
dmas = <&pdma1 7>, <&pdma1 8>;
|
dmas = <&pdma1 7>, <&pdma1 8>;
|
||||||
|
|||||||
Reference in New Issue
Block a user