By Andy Woodruff
Mike Kaltschnee regaled us once again with an informative and fast-paced presentation about mobile apps. After some introductory comments and background information, he said that he would show us how to build a working mobile application … and that he could complete it in just a few minutes.
And he did, indeed. He started from scratch, and within 10 minutes had an app built and uploaded to his cell phone. The required time would have been even less than 10 minutes, if he had not carefully explained all of his steps to us! It was clear to all in the room that any one of us could do this successfully, easily, and for no cost.
Mike had discovered the system called “MIT App Inventor 2”, which is free and designed for non-programmers to build apps for Android phones. Mike explained that this system is compatible only with Android phone. Apple’s iPhones utilize the iOS operating system, and it is more difficult to build apps for that platform. In addition, MIT App Inventor 2 works only on the Chrome browser, and the user must sign in. The application runs in the browser, and data is stored in the Cloud.
In order to use MIT App Inventor 2, Mike downloaded and opened its main application onto his computer … and downloaded its “companion app” to his cell phone (from the Google Play Store). He said it was necessary that both be on the same network. This arrangement allowed him to design the app on his computer and test it live on his cell phone.
MIT App Inventor 2 provides a simple “integrated development environment” (IDE) that does not require any conventional programming skill. The “design” work involves simple drag and drop steps, using components that can fit with one another in only certain arrangements, similar to jigsaw parts or lego blocks. This approach assures that a user cannot “make a mistake” by connecting components incorrectly. When positioned correctly, the shapes fit and the components “snap” together.
There is a design window with a list of components on the left side of the screen and a list of controls on the right side. One simply opens a “new project” and then uses the mouse to pick up components from the left side and place them within the design in the center of the screen. Then one can adjust detailed properties, like size and color, on the right side.
In the first version of the app that Mike built in front of us, the cell phone greeted us by voice when a button was depressed. Mike needed to use only a few components from the left side of the screen. The principle item was a “TextToSpeech” component that caused the cell phone to speak words that Mike had typed into this component.
Mike demonstrated the ability to use sensors within the phone. For instance, an Android phone has an accelerometer (a sensor that can detect movement). Mike set up a second version of his app to recognize “shaking” and to complain verbally when Mike would shake the phone. (“Stop shaking me, please!”) As another demonstration, he converted his phone into a sort of Etch-A-Sketch, by using the accelerometer’s shake detection to erase the contents of his display. The audience loved this!
Mike emphasized that apps created with the MIT App Inventor 2 could access all or nearly all the sensors and features of the phone. In particular, a user can utilize the camera, media player, a barcode scanner, proximity sensor, orientation sensor, and the clock. The user can design apps that send texts or contact social media. As yet another example, Mike modified his app to show a ball bouncing around the cell phone display.
There are tutorials on the appinventor.mit.edu website. Mike said he first learned of this app builder from his daughter, who is a school student.
Audience questions included:
- Can one add one’s own code, rather than just using the drag-and-drop feature? Mike doubts that this is possible.
- How does one distribute the result to others? Mike said that one can save an .apk file. This is the standard for apps on Android phones.
Mike is an entrepreneur in technical fields, and he is a co-founder of Danbury Hackerspace. He has spoken to us on several previous occasions. Mike is available at mike@danburyhackerspace.com.