Andrew Mccuan

CMPS 4350: Advanced Software Engineering

Project 3: Bubble Level

Bubble Level

Project Overview

The idea of this mobile app will be a bubble level that uses an android devices rotation to move a visual bubble level around the phone to show if a surface is level. This app will also have a "Tare" type button that will keep the phones current level (degree angle) and can be used as the new level. Then there will be a reset button to reset the level back to normal.

This app will be built in android studio and will be made to be played on most android devices on the market.

Prototype
Sensors of the Bubble Level App

TYPE_ORIENTATION

The sensor our app will be using will be the TYPE_ORIENTATION, this will determine the orientation the phone will be in. And we can use this to determine in which direction the bubble should move around the level.

Lab 12: Project 3 Update Questions

1. What kind of data will you collect for sensors?

The type of data that will be collected is an array of float values from the TYPE_ORIENTATION sensor. The array will hold the x, y, z axis values respectively, these values are considered unitless.

2. What is the range of possible values?

The possible values of this sensor or 0 to 359.

3. How will you test the sensor?

I will be testing the sensor in two ways, one using the Android Emulator's virtual sensors to test the rotation sensor and the other way is I have an old Android phone that I can test the app with.

4.Push your project to github. How did you get it there?

I created a repository on GitHub and then cloned the blank repo onto my machine into an area I wanted it. Then I copied my android project into, committed and pushed my changes into the repo and work out of this directory. https://github.com/Shankapotamus66/BubbleLevel

Bubble Level Update Screenshots (4/30/2021)

Surface Level

45 Degrees

0 Degrees

90 Degrees

Final Product

Android Requrements:

Designed for API level 15 and older.
Designed for phones that have a 1440p screen resoltion.
Note: This will not work on Emulator Movement.

Orientation Sensor Data Change Code

Straight Bubble Level Drawing code

Surface Level

Straight Level

Download the Bubble Level APK here: