27 lines
583 B
Bash
Executable File
27 lines
583 B
Bash
Executable File
#!/bin/bash
|
|
# Set date based on current system time.
|
|
# Perhaps you should make sure your local clock is correct. :)
|
|
|
|
# sudo ntpdate time.mit.edu
|
|
|
|
echo "Be the root"
|
|
adb root
|
|
echo "Current time on analyzer"
|
|
adb shell busybox date
|
|
echo
|
|
NOW=`date -u "+%Y-%m-%d %H:%M:%S"`
|
|
echo "Setting time to "
|
|
adb shell busybox date -s \"$NOW\"
|
|
echo
|
|
echo "Current time on analyzer"
|
|
adb shell busybox date
|
|
echo
|
|
echo "Write time to hardware clock"
|
|
adb shell hwclock -w -u
|
|
echo "Current hardware clock time"
|
|
adb shell hwclock -u
|
|
|
|
# Set the timezone, ala:
|
|
#setprop persist.sys.timezone "America/Denver"
|
|
|