A Generative Approach for Android Sensor-based Applications - Ponciano, Tarik; Tabosa, Davi; Viana, Windson; Duarte, Paulo; Carmo, Rafael (Proceedings of the Brazilian Symposium on Multimedia and the Web (WebMedia); 2020: Proceedings of the 26th Brazilian Symposium on Multimedia and the Web, 2020)
As smartphones increased in popularity, mobile devices became a crucial technological element of our time. Beyond the end-user platform, smartphones have several sensors to capture and characterise the user's context. Current Context-Aware Mobile (CAM) applications use this data to improve user experience by filtering data, services, and, even, adapting their behaviour. The development of CAM applications can be challenging for mobile developers, due to the diversity of mobile hardware ecosystem and sensor APIs' complexity. This paper presents EasyContext, a visual tool for designing and generating contextual rules for mobile devices, using the Google Awareness API as its contextual information provider. Mobile developers specify what to capture and when to react to context-changes in the visual tool and these contextual rules are exported to Android projects. We evaluated our approach with developers, which were selected to participate in a quasi-experiment. The experiment involves developing two mobile applications using both EasyContext and Google Awareness API. Preliminary results show that it is possible to build applications with fewer lines of code compared to the Google Awareness API. According to the developers, the proposed approach has better readability and makes it easier to design contextual rules.