Tag Archives: android

Measuring Android Power Consumption

I did my software engineering Masters thesis (2012) on Android power management and I learned, as part of my research, that most app developers have no idea how much power their app demands from their Android device’s battery.  Some who thought they were looking at power were confusing other metrics with power. At the time, tools for measuring power were not easy to obtain (costly, and hard to measure power inside a phone).

Now there is an app that provides many metrics about what apps are doing on Android, including power.

Go to the Google Play store, search for Trepn Profiler and install that app (from Qualcomm, who makes the Snapdragon processor used in most phones).

For a quick look at battery power in a strip chart format, select Network Activity and see a chart like this:

Screenshot_20151102-160041

Then select CPU Usage Monitor and identify what percent of CPU time is being used by each app. Initially the display will show “No applications are running” – wait a moment and gradually, apps will begin to show up in the list, with the % of CPU core they are using, shown at right. This may help you spot apps that are using an unexpected amount of power.

If possible, delete apps that you never or rarely use. Many lurk in the background and periodically run a fraction of a second, infrequently. While each individual app has little impact, the total of all apps may start to have an impact that you notice.

For more information about Trepn and estimating power consumption, read the linked article, below.

Trepn Profiler

Source: How to Measure Power Consumption Using Free Software | Mostly-Tech

 

Free-Download App Inventor Text Files Cheat Sheet

Download here: App Inventor Basic Text Files Cheat Sheet (PDF)

High res, suitable for printing. Feel free to share with others.

App Inventor sample source code: TextFile.aia

Be sure to follow the links for more information about text files and where they are stored on your device and how to transfer files to your computer.

Here is a GIF image but use the PDF for printing:

Voila_Capture 2015-11-02_10-45-33_AM

E-Books and Printed Books

If you find these tutorials helpful (I hope you do!) please take a look at my books on App Inventor. To learn more about the books and where to get them (they are inexpensive) please see my App Inventor Books page.

  • App Inventor 2 Introduction (Volume 1 e-book)
    Step-by-step guide to easy Android programming
  • App Inventor 2 Advanced Concepts (Volume 2 e-book)
    Step-by-step guide to Advanced features including TinyDB
  • App Inventor 2 Databases and Files (Volume 3 e-book)
    Step-by-step TinyDB, TinyWebDB, Fusion Tables and Files
  • App Inventor 2 Graphics, Animation and Charts (Volume 4 e-book and printed book)
    Step-by-step guide to graphics, animation and charts

Thank you for visiting! — Ed

Free-Download App Inventor Location Sensor Cheat Sheet

Download here: App Inventor Location Sensor Cheat Sheet (PDF)

High res, suitable for printing. Feel free to share with others.

App Inventor sample source code: Location_WhereAmI.aia

Here is a GIF image but use the PDF for printing – also, where it says “enter a mailing address”, that should probably be “enter a street address”!

Voila_Capture 2015-10-28_12-21-17_PM

Post comments here or on our Facebook group page. Thank you!

E-Books and Printed Books

If you find these tutorials helpful (I hope you do!) please take a look at my books on App Inventor. To learn more about the books and where to get them (they are inexpensive) please see my App Inventor Books page.

  • App Inventor 2 Introduction (Volume 1 e-book)
    Step-by-step guide to easy Android programming
  • App Inventor 2 Advanced Concepts (Volume 2 e-book)
    Step-by-step guide to Advanced features including TinyDB
  • App Inventor 2 Databases and Files (Volume 3 e-book)
    Step-by-step TinyDB, TinyWebDB, Fusion Tables and Files
  • App Inventor 2 Graphics, Animation and Charts (Volume 4 e-book and printed book)
    Step-by-step guide to graphics, animation and charts

Thank you for visiting! — Ed

All new tutorial: Using TinyDB in App Inventor

I have completely rewritten and re-done my original tutorial on using TinyDB in App Inventor.

You can see the all new rewrite at Using TinyDB in App Inventor

TinyDB is a database used to store and retrieve values to semi-permanent storage on your phone or tablet. Unlike variables, which vanish when your app closes or your phone is turned off, values stored in the TinyDB are retained and can be accessed again, much later.

The original post was a popular post here on the blog, but it was brief and left out some details. I started over from scratch and wrote an all new, complete tutorial, with screen shots and blocks code, and downloadable App Inventor source code. Hope this helps!

E-Books and Printed Books

If you find these tutorials helpful (I hope you do!) please take a look at my books on App Inventor. To learn more about the books and where to get them (they are inexpensive) please see my App Inventor Books page.

  • App Inventor 2 Introduction (Volume 1 e-book)
    Step-by-step guide to easy Android programming
  • App Inventor 2 Advanced Concepts (Volume 2 e-book)
    Step-by-step guide to Advanced features including TinyDB
    • App Inventor 2 Databases and Files (Volume 3 e-book)
      Step-by-step TinyDB, TinyWebDB, Fusion Tables and Files
      Buy from: Amazon, Google Books, Kobo Books
  • App Inventor 2 Graphics, Animation and Charts (Volume 4 e-book and printed book)
    Step-by-step guide to graphics, animation and charts

Thank you for visiting! — Ed

FIRST Tech Challenge (Robotics) can now use App Inventor

Early in 2015, FIRST announced that the First Tech Challenge (FTC) robotics platform would be powered by the Qualcomm Snapdragon processor (the same processor used in most Android phones).

Starting with the Fall 2015 FTC competition, students can now control the robot using App Inventor. (Go here and page down to App Inventor Download and Resources and follow that link).

FTC uses a version of App Inventor that is installed on a local computer rather than running over the Internet, as we do with MIT App Inventor.

About FIRST

FIRST robotics is an “academic sport” for the mind as teams are faced with the challenge of conceptualizing, designing and building a complex robot to solve a challenge. The Mission of FIRST Robotics:

“Our mission is to inspire young people to be science and technology leaders, by engaging them in exciting mentor-based programs that build science, engineering and technology skills, that inspire innovation, and that foster well-rounded life capabilities including self-confidence, communication, and leadership.”

Volunteering

I am in my 8th year of volunteering as an engineering mentor to high school robotics teams. I am currently a volunteer with Glencoe High School’s Team #4488 “Shockwave” team where I am the lead mentor for Apps Software. Our team is a student-led team. The students make the design choices and implement the solutions. The mentors assist with technical and management training and specialized learning.

Our team, like many FIRST teams, is run similar to a business with separate sub-teams not only for robotics (mechanical, electrical, robot programming, CAD) but also other functions (marketing, business, strategy, web and applications software, graphic design) and even an animation team. Our applications team produces support software for the entire team by creating custom tablet apps and Windows applications software that assist in various information collection, analysis and processing functions. Last year, the team also created a robotics game that is available in the Google Play store.

There are many opportunities for volunteering – from technical engineering to business and marketing, graphic and art design, wood and metal working, CAD, and teaching. Visit usfirst.org to learn more!

Free-Download App Inventor Bluetooth Communications Cheat Sheet

Download here: App Inventor Bluetooth Cheat Sheet (PDF)

Covers basic Bluetooth text communications with links to tutorials on sending numeric and binary data, and connecting to Arduino over App Inventor Bluetooth.

App Inventor sample source code available here.

High res, suitable for printing. Feel free to share with others.

Here is a GIF image of the first page but use the PDF for printing (higher resolution) and it includes both pages:

Voila_Capture 2015-10-28_08-35-41_PM

Post comments here or on our Facebook group page. Thank you!

E-Books and Printed Books

If you find these tutorials helpful (I hope you do!) please take a look at my books on App Inventor. To learn more about the books and where to get them (they are inexpensive) please see my App Inventor Books page.

  • App Inventor 2 Introduction (Volume 1 e-book)
    Step-by-step guide to easy Android programming
  • App Inventor 2 Advanced Concepts (Volume 2 e-book)
    Step-by-step guide to Advanced features including TinyDB
  • App Inventor 2 Databases and Files (Volume 3 e-book)
    Step-by-step TinyDB, TinyWebDB, Fusion Tables and Files
  • App Inventor 2 Graphics, Animation and Charts (Volume 4 e-book and printed book)
    Step-by-step guide to graphics, animation and charts

Thank you for visiting! — Ed