{"id":1746,"date":"2020-05-09T02:40:02","date_gmt":"2020-05-09T02:40:02","guid":{"rendered":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/?page_id=1746"},"modified":"2020-05-17T07:34:47","modified_gmt":"2020-05-17T07:34:47","slug":"mobile-application_fg10","status":"publish","type":"page","link":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/female-students\/fg10\/mobile-application_fg10\/","title":{"rendered":"Mobile Application_FG10"},"content":{"rendered":"<p>In order to better show the project outcomes, an Android mobile application has been developed. The application allows its users to choose between different buildings, then, it will provide the user with real-time readings from the system sensors and modules. The application has been built using Android Studio which is open-source software that supports Java and Kotlin languages for android applications. In this project Java has been selected since it is widely used programming language and has much more supporting documents and community, also, it has a faster building process than Kotlin. The application consists mainly of a home page that has a list of tested buildings, a page for monitoring the sensors and camera readings. Within the application\u2019s Java code, different classes and activities have been implemented. In addition, access to a database is required for reading data from it and writing to it. For testing and debugging the code, Android Studio emulator or real Android device can be used.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-1747 aligncenter\" src=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/app-front.jpeg\" alt=\"\" width=\"198\" height=\"396\" srcset=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/app-front.jpeg 800w, http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/app-front-150x300.jpeg 150w, http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/app-front-768x1536.jpeg 768w, http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/app-front-512x1024.jpeg 512w\" sizes=\"auto, (max-width: 198px) 100vw, 198px\" \/><\/p>\n<h3><\/h3>\n<h3><strong>Android Studio Activities<\/strong><\/h3>\n<p>Since the application has to do several tasks, each task or feature can be represented using something called activity, which is basically a Java class where the developer can describe the task, upload user interface (UI) elements and the needed Extensible Mark-up Language (XML) file for each activity.<\/p>\n<ul>\n<li><strong>Home page Activity\u00a0<\/strong><\/li>\n<\/ul>\n<p style=\"text-align: left;padding-left: 30px\">Home page activity is designed to be the main activity for the user, where the application user can reach other activities from home page activity. This activity is linked to an XML file that has basically buttoned which are operated using the common method in android which is setOnClickListener().<\/p>\n<ul>\n<li style=\"text-align: left\"><strong>New Building Activity<\/strong><br \/>\nNew building activity allows users to add new buildings and create their profiles after clicking on add new building button using the name and address in the time of need to test them.\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0\u00a0<img loading=\"lazy\" decoding=\"async\" class=\"wp-image-1769 aligncenter\" src=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/Capture.gif\" alt=\"\" width=\"393\" height=\"381\" \/><\/li>\n<li><strong>Building List Activity<\/strong><\/li>\n<\/ul>\n<p style=\"padding-left: 30px\">Building list activity is for viewing and accessing the profiles for each building. Unlike the previous activity, this one is to read the data that has been stored in new building activity from firebase. The activity is linked to several XML files that include recycler view and card view. Both features in Android studio will help in updating the list when a user registers a new building. Furthermore, the activity needs another Java class to store any new values.<\/p>\n<ul>\n<li><strong>Doha Tower Activity<\/strong><\/li>\n<\/ul>\n<p style=\"padding-left: 30px\">Doha tower activity is mentioned here as an example and the same method will be applied for each tower mentioned in the list. In these activities, users will see sensors\u2019 data that are retrieved from firebase in real-time. Moreover, feedback will be given to the user about the status of the drone, based on the Lidar sensors readings. It has been specified in the code that whenever at least one Lidar shows 1m distance as specified in the system constraints, the user will be notified about that. Also, there are buttons to activate Lepton 2.5 and Raspberry Pi camera.<\/p>\n<p style=\"padding-left: 30px\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-1750 aligncenter\" src=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/testing.jpeg\" alt=\"\" width=\"198\" height=\"396\" srcset=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/testing.jpeg 800w, http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/testing-150x300.jpeg 150w, http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/testing-768x1536.jpeg 768w, http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/testing-512x1024.jpeg 512w\" sizes=\"auto, (max-width: 198px) 100vw, 198px\" \/><\/p>\n<h3 style=\"text-align: center\"><strong>To have an overview for activities and classes flowchart<\/strong>\u00a0below<\/h3>\n<h3><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-1751 aligncenter\" src=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/flow-chart.gif\" alt=\"\" width=\"535\" height=\"386\" \/><\/h3>\n<h3><strong>Firebase\u00a0Database<\/strong><\/h3>\n<p>Firebase is a free database provided by Google for mobile and web development, and it is used as the database for this project. Firebase is used to store the retrieved data from sensors, and it supports real-time and offline access for the database. Also, it provides low latency and security. Firebase allows storing and synchronizing data between users and real-time. In this project, whenever the data is changed either from sensors or users\u2019 side, it is stored and updated directly in the cloud. Firebase data is formatted as JavaScript Object Notation (JSON).<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-1763 aligncenter\" src=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/files\/2020\/05\/app.gif\" alt=\"\" width=\"432\" height=\"144\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In order to better show the project outcomes, an Android mobile application has been developed. The application allows its users to choose between different buildings, then, it will provide the user with real-time readings from the system sensors and modules. The application has been built using Android Studio which is open-source software that supports Java &hellip; <a href=\"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/female-students\/fg10\/mobile-application_fg10\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":186,"featured_media":0,"parent":234,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-1746","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/pages\/1746","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/users\/186"}],"replies":[{"embeddable":true,"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/comments?post=1746"}],"version-history":[{"count":11,"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/pages\/1746\/revisions"}],"predecessor-version":[{"id":2124,"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/pages\/1746\/revisions\/2124"}],"up":[{"embeddable":true,"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/pages\/234"}],"wp:attachment":[{"href":"http:\/\/blogs.qu.edu.qa\/ee-sdp-sp2020\/wp-json\/wp\/v2\/media?parent=1746"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}