[android-developers] Re: Keystore

2011-04-26 Thread Sahil Verma
Seconding the usage of password managers.  I put my keystore passphrase in a 
password file using KeePass.  My blog post about password management might 
be of some use to you:

http://vermasque.blogspot.com/2011/04/simple-effective-password-management.html

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Problem installing android sdk in ubuntu 10.10

2011-04-26 Thread Sahil Verma
To make sure it's not a problem with SDK manager, try going to that URL with 
your web browser.  You should see a valid XML file when you go to that link.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Database shared by Activity and Service. What's the best approach?

2011-04-17 Thread Sahil Verma
Instead of repeatedly hitting the database to see if something is available, 
you could find some way for the service to send the new datum to the 
application when it is received from the external device.  I think this 
could be achieved with an explicit intent.  This allows the application to 
only update the chart when a new data point is available, but does not 
require the application to repeatedly poll a database (application is the 
observer in the observer design pattern here).  The service would still 
store the data to persistence (SQLite database for now or binary 
file later as Dianne recommended).  

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: onSaveInstanceState(Bundle) onRestoreInstanceState(Bundle)

2011-04-15 Thread Sahil Verma
I've had this same problem too and actually posted to the mailing list a few 
weeks ago but got not responses:

https://groups.google.com/d/topic/android-developers/6GfbdsJIj9k/discussion

I was testing it on hardware by simply rotating the phone, changing the 
orientation and recreating the activity.  However, the problem occurred 
randomly for me; it was very hard to reproduce as instance state would be 
restored after most orientation changes.  On a handful of occasions, the 
instance state would be wiped out as my UI would display as if started anew. 
 I have no solution so far.  I did a search some time back on the Android 
issues list at Google Code to see if it was a known bug, but I found 
nothing.

One workaround would be to persistently store the state which you wish to be 
restored in onPause.  If the state bundles in onCreate or 
onRestoreInstanceState are not filled, you could restore from persistent 
state.


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: onSaveInstanceState(Bundle) onRestoreInstanceState(Bundle)

2011-04-15 Thread Sahil Verma
For sample code of what I was doing, you could take a look here:

https://github.com/vermasque/song-alarm/blob/master/src/org/vermasque/songalarm/SongAlarmActivity.java

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Creator problem using location.

2011-04-07 Thread Sahil Verma
The documentation for createFromParcel suggests that the location object 
should have been written to the parcel with  writeToParcel.  Have you tried 
this method on the location object instead of writeParcelable on the parcel 
object? 

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: adb devices returns an empty list

2011-04-04 Thread Sahil Verma
In order to see the connected device in Linux, I have to start adb
server as root.  You might have to kill an existing adb instance if it
is already running (pkill adb).

sudo adb start-server

adb devices

On Apr 4, 1:08 am, argongold argongol...@gmail.com wrote:
 Hi,
 I've a mini MID device and I am trying to use it for development/
 debugging purpose. But after all the setting steps( see below) . I am
 still not able to get device listed when I issue  'adb devices'
 command.

 Things I have done as follows:
 1. enable USB debugging on the device under Settings-Applications-

 Development-USB debugging

 2. I have changed the following file on my computer .
 /etc/udev/rules.d/51-android.rules and added the following line.
 SUBSYSTEM==usb, SYSFS{idVendor}==18d1, ATTR{idProduct}==0001,
 SYMLINK+=android_adb, MODE=0666, OWNER=MYNAME

 (on Computer)
 Command Issued  lsusb
 Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 005 Device 002: ID 1690:0741 Askey Computer Corp. [hex]
 Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 004 Device 002: ID 062a:6301 Creative Labs
 Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 Bus 001 Device 006: ID 18d1:0001
 Bus 001 Device 003: ID 0408:1fc3 Quanta Computer, Inc.
 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

 Note: device is connect to usb bus at Line no. 9  above .

 (on Computer)
 Command Issued  adb devices
 * daemon not running. starting it now on port 5037 *
 * daemon started successfully *
 List of devices attached

 (on Device itself)
 Command Issued  adbd
 cannot bind 'tcp:5037'

 (on Device itself)
 Command Issued  netstat -a | grep  5037

 nothing returns from above command.

 If you have experienced such issue please let me know steps to resolve
 it.  It seems the problem is on device side for which adbd returns
 'cannot bind 'tcp:5037'

 Thanks for your strong support.

 regards,
 argon

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Instance state randomly not being restored on orientation changes

2011-04-04 Thread Sahil Verma
I have an app that handles onSaveInstanceState and
onRestoreInstanceState appropriately in Android 2.2.  When I change
the orientation of the device, my UI shows the same state as shown
during the previous device orientation as expected.  However, if I
flip the orientation enough times in random fashion, it will
eventually show the home screen instead of my reoriented app.  When I
start my activity again from the home screen, it will show no state.
I don't have any insight into why this is happening and a search of
the bug database, Stack Overflow, and the discussions didn't turn up
anything.  Any clue why this is happening?

From logcat during USB debugging, I see a series of similar
orientation change statements and then suddenly activity start (last
group of statements).

04-03 17:13:47.153: INFO/WindowManager(1082): Setting rotation to 3,
animFlags=0
04-03 17:13:47.177: INFO/ActivityManager(1082): Config changed:
{ scale=1.0 imsi=310/4 loc=en_US touch=3 keys=2/1/2 nav=2/2 orien=2
layout=34 uiMode=17 seq=373}
04-03 17:13:47.231: INFO/UsageStats(1082): Unexpected resume of
org.vermasque.songalarm while already resumed in
org.vermasque.songalarm
04-03 17:13:47.536: INFO/WindowManager(1082): Setting rotation to 1,
animFlags=0
04-03 17:13:47.559: DEBUG/dalvikvm(8079): GC_FOR_MALLOC freed 9218
objects / 493160 bytes in 132ms
04-03 17:13:49.036: DEBUG/dalvikvm(1082): GC_EXPLICIT freed 643
objects / 29688 bytes in 171ms

04-03 17:13:49.036: INFO/WindowManager(1082): Setting rotation to 3,
animFlags=0
04-03 17:13:49.270: INFO/WindowManager(1082): Setting rotation to 0,
animFlags=0
04-03 17:13:49.294: INFO/ActivityManager(1082): Config changed:
{ scale=1.0 imsi=310/4 loc=en_US touch=3 keys=2/1/2 nav=2/2 orien=1
layout=34 uiMode=17 seq=374}
04-03 17:13:49.356: INFO/UsageStats(1082): Unexpected resume of
org.vermasque.songalarm while already resumed in
org.vermasque.songalarm
04-03 17:13:49.981: DEBUG/dalvikvm(1082): GC_EXPLICIT freed 505
objects / 21816 bytes in 100ms

04-03 17:13:49.981: INFO/WindowManager(1082): Setting rotation to 1,
animFlags=0
04-03 17:13:49.997: INFO/ActivityManager(1082): Config changed:
{ scale=1.0 imsi=310/4 loc=en_US touch=3 keys=2/1/2 nav=2/2 orien=2
layout=34 uiMode=17 seq=375}
04-03 17:13:50.044: INFO/UsageStats(1082): Unexpected resume of
org.vermasque.songalarm while already resumed in
org.vermasque.songalarm
04-03 17:13:51.208: DEBUG/dalvikvm(1082): GC_EXPLICIT freed 498
objects / 21616 bytes in 111ms

04-03 17:13:51.208: INFO/WindowManager(1082): Setting rotation to 0,
animFlags=0
04-03 17:13:51.231: INFO/ActivityManager(1082): Config changed:
{ scale=1.0 imsi=310/4 loc=en_US touch=3 keys=2/1/2 nav=2/2 orien=1
layout=34 uiMode=17 seq=376}
04-03 17:13:51.278: INFO/UsageStats(1082): Unexpected resume of
org.vermasque.songalarm while already resumed in
org.vermasque.songalarm
04-03 17:13:53.911: DEBUG/dalvikvm(1082): GC_EXPLICIT freed 1008
objects / 53840 bytes in 126ms

04-03 17:13:54.903: WARN/KeyCharacterMap(8079): Can't open keycharmap
file
04-03 17:13:54.903: WARN/KeyCharacterMap(8079): Error loading
keycharmap file '/system/usr/keychars/qtouch-touchscreen.kcm.bin'.
hw.keyboards.65538.devname='qtouch-touchscreen'
04-03 17:13:54.903: WARN/KeyCharacterMap(8079): Using default keymap: /
system/usr/keychars/qwerty.kcm.bin
04-03 17:14:06.356: INFO/ActivityManager(1082): Starting activity:
Intent { act=android.intent.action.MAIN
cat=[android.intent.category.LAUNCHER] flg=0x1020
cmp=org.vermasque.songalarm/.SongAlarmActivity bnds=[245,640]
[355,758] }

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en