Office Hours — Today, December 15

Yesterday, December 14

Mark M.
has entered the room
Mark M.
turned on guest access
trdillah
has entered the room
trdillah
Hi Mark!
Mark M.
howdy, trdillah!
how can I help you today?
trdillah
View paste
I have a question about achartengine. My first question is posted here: 
http://stackoverflow.com/questions/8522639/achartengine-inserting-dates-as-x-values-in

I was also wondering if the code used for the PowerTutor was available via opensource (Tuning Android Applications):
Dec 15
4:00 PM
Mark M.
I know nothing about AChartEngine
PowerTutor source code is available from the project site
it is actually hosted at GitHub
trdillah
Thanks! I was hoping that there may be a good example there
Mark M.
oh, of AChartEngine -- possibly, not sure what they use
trdillah
That's true. I've been looking for good charting examples in general though
It should help
View paste
My next question was if you have suggestions for updating applications that aren't on the market. How do we set it up to detect changes and send a message to the device?
IE, if I deploy an .apk file to a group of people, can they be notified of updates without the app being on the market?
Mark M.
the typical solution is for the app to poll some URL on your Web site, where you have the version information, then have it download the APK when there is an update available
trdillah
Oh I see. Will the download happen automatically? Or will the user have to initiate the download?
Mark M.
that's your decision
your code is the one detecting that there is a new version
your code will be responsible for either doing the download, informing the user about the available download, etc.
4:05 PM
trdillah
I see. Is this method documented anywhere or is this just the standard method of updating?
Mark M.
it's not part of Android
it is your code
trdillah
Ok
Mark M.
I am not aware of a third-party library that wraps all of this up for you
I will write one in 2012 if nobody beats me to it
trdillah
lol, ok
I have one final question.
It has to do with an ANR that I've seen intermittently.
I handle long tasks using services and asyncrhonous tasks so I'm not sure why I see this error
View paste (1 more line)
12-14 17:14:34.193: ERROR/ActivityManager(59): ANR in com.cmu.community
12-14 17:14:34.193: ERROR/ActivityManager(59): Reason: Broadcast of Intent { act=com.cmu.community.ACTION_STEPGREENMANAGER flg=0x4 (has extras) }
12-14 17:14:34.193: ERROR/ActivityManager(59): Load: 4.83 / 3.61 / 2.46
12-14 17:14:34.193: ERROR/ActivityManager(59): CPU usage from 6718ms to 127ms ago:
12-14 17:14:34.193: ERROR/ActivityManager(59):   m.cmu.community: 40% = 26% user + 14% kernel / faults: 3776 minor 38 major
12-14 17:14:34.193: ERROR/ActivityManager(59):   adbd: 25% = 2% user + 22% kernel / faults: 7 minor
12-14 17:14:34.193: ERROR/ActivityManager(59):   system_server: 22% = 15% user + 6% kernel / faults: 1463 minor 12 major
12-14 17:14:34.193: ERROR/ActivityManager(59):   logcat: 7% = 1% user + 6% kernel / faults: 24 minor
12-14 17:14:34.193: ERROR/ActivityManager(59):   m.android.phone: 1% = 0% user + 1% kernel / faults: 206 minor 1 major
12-14 17:14:34.193: ERROR/ActivityManager(59):   ndroid.launcher: 1% = 1% user + 0% kernel / faults: 284 minor 4 major
12-14 17:14:34.193: ERROR/ActivityManager(59):   putmethod.latin: 0% = 0% user + 0% kernel / faults: 215 minor
12-14 17:14:34.193: ERROR/Activi
...
Mark M.
that's a different ANR trace than I am used to seeing
what does your com.cmu.community.ACTION_STEPGREENMANAGER BroadcastReceiver do in onReceive()?
4:10 PM
trdillah
it displays values to the UI
well to the application widget
Mark M.
is it doing any disk I/O or network I/O?
trdillah
There is network I/O being done by the service itself
Mark M.
I am interested in the BroadcastReceiver, not a Service, AFAICT from the stack trace
trdillah
oh, it launches a background service - the background service handles the Network I/O
Mark M.
so all the BroadcastReciever does is call startService()?
trdillah
yes
Mark M.
is the Service an IntentService?
trdillah
yes
View paste (2 more lines)
@Override
		public void onReceive(Context context, Intent intent) {
				
			// Moved to an IntentService, as the http might take long to get a reply from the webservice.
		  
			Log.v(TAG, "Entering StepgreenReceiver onReceive");
			if(mContext == null)
				mContext = context;
			
			if(intent.getAction().equals(ACTION_STEPGREENMANAGER))
			{	
				Log.v(TAG, "about to start bgStepgreen Service");
				Intent bgStepgreenService = new Intent(context, StepgreenService_BG.class);
				bgStepgreenService.setAction(intent.getAction());
				context.startService(bgStepgreenService);
...
Mark M.
then I have no clue what might be causing that ANR report
4:15 PM
trdillah
ok. it's intermittent and I can't reproduce the issue
(to give you background info, i'm a student researcher)
Mark M.
I figured the CMU was Carnegie Mellon University
trdillah
yes :)
Mark M.
spent the summer of 1995 there
trdillah
nice!
i'm not an experienced android developer so i appreciate all of the help you provide!
Mark M.
happy to help!
4:20 PM
trdillah
"AND i appreciate" -- I'm sure if I had experience, you'd still be of great help!
Thanks again and have a great day!
Mark M.
you too!
trdillah
I may just stick around to see what types of questions come up. I can always learn new things!
Mark M.
sure, no problem
as you can see, attendance at these chats varies widely
trdillah
I can imagine
5:00 PM
Mark M.
well, that's a wrap for today's chat
next one is Tuesday, 7:30pm Eastern
trdillah
ok, thanks again!
bye!
Mark M.
have a pleasant day!
trdillah
has left the room
Mark M.
turned off guest access

Yesterday, December 14

 

Office Hours

People in this transcript

  • Mark Murphy
  • trdillah