A few things, mostly technical notes...

Friday, August 07, 2015

gps.conf (motox 2013 5.1 build)

gps.conf
# XTRA_SERVER_QUERY (1=on, 0=off)
# If XTRA_SERVER_QUERY is on, the XTRA_SERVERs listed
# below will be ignored, and instead the servers will
# be queried from the modem.
XTRA_SERVER_QUERY=0
# XTRA_SERVERs below are used only if XTRA_SERVER_QUERY
# is off.
XTRA_SERVER_1=http://xtra1.gpsonextra.net/xtra2.bin
XTRA_SERVER_2=http://xtra2.gpsonextra.net/xtra2.bin
XTRA_SERVER_3=http://xtra3.gpsonextra.net/xtra2.bin

# Error Estimate
# _SET = 1
# _CLEAR = 0
ERR_ESTIMATE=0

#Test
#NTP_SERVER=time.gpsonextra.net
#Asia
# NTP_SERVER=asia.pool.ntp.org
#Europe
# NTP_SERVER=europe.pool.ntp.org
#North America
NTP_SERVER=north-america.pool.ntp.org

# DEBUG LEVELS: 0 - none, 1 - Error, 2 - Warning, 3 - Info
#               4 - Debug, 5 - Verbose
# If DEBUG_LEVEL is commented, Android's logging levels will be used
DEBUG_LEVEL = 2

# Intermediate position report, 1=enable, 0=disable
INTERMEDIATE_POS=0

# supl version 1.0
SUPL_VER=0x10000

# GPS Capabilities bit mask
# SCHEDULING = 0x01
# MSB = 0x02
# MSA = 0x04
# ON_DEMAND_TIME = 0x10
# GEOFENCE = 0x20
# default = ON_DEMAND_TIME | MSA | MSB | SCHEDULING | GEOFENCE
CAPABILITIES=0x37

# Accuracy threshold for intermediate positions
# less accurate positions are ignored, 0 for passing all positions
# ACCURACY_THRES=5000

################################
##### AGPS server settings #####
################################

# FOR SUPL SUPPORT, set the following
SUPL_HOST=supl.google.com
SUPL_PORT=7276

# FOR C2K PDE SUPPORT, set the following
# C2K_HOST=c2k.pde.com or IP
# C2K_PORT=1234

####################################
#  LTE Positioning Profile Settings
####################################
# 0: Enable RRLP on LTE(Default)
# 1: Enable LPP_User_Plane on LTE
# 2: Enable LPP_Control_Plane
# 3: Enable both LPP_User_Plane and LPP_Control_Plane
LPP_PROFILE = 0

################################
# EXTRA SETTINGS
################################
# NMEA provider (1=Modem Processor, 0=Application Processor)
NMEA_PROVIDER=0

##################################################
# Select Positioning Protocol on A-GLONASS system
##################################################
# 0x1: RRC CPlane
# 0x2: RRLP UPlane
# 0x4: LLP Uplane
A_GLONASS_POS_PROTOCOL_SELECT = 0

Saturday, July 11, 2015

dnsmasq cache flags

for my reference, dnsmasq cache flags:



# pkill -USR1 dnsmasq

Tuesday, July 07, 2015

dotted quad to decimal and back, in bash




bash snippet to convert IP address to decimal:

$ cat ip2d.sh
#!/bin/bash

IFS=.
set -- $*
echo $(( ($1*256**3) + ($2*256**2) + ($3*256) + ($4) ))


Conversely, to convert from decimal to dotted quad address:



$ cat d2ip.sh
#!/bin/bash

IFS=" " read -r a b c d  <<< $(echo  "obase=256 ; $1" |bc)
echo ${a#0}.${b#0}.${c#0}.${d#0}

Here they are in action:

google.com has address 216.58.216.142
$ ./ip2d.sh 216.58.216.142
3627735182
$ ./d2ip.sh 3627735182
216.58.216.142

Sunday, March 15, 2015

samsung Galaxy S3 UMTS to unlock

nvram rebuild:

just flash a TW rom. (example)

Once you are in stock ROM and gotten through all the annoying pop-ups, open your dialer and type in *#197328640#
it should open up a menu, you want to go to Mainmenu > UMTS > Common > NVREBUILD > NVREBUILD > Once you select to rebuild the NVRAM and it finishes don't exit the menu wait about 30 seconds long press power button and select Resta.

 To unlock your Galaxy S3 OR NOTE 2:

To unlock your Galaxy S3 OR NOTE 2:
Attention S3 users, you need to update your S3 to 4.1.1 Jelly Bean which was released today December 3 by Samsung in order to be able to unlock your phone.
Just dial the following keys *#197328640#

Main Menu > [1] UMTS > [1] Debug Screen > [8] Phone Control > [6] Network Lock > Options [3]Perso SHA256 OFF > (after choosing this option, wait about 30 seconds, then go back one step by pressing the Menu button then select Back, now you are in [6] Network Lock then choose [4] NW Lock NV Data INITIALLIZ ..... wait for a minute then reboot your phone

Followers


Creative Commons License
This work is licensed under a Creative Commons License.