Android 1.5 Spare parts Battery History does not display any data

by Jeff Sharkey » Thu, 21 May 2009 05:22:15 GMT

Sponsored Links
 Because the emulator doesn't have a battery?


Jeff Sharkey


Other Threads

1. IntentDemo


I have recorded my second screencast which talks at a very basic level
about Intents. here is the link

The sound quality is unfortunately low and I am trying to remedy that
for my subsequent demonstrations. Any of your [other] comments /
criticisms are most welcome. Simply visit
and drop me an email.


2. parse XML from http response

Hi all,

i need Your help:

i become XML output from  server (who needs username and password for 
access)  and i d like to read the information in my android app. I've 
made HttpConnection to connect the server and authenticate. Then i read 
the HttpResponse - it looks like this:

private void getResponse() {
        try {
             //huc ist the HttpURLConnection

            StringBuffer sb = new StringBuffer(huc.getContentLength());
            InputStreamReader isr = new 
            char buff[] = new char[huc.getContentLength()];
            int n;
            while ((n =, 0, huc.getContentLength() - 1)) > 
0) {
                sb.append(buff, 0, n);
            response = sb.toString();  //as String is easy ...  but with 
the xml elements ... see next:
        } catch (IOException e1) {
            // TODO Auto-generated catch block

        try {
               //now i need to parse this output into Array only with 
the attributs from the
               XMLHandler h = new XMLHandler();
               SAXParserFactory f = SAXParserFactory.newInstance();
               SAXParser sp = f.newSAXParser();
               XMLReader xr = sp.getXMLReader();
               sp.parse(huc.getInputStream(), h);  // here is my 
problem: parse does not support Stream input ..

           catch (SAXParseException error) {

               Log.d("\nParse Error", "\n Num: " + error.getLineNumber());
               Log.d("\n", error.getMessage() );
               }catch (Throwable t) {

any help is welcome!


3. Camera Test Phone

4. Thread safety of using a Handler

5. A Bitmap/Drawable from GTalk avatar?

6. Where do you embed application version ?

7. Help on porting with ME4Android