sensors Article SleepPos App: An Automated Smartphone Application for Angle Based High Resolution Sleep Position Monitoring and Treatment Ignasi Ferrer-Lluis 1,2,3,* , Yolanda Castillo-Escario 1,2,3 , Josep Maria Montserrat 4,5 and Raimon Jané1,2,3,* Citation: Ferrer-Lluis, I.; Castillo-Escario, Y.; Montserrat, J.M.; Jané, R. SleepPos App: An Automated Smartphone Application for Angle Based High Resolution Sleep Position Monitoring and Treatment. Sensors 2021,21, 4531. https://doi.org/10.3390/s21134531 Academic Editors: Carlo Massaroni, Emiliano Schena and Domenico Formica Received: 3 June 2021 Accepted: 28 June 2021 Published: 1 July 2021 Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. Copyright: © 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https:// creativecommons.org/licenses/by/ 4.0/). 1Institute for Bioengineering of Catalonia (IBEC), Barcelona Institute of Science and Technology (BIST), 08028 Barcelona, Spain;
[email protected] 2Centro de Investigación Biomédica en Red de Bioingeniería, Biomateriales y Nanomedicina (CIBER-BBN), 28029 Madrid, Spain 3Department of Automatic Control (ESAII), Universitat Politècnica de Catalunya-Barcelona Tech (UPC), 08028 Barcelona, Spain 4 Sleep Lab, Pneumology Service, Hospital Clínic de Barcelona, 08036 Barcelona, Spain; [email protected] 5Centro de Investigación Biomédica en Red de Enfermedades Respiratorias (CIBERES), 28029 Madrid, Spain *Correspondence: [email protected] (I.F.-L.);
[email protected] (R.J.) Abstract: Poor sleep quality or disturbed sleep is associated with multiple health conditions. Sleep position affects the severity and occurrence of these complications, and positional therapy is one of the less invasive treatments to deal with them. Sleep positions can be self-reported, which is unreliable, or determined by using specific devices, such as polysomnography, polygraphy or cameras, that can be expensive and difficult to employ at home. The aim of this study is to determine how smartphones could be used to monitor and treat sleep position at home. We divided our research into three tasks: (1) develop an Android smartphone application (‘SleepPos’ app) which monitors angle-based high-resolution sleep position and allows to simultaneously apply positional treatment; (2) test the smartphone application at home coupled with a pulse oximeter; and (3) explore the potential of this tool to detect the positional occurrence of desaturation events. The results show how the ‘SleepPos’ app successfully determined the sleep position and revealed positional patterns of occurrence of desaturation events. The ‘SleepPos’ app also succeeded in applying positional therapy and preventing the subjects from sleeping in the supine sleep position. This study demonstrates how smartphones are capable of reliably monitoring high-resolution sleep position and provide useful clinical information about the positional occurrence of desaturation events. Keywords: accelerometry; biomedical signal processing; mHealth; monitoring; sleep position; smartphone; app; android 1. Introduction Sleep is a very important state for living organisms. It occupies approximately one third of our life [ 1 – 3 ] and it is known to affect emotional, physical and cognitive performance [ 4 ]. There have been many studies highlighting that poor sleep quality or disturbed sleep is associated with multiple health complications. These complications range from mental disorders [ 5 – 7 ] to cardiovascular and cerebrovascular diseases [ 8 – 10 ], which are the leading cause of death worldwide [11,12]. Sleep position is an important factor affecting the severity and occurrence of multiple diseases, which impacts sleep quality. It has been reported how lateral and prone sleep positions influence the occurrence of dry eye, ocular hypertension, and glaucoma [13–15]. Additionally, in late pregnancy, supine sleep position can lead to a reduced flow to the placenta [ 16 , 17 ] and result in poor fetal outcome, affecting fetal growth and increasing the risk of stillbirth, pre-eclampsia/eclampsia, gestational diabetes mellitus, cardiomyopathies and heart failure [ 18 , 19 ]. Furthermore, supine sleep position is also known to promote the Sensors 2021,21, 4531. https://doi.org/10.3390/s21134531 https://www.mdpi.com/journal/sensors
Sensors 2021,21, 4531 2 of 22 occurrence of apneas when compared to lateral and prone sleep positions, in a phenomenon known as positional obstructive sleep apnea (pOSA) [ 20 , 21 ]. Obstructive sleep apnea (OSA) is one of the most common diseases affecting sleep quality and is characterized by repetitive episodes of total or partial air pathway obstruction, which reduce the airflow and lead to hypoxia [22–25]. Multiple techniques can be used to monitor sleep quality and sleep position. There exist many questionnaires, such as the STOP-Bang [ 26 ] and Berlin [ 27 ] questionnaires, among others [ 28 ], which aim to determine the state of the patient and quantify the sleep quality. These questionnaires can include questions about sleep position, but they fail to properly determine the different sleep positions during the night and are not reliable enough due to their subjective nature [ 29 – 31 ]. Other techniques, such as polysomnography (PSG), which is the gold-standard test for diagnosing sleep-related diseases, use accelerometry-based sensors, as well as cameras, for monitoring sleep position, which leads to a more objective and reliable measure. However, the position obtained from PSG usually requires the validation of sleep technicians to properly determine the sleep position. Moreover, the PSG test is known to promote supine sleep position [ 32 , 33 ], due to the amount of wires and devices used. There are also studies which aimed to use a combination of video cameras and infrared cameras to reliably monitor and detect the different sleep positions in an unobtrusive manner [ 34 – 36 ]. However, these approaches require specific cameras to be installed on the bedframe or in the room. Even though there exist multiple techniques to monitor sleep position, it is usually only classified into four discrete categories: supine, prone, lateral left, and lateral right. Recent studies have demonstrated that a higher resolution sleep position, provided with an angular resolution, would be necessary to better diagnose pOSA [37,38] as there could exist variability within the four clinically used sleep positions categories (supine, prone, left and right). Positional treatment is a procedure by which a patient is forced to avoid sleeping in a certain sleep position. It is one of the less invasive methods to treat multiple diseases [ 39 – 41 ], and has proven to be efficient in patients suffering pOSA [ 42 , 43 ]. There are multiple ways to achieve it, including the use of bands covering the thorax which contain objects inside them to prevent certain specific sleep positions, such as the tennis ball technique (TBT) for pOSA [ 44 , 45 ]. Other approaches attach devices to the body which vibrate when sleeping in a certain position [ 46 – 48 ] to force the patient to change it. These devices achieved the same results as the TBT, but with improved sleep quality, quality of life, and compliance [ 49 ], as the long-term adherence of the TBT is poor [50]. Smartphones have appeared in the last years as tools with a great potential to monitor healthy and disturbed sleep [ 51 , 52 ]. They have great advantages, such as containing a lot of embedded sensors, and being worldwide available. Multiple approaches have already been made, including some previous work of our group, in developing tools to monitor sleep quality. These attempts included the analysis of audio to detect snoring and breathing [53–56] , the analysis of accelerometry to detect chest movement, respiration and sleep depth [ 57 – 60 ], and, sometimes, the combination of both with portable oximetry devices. Furthermore, smartphones have been tested as vibrational position treatment devices [ 61 ]. Nevertheless, despite the multiple approaches using smartphones to determine sleep quality, none have focused in providing high-resolution reliable sleep position and positional treatment at the same time. The aim of this research is to develop a smartphone application that can be used to reliably monitor sleep position and detect the positional occurrence of desaturation events and perform positional treatment. We divided our study into three tasks: (1) ‘develop an Android smartphone application (‘SleepPos’ app) which monitors angle-based highresolution sleep position and provides the option to simultaneously apply positional treatment; (2) test the smartphone application at home coupled with a pulse oximeter; and (3) explore the potential of this tool when combined with a pulse oximeter to detect the positional occurrence of desaturation events.
Sensors 2021,21, 4531 3 of 22 2. Materials and Methods 2.1. ‘SleepPos’ App: Design and Specifications We developed ‘SleepPos app’, an Android application to monitor high-resolution sleep position and eventually provide positional treatment to the patients. 2.1.1. Hardware Two different elements are needed to use the ‘SleepPos’ app: 1. An Android smartphone containing an accelerometry sensor. 2. A fixation system to place the smartphone over the sternum, in the configuration proposed by Nakano et al. [ 53 ] and successfully tested by our group [ 55 , 59 ]. We suggest the use of an elastic band for that purpose, as shown in Figure 1a. Sensors 2021, 21, x FOR PEER REVIEW 3 of 22 explore the potential of this tool when combined with a pulse oximeter to detect the positional occurrence of desaturation events. 2. Materials and Methods 2.1. ‘SleepPos’ App: Design and Specifications We developed ‘SleepPos app’, an Android application to monitor high-resolution sleep position and eventually provide positional treatment to the patients. 2.1.1. Hardware Two different elements are needed to use the ‘SleepPos’ app: 1. An Android smartphone containing an accelerometry sensor. 2. A fixation system to place the smartphone over the sternum, in the configuration proposed by Nakano et al. [53] and successfully tested by our group [55,59]. We suggest the use of an elastic band for that purpose, as shown in Figure 1a. Figure 1. Image of the fixation system (a), composed of an elastic band and a bag which allows to place the smartphone over the sternum (b) in the desired configuration to run the ‘SleepPos’ app. The smartphone accelerometry sensor should be providing positive values (c) when accelerations occur from right to left (X-axis, red arrow), from toe to head (Y-axis, yellow arrow), and from front to back (Z-axis, green arrow), defining the X–Z plane, where the sleep angle is calculated, and the Y–Z plane, where the stand angle is calculated. An example of the placement of these different elements can be seen in Figure 1b, where the elastic band proposed is placed over the sternum and contains a smartphone inside with the ‘SleepPos’ app. In Figure 1c we can observe how the accelerometry sensor should be placed for the app to function properly. The smartphone accelerometry sensor should be providing positive values when the acceleration goes from right to left (X-axis, red arrow), from toe to head (Y-axis, yellow arrow), and from front to back (Z-axis, green arrow), thus defining the X–Z plane, where the sleep angle is calculated, and the Y–Z plane, where the stand angle is calculated. The sleep angle provides information about the sleep position and the rotation of the subject while sleeping. With this configuration, a sleep angle of 0° belongs to a pure left sleep position, 90° belongs to a pure supine position, ±180° belongs to a pure right position, and −90° belongs to a pure prone position. The stand angle provides information whether the subject is standing or lying in bed, and, with this configuration, a stand angle of ±180° belongs to a stand position, 0° belongs to a headstand position, and 90° and −90° belong to a pure laying position. The developed app allows visual validation of each sleep position orientation, to ensure that the smartphone is being used correctly, and is explained in the following section. Figure 1. Image of the fixation system ( a ), composed of an elastic band and a bag which allows to place the smartphone over the sternum ( b ) in the desired configuration to run the ‘SleepPos’ app. The smartphone accelerometry sensor should be providing positive values ( c ) when accelerations occur from right to left (X-axis, red arrow), from toe to head (Y-axis, yellow arrow), and from front to back (Z-axis, green arrow), defining the X–Z plane, where the sleep angle is calculated, and the Y–Z plane, where the stand angle is calculated. An example of the placement of these different elements can be seen in Figure 1b, where the elastic band proposed is placed over the sternum and contains a smartphone inside with the ‘SleepPos’ app. In Figure 1c we can observe how the accelerometry sensor should be placed for the app to function properly. The smartphone accelerometry sensor should be providing positive values when the acceleration goes from right to left (X-axis, red arrow), from toe to head (Y-axis, yellow arrow), and from front to back (Z-axis, green arrow), thus defining the X–Z plane, where the sleep angle is calculated, and the Y–Z plane, where the stand angle is calculated. The sleep angle provides information about the sleep position and the rotation of the subject while sleeping. With this configuration, a sleep angle of 0 ◦ belongs to a pure left sleep position, 90 ◦ belongs to a pure supine position, ± 180 ◦ belongs to a pure right position, and − 90 ◦ belongs to a pure prone position. The stand angle provides information whether the subject is standing or lying in bed, and, with this configuration, a stand angle of ± 180 ◦ belongs to a stand position, 0 ◦ belongs to a headstand position, and 90 ◦ and − 90 ◦ belong to a pure laying position. The developed app allows visual validation of each sleep position orientation, to ensure that the smartphone is being used correctly, and is explained in the following section. 2.1.2. Software The software used to develop the Android application was ‘Android Studio’ (Google, Mountain View, United States), a free-to-use Android integrated development environment, under the Apache 2.0 license.
Sensors 2021,21, 4531 4 of 22 The Android application developed can be installed starting from Android Lollipop version (Android 5.0), which is expected to cover, at least, 94.1% of the Android smartphone devices on the market. This app has been developed with the experience and feedback provided by subjects from previous studies of our own group [38,54,55,58,59]. This application can run in background mode with the screen switched off. In its first use, the Android application checks that the necessary Android permissions to use the application are granted. It also reminds the user the need to disable battery optimization for this app, to avoid restrictions applied by the Android doze mode and allow the accelerometer sensor to continuously acquire data during the whole night. Then, it generates the folder structure to save the accelerometry data acquired and processed. The folder structure can be seen in Figure 2a. Once these aspects have been fulfilled, the app displays three tabs: ‘Acquisition’, ‘Recordings’, and ‘Results’. Sensors 2021, 21, x FOR PEER REVIEW 4 of 22 2.1.2. Software The software used to develop the Android application was ‘Android Studio’ (Google, Mountain View, United States), a free-to-use Android integrated development environment, under the Apache 2.0 license. The Android application developed can be installed starting from Android Lollipop version (Android 5.0), which is expected to cover, at least, 94.1% of the Android smartphone devices on the market. This app has been developed with the experience and feedback provided by subjects from previous studies of our own group [38,54,55,58,59]. This application can run in background mode with the screen switched off. In its first use, the Android application checks that the necessary Android permissions to use the application are granted. It also reminds the user the need to disable battery optimization for this app, to avoid restrictions applied by the Android doze mode and allow the accelerometer sensor to continuously acquire data during the whole night. Then, it generates the folder structure to save the accelerometry data acquired and processed. The folder structure can be seen in Figure 2a. Once these aspects have been fulfilled, the app displays three tabs: ‘Acquisition’, ‘Recordings’, and ‘Results’. Figure 2. Folder structure of the app (a) used to store the raw and processed information from the accelerometry sensor of the smartphone. Raw accelerometry is saved within the ‘Raw Acc Files’ folder. The ‘Recordings’ file contains the register of the multiple recordings performed. The ‘Results’ file contains the register with the summarized processed information from the accelerometry, and the ‘Low Res Acc’ folder contains the low sampling frequency accelerometry used for data visualization. The diagram in (b) shows the logic applied in the app to acquire and process the accelerometry data. 1. ‘Acquisition’ tab: this tab allows to start the sleep position acquisition by clicking the ‘Start’ button and stop it by clicking the ‘Stop’ button. Once the ‘Start’ button is clicked, a dialog prompts asking if you would like the smartphone to vibrate when sleeping in a supine-like sleep position, to force the user to change the sleep position. If vibration is selected, when sleeping in a supine-like sleep position, the smartphone will vibrate for 300 ms every 3 s. After the user’s decision upon the vibration option, accelerometry starts being sampled at a non-uniform sample rate of around 10 Hz. The acquired accelerometry data are saved in a separate file in the ‘Raw Acc Files’ Figure 2. Folder structure of the app ( a ) used to store the raw and processed information from the accelerometry sensor of the smartphone. Raw accelerometry is saved within the ‘Raw Acc Files’ folder. The ‘Recordings’ file contains the register of the multiple recordings performed. The ‘Results’ file contains the register with the summarized processed information from the accelerometry, and the ‘Low Res Acc’ folder contains the low sampling frequency accelerometry used for data visualization. The diagram in (b) shows the logic applied in the app to acquire and process the accelerometry data. 1. ‘Acquisition’ tab: this tab allows to start the sleep position acquisition by clicking the ‘Start’ button and stop it by clicking the ‘Stop’ button. Once the ‘Start’ button is clicked, a dialog prompts asking if you would like the smartphone to vibrate when sleeping in a supine-like sleep position, to force the user to change the sleep position. If vibration is selected, when sleeping in a supine-like sleep position, the smartphone will vibrate for 300 ms every 3 s. After the user’s decision upon the vibration option, accelerometry starts being sampled at a non-uniform sample rate of around 10 Hz. The acquired accelerometry data are saved in a separate file in the ‘Raw Acc Files’ folder seen in Figure 2a, and a new registry is entered in the ‘Recordings’ file. Then, it is simultaneously processed to extract information of interest and it is interpolated to a uniform sampling rate of 10 Hz. Afterwards, each sampled accelerometry value is median filtered, with a window of 60 s around each sample, to
Sensors 2021,21, 4531 5 of 22 remove the high frequency noise from the accelerometry. In addition, the sleep angle and stand angles are calculated and displayed on the polar plots from the tab using the following formula: Angle (o)=180 Π·acos → a· → b → a · → b ·sign(c) + θInitial (1) where, for the sleep angle, → a=(Xn,Zn) with Xn and Zn being the values of the X and Z axis of the triaxial accelerometry at each specific timestamp; → b=(1, 0) , which is a static reference aligned with the left sleep position; and c=Zn , to be able to differentiate supine and prone positions. For the stand angle, → a=(Yn,Zn) , with Yn and Zn being the values of the Y and Z axis of the triaxial accelerometry at each specific timestamp; → b=(1, 0) , which is a static reference aligned with the stand position; and c=Zn , to be able to differentiate stand and headstand positions. The θInitial is an angle used to correct the differences in anatomy between patients when placing the phone over the sternum. It is automatically determined from the sleep and stand angles when sleeping in a supine position during the first 10 min of acquisition [ 38 ]. It can be different for the sleep and stand angles and it is used to ensure that the smartphone returns 90 ◦ for both the sleep and stand angles when being in a pure supine position, which are the values expected for this position. The algorithm described in this section has successfully been tested and validated in a previous work of our group compared to the video-validated position from the PSG [38]. Then, the sleep angle is used to display the high-resolution sleep position in real time in the ‘Sleep Position’ polar plot, which shows the smartphone angular orientation between the four classic sleep positions (supine, left, right and prone). The stand angle can also be observed in real time to determine if the subject is laying on the bed or standing, by looking at the ‘Stand Position’ polar plot, which shows the angular orientation between the standing and laying positions. The acceleration values and time spent on the acquisition can also be seen in this Table Finally, accelerometry is down-sampled to 0.2 Hz and saved also in the ‘Low Res Acc’ folder for its visualization in the results Table Acquisitions shorter than 2 min are discarded. The logical scheme applied in this tab can be seen in Figure 2b. 2 ‘Recordings’ tab: this tab displays all the sleep position acquisitions performed. For each acquisition, the date, start time, and duration are shown. It is also possible to switch to a calendar view, where the number of acquisitions per day are shown. Finally, in this menu it is possible to observe whether the accelerometry file is still saved in the smartphone memory and it gives you the option to delete the file and/or the results linked to the acquisition. 3 ‘Results’ tab: this tab shows the sleep position results for each of the acquisitions, including the acquisition date, start time, and a summary of the discrete sleep position performance. When clicking on each of the sleep position summary boxes, a dialog box appears showing the details of the acquisition. The details of the sleep position include a polar plot showing the evolution in time of the sleep position as well as a summary table with the minutes and percentage of minutes spent at each sleep position. In the detailed polar plot, the standing position, if present, appears in blue, and the laying position in orange. The high-resolution sleep position orientation is also shown, allowing to determine the exact angular orientation at each specific time of the night.
Sensors 2021,21, 4531 6 of 22 2.2. ‘SleepPos’ App: Position Monitoring during the Night The acquisition protocol used for all the experiments in this study was approved by the ethics committee from the Hospital Clínic of Barcelona. We have tested the ‘SleepPos’ Android app in 17 subjects who volunteered to use it during a whole night in sleep position diagnosis mode. These volunteers were proposed by the Hospital Clínic of Barcelona, and some of them were suspected of having positional OSA. The database used for the analysis is composed of 11 men and 6 women, with an average age of 51 (24–83) and an average BMI of 27.7 (20–34). They were given a Samsung S5 SM-G900F Android 6.0.1 smartphone (Samsung, Seoul, South Korea) with the app installed on it, a wired pulse oximeter Nonin 8000s (Nonin, Plymouth, MN, USA), and the fixation system proposed shown in Figure 1a. From the app we obtained the angular-based high resolution sleep position, the percentage of time and minutes spent lying and standing, and the percentage of time and minutes spent for each discrete sleep position (supine, prone, left and right). We also processed the raw accelerometry files saved within the ‘Raw Acc Files’ folder (Figure 2a) with the MATLAB r2019b software (Mathworks Inc., Natick, MA, USA). We developed custom algorithms to calculate the mean angle ( X ) and standard deviation ( σX ) of each of the sleep angles within each discrete sleep position (supine, prone, left and right) to study the angular variation at each discrete sleep position and determine whether they were steady at a specific position or not. 2.3. ‘SleepPos’ App: Combination with Oximetry We used the acquisition protocol explained in the previous subsection to study the occurrence of desaturation events linked to the angular-based high resolution sleep position. The desaturation events are defined as the time intervals that the blood oxygen level has a drop of at least 3%, respect to the baseline prior to this drop, in a short period of time (maximum 120 s) due to disordered breathing [ 62 , 63 ]. To perform this study, we also developed custom-made algorithms with MATLAB r2019b. For each of the 17 subjects, we obtained the desaturation events provided by the pulse oximeter and calculated the percentage of time spent in a certain sleep position angle with the following formula: %Positionθ=100 · N ∑ i=1 Positioni[Anglelow θ≤Positioni≤Anglehigh θ] N(2) where %Positionθ provides the percentage of time spent in a certain sleep angle θ ;Nis the number of sleep position samples available; Positioni represents each sleep position sample matching the criteria between brackets; and the Anglelow θ and Anglehigh θ are the thresholds used around each sleep angle θ , forming a window of 15 ◦ ( θ± 7.5 ◦ ). The evaluated sleep angles θranged from −180◦to 180◦with 1◦increase. We also calculated, for each patient, the percentage of desaturation events (DE) at a certain sleep position angle. To achieve this, we took each desaturation event and assigned it the mean angle value of all the sleep position angle samples that occurred during the event. Afterwards, we calculated the percentage of events occurring at a certain angle with the following Equation: %DEθ=100 · N ∑ i=1 DEi[Anglelow θ≤DEi≤Anglehigh θ] N(3) where %DEθ is the percentage of events in a certain sleep angle θ ;Nis the number of desaturation events available; DEi represents the median angle linked to an event matching the criteria between brackets; and the Anglelow θ and Anglehigh θ are the thresholds used around each sleep angle θwith the same window and resolution as Equation (2). Finally, to determine the relationship between the occurrence of the desaturation events and the sleep position, two variables were calculated linked to their angle of
Sensors 2021,21, 4531 7 of 22 occurrence: the local oxygen desaturation index (ODI) and the ratio between the percentage of events and the percentage of position. The formulas used to calculate these two variables were the following: Local ODIθ= N ∑ i=1 DEi[Anglelow θ≤DEi≤Anglehigh θ] 1 36000 ·M ∑ j=1 Positionj[Anglelow θ≤Positionj≤Anglehigh θ] (4) Ratio-%DE/%Positionθ=%DEθ %Positionθ (5) where the Local ODIθ provides an estimation of the ODI in a certain sleep angle θ ;Nis the number of desaturation events available; DEi represents the median angle linked to an event matching the criteria between brackets; Anglelow θ and Anglehigh θ are the thresholds used around this angle with the same window and resolution as Equation (2); the coefficient 1 36,000 is used to normalize the position to hours, taking into account the sampling frequency of the smartphone (10 Hz); Mis the number of sleep position samples available; and Positioni represents each sleep position sample matching the criteria between brackets. The Ratio-%DE/%Positionθ provides information about the occurrence of events at a certain sleep angle θ ; and %DEθ and %Positionθ are the results from Equations (2) and (3) for each angle θ . To avoid high-value artifacts due to denominators being close to 0 in both the Local ODIθ and Ratio-%DE/%Positionθ variables, a minimum denominator value is used in both equations, which is 10 min for the Local ODIθ and 1% for the Ratio-%DE/%Positionθ . Moreover, the Local ODIθ is smoothed with the mean value calculated from the window containing the previous and following two values. 2.4. ‘SleepPos’ App: Positional Treatment To validate the efficacy of the vibration as a positional treatment strategy to avoid sleeping in the supine sleep position, nine subjects were tested some months later with the vibration option activated and compared to their previous sleep position recording without vibration. The vibration characteristics were described in the Section 2.1.2 “‘Acquisition’ tab” of this study. We used the same acquisition protocol explained for the previous subsection, with an EMO-80 wireless pulse oximeter (EMAY Ltd., Hong Kong, China), and determined the high-resolution sleep position and the desaturation events of at least 3%. To perform this study, we also developed custom-made algorithms with MATLAB r2019b. We have used the Equations (2)–(5) to determine the effect of the positional treatment in the appearance of desaturation events and to assess the ODI values of each subject linked to their sleep position angle. 3. Results 3.1. ‘SleepPos’ App: Design and Specifications Screenshots of the ‘SleepPos’ app are shown in Figure 3. The ‘Acquisition’ tab ( Figure 3a ) allows to start the acquisition of the sleep position. Once the ‘Start’ button is clicked, a window prompts (Figure 3b) asking if positional treatment should be applied. If the user selects positional treatment, the smartphone will vibrate for 300 ms every 3 s when sleeping in a supine like position, to induce the user to change the sleep position. An example of a real time representation of the sleep position and whether the subject is standing or not can be seen in Figure 3c. This allows to check if the smartphone has been placed correctly to monitor the sleep position during the night. The ‘Recordings’ tab (Figure 3d) shows the list of recordings performed with their acquisition date, hour of start and duration. The icon Sensors 2021, 21, x FOR PEER REVIEW 8 of 22 window prompts (Figure 3b) asking if positional treatment should be applied. If the user selects positional treatment, the smartphone will vibrate for 300 ms every 3 s when sleeping in a supine like position, to induce the user to change the sleep position. An example of a real time representation of the sleep position and whether the subject is standing or not can be seen in Figure 3c. This allows to check if the smartphone has been placed correctly to monitor the sleep position during the night. Figure 3. Screenshots of the ‘SleepPos’ app. The ‘Acquisition’ tab (a) is used to record the sleep position. Upon clicking the ‘Start’ button, a dialog is prompted (b) asking if positional treatment should be applied. Afterwards, the sleep position is acquired and displayed (c) on the polar plots as well as the accelerometry values and the time spent on the acquisition. The ‘Recordings’ tab (d) shows the details of each acquisition, which include the date, hour of start, and duration. The ‘Results’ tab (e) shows a summary of the sleep position for each acquisition. When clicking over each summary, a window prompts (f) showing the sleep position with angular resolution, as well as a table with the summarized details of the acquisition. The ‘Recordings’ tab (Figure 3d) shows the list of recordings performed with their acquisition date, hour of start and duration. The icon is used to provide the information that the raw accelerometry is still saved in the ‘Raw Acc Files’ folder, whereas the icon is used to provide the information that the raw accelerometry has been removed. The icon opens a window which let the users decide whether to remove the raw accelerometry file to reduce the smartphone’s memory used, or to remove this acquisition and its results from the app. Each acquisition is estimated to occupy at maximum 20 Mb. Finally, the ‘Results’ tab (Figure 3e) shows the outcomes of the sleep position performance for each acquisition. To easily identify the results the user wants to check, the date and hour of start are provided for each acquisition. When the user clicks over any of the summary boxes displayed for each acquisition, a window appears (Figure 3f) showing the is used to provide the information that the raw accelerometry is still saved in the ‘Raw Acc Files’ folder, whereas the Sensors 2021, 21, x FOR PEER REVIEW 8 of 22 window prompts (Figure 3b) asking if positional treatment should be applied. If the user selects positional treatment, the smartphone will vibrate for 300 ms every 3 s when sleeping in a supine like position, to induce the user to change the sleep position. An example of a real time representation of the sleep position and whether the subject is standing or not can be seen in Figure 3c. This allows to check if the smartphone has been placed correctly to monitor the sleep position during the night. Figure 3. Screenshots of the ‘SleepPos’ app. The ‘Acquisition’ tab (a) is used to record the sleep position. Upon clicking the ‘Start’ button, a dialog is prompted (b) asking if positional treatment should be applied. Afterwards, the sleep position is acquired and displayed (c) on the polar plots as well as the accelerometry values and the time spent on the acquisition. The ‘Recordings’ tab (d) shows the details of each acquisition, which include the date, hour of start, and duration. The ‘Results’ tab (e) shows a summary of the sleep position for each acquisition. When clicking over each summary, a window prompts (f) showing the sleep position with angular resolution, as well as a table with the summarized details of the acquisition. The ‘Recordings’ tab (Figure 3d) shows the list of recordings performed with their acquisition date, hour of start and duration. The icon is used to provide the information that the raw accelerometry is still saved in the ‘Raw Acc Files’ folder, whereas the icon is used to provide the information that the raw accelerometry has been removed. The icon opens a window which let the users decide whether to remove the raw accelerometry file to reduce the smartphone’s memory used, or to remove this acquisition and its results from the app. Each acquisition is estimated to occupy at maximum 20 Mb. Finally, the ‘Results’ tab (Figure 3e) shows the outcomes of the sleep position performance for each acquisition. To easily identify the results the user wants to check, the date and hour of start are provided for each acquisition. When the user clicks over any of the summary boxes displayed for each acquisition, a window appears (Figure 3f) showing the icon is used to provide the information that the raw accelerometry has been removed. The icon
Sensors 2021,21, 4531 8 of 22 Sensors 2021, 21, x FOR PEER REVIEW 8 of 22 window prompts (Figure 3b) asking if positional treatment should be applied. If the user selects positional treatment, the smartphone will vibrate for 300 ms every 3 s when sleeping in a supine like position, to induce the user to change the sleep position. An example of a real time representation of the sleep position and whether the subject is standing or not can be seen in Figure 3c. This allows to check if the smartphone has been placed correctly to monitor the sleep position during the night. Figure 3. Screenshots of the ‘SleepPos’ app. The ‘Acquisition’ tab (a) is used to record the sleep position. Upon clicking the ‘Start’ button, a dialog is prompted (b) asking if positional treatment should be applied. Afterwards, the sleep position is acquired and displayed (c) on the polar plots as well as the accelerometry values and the time spent on the acquisition. The ‘Recordings’ tab (d) shows the details of each acquisition, which include the date, hour of start, and duration. The ‘Results’ tab (e) shows a summary of the sleep position for each acquisition. When clicking over each summary, a window prompts (f) showing the sleep position with angular resolution, as well as a table with the summarized details of the acquisition. The ‘Recordings’ tab (Figure 3d) shows the list of recordings performed with their acquisition date, hour of start and duration. The icon is used to provide the information that the raw accelerometry is still saved in the ‘Raw Acc Files’ folder, whereas the icon is used to provide the information that the raw accelerometry has been removed. The icon opens a window which let the users decide whether to remove the raw accelerometry file to reduce the smartphone’s memory used, or to remove this acquisition and its results from the app. Each acquisition is estimated to occupy at maximum 20 Mb. Finally, the ‘Results’ tab (Figure 3e) shows the outcomes of the sleep position performance for each acquisition. To easily identify the results the user wants to check, the date and hour of start are provided for each acquisition. When the user clicks over any of the summary boxes displayed for each acquisition, a window appears (Figure 3f) showing the opens a window which let the users decide whether to remove the raw accelerometry file to reduce the smartphone’s memory used, or to remove this acquisition and its results from the app. Each acquisition is estimated to occupy at maximum 20 Mb. Sensors 2021, 21, x FOR PEER REVIEW 8 of 22 window prompts (Figure 3b) asking if positional treatment should be applied. If the user selects positional treatment, the smartphone will vibrate for 300 ms every 3 s when sleeping in a supine like position, to induce the user to change the sleep position. An example of a real time representation of the sleep position and whether the subject is standing or not can be seen in Figure 3c. This allows to check if the smartphone has been placed correctly to monitor the sleep position during the night. Figure 3. Screenshots of the ‘SleepPos’ app. The ‘Acquisition’ tab (a) is used to record the sleep position. Upon clicking the ‘Start’ button, a dialog is prompted (b) asking if positional treatment should be applied. Afterwards, the sleep position is acquired and displayed (c) on the polar plots as well as the accelerometry values and the time spent on the acquisition. The ‘Recordings’ tab (d) shows the details of each acquisition, which include the date, hour of start, and duration. The ‘Results’ tab (e) shows a summary of the sleep position for each acquisition. When clicking over each summary, a window prompts (f) showing the sleep position with angular resolution, as well as a table with the summarized details of the acquisition. The ‘Recordings’ tab (Figure 3d) shows the list of recordings performed with their acquisition date, hour of start and duration. The icon is used to provide the information that the raw accelerometry is still saved in the ‘Raw Acc Files’ folder, whereas the icon is used to provide the information that the raw accelerometry has been removed. The icon opens a window which let the users decide whether to remove the raw accelerometry file to reduce the smartphone’s memory used, or to remove this acquisition and its results from the app. Each acquisition is estimated to occupy at maximum 20 Mb. Finally, the ‘Results’ tab (Figure 3e) shows the outcomes of the sleep position performance for each acquisition. To easily identify the results the user wants to check, the date and hour of start are provided for each acquisition. When the user clicks over any of the summary boxes displayed for each acquisition, a window appears (Figure 3f) showing the Figure 3. Screenshots of the ‘SleepPos’ app. The ‘Acquisition’ tab ( a ) is used to record the sleep position. Upon clicking the ‘Start’ button, a dialog is prompted ( b ) asking if positional treatment should be applied. Afterwards, the sleep position is acquired and displayed ( c ) on the polar plots as well as the accelerometry values and the time spent on the acquisition. The ‘Recordings’ tab ( d ) shows the details of each acquisition, which include the date, hour of start, and duration. The ‘Results’ tab ( e ) shows a summary of the sleep position for each acquisition. When clicking over each summary, a window prompts ( f ) showing the sleep position with angular resolution, as well as a table with the summarized details of the acquisition. Finally, the ‘Results’ tab (Figure 3e) shows the outcomes of the sleep position performance for each acquisition. To easily identify the results the user wants to check, the date and hour of start are provided for each acquisition. When the user clicks over any of the summary boxes displayed for each acquisition, a window appears (Figure 3f) showing the sleep position with angular resolution, as well as a summary table with the minutes and percentage of time spent in each sleep position. It also displays the minutes and percentage of time spent lying or standing. 3.2. ‘SleepPos’ App: Position Monitoring during the Night Figure 4shows the sleep position results for subjects 2 (Figure 4a), 6 (Figure 4b) and 16 (Figure 4c). For each subject, we can observe the angular-based high resolution sleep position, as well as the summary of the discrete sleep position performance. We can see how subject 2 was lying in bed for 266.6 min (~4 h 30 m) and spent 11% of this time in a left sleep position, 55.5% in a supine sleep position and 33.6% in a right sleep position.
Sensors 2021,21, 4531 9 of 22 Subject 6 spent 311.3 min (~5 h 10 m) lying in bed and spent 19.1% of this time in a left sleep position, 29.1 in a supine sleep position, 15.1% in a right sleep position and 36.8% in a prone sleep position. Finally, subject 16 spent 469.0 min (~7 h 45 m) lying in bed and spent 27.2% of this time in a left sleep position, 37.9% in a supine sleep position and 34.9% in a right sleep position. It is noticeable how subject 2 spent most of the time (>50%) in a supine sleep position compared to subjects 6 and 16. Additionally, subject 6 spent 36.8% of the time (~2 h) sleeping in a prone sleep position, which was its preferred sleep position compared to the time spent in the lateral positions (106.3 min, 34.2% of the time) or in the supine position (90.6 min, 29.1% of the time). Finally, the angular-based high-resolution sleep position reveals how subject 16 has a lot of position shifts when compared to subjects 2 and 6. It also reveals the existence of angular differences within the supine sleep position and within the right sleep position in subject 2. These angular differences within the same sleep position can also be seen in subject 6 and 16. This indicates how a high-resolution sleep position would be needed to better determine the sleep position and the movement of the subject when sleeping. Sensors 2021, 21, x FOR PEER REVIEW 9 of 22 sleep position with angular resolution, as well as a summary table with the minutes and percentage of time spent in each sleep position. It also displays the minutes and percentage of time spent lying or standing. 3.2. ‘SleepPos’ App: Position Monitoring during the Night Figure 4 shows the sleep position results for subjects 2 (Figure 4a), 6 (Figure 4b) and 16 (Figure 4c). For each subject, we can observe the angular-based high resolution sleep position, as well as the summary of the discrete sleep position performance. We can see how subject 2 was lying in bed for 266.6 min (~4 h 30 m) and spent 11% of this time in a left sleep position, 55.5% in a supine sleep position and 33.6% in a right sleep position. Subject 6 spent 311.3 min (~5 h 10 m) lying in bed and spent 19.1% of this time in a left sleep position, 29.1 in a supine sleep position, 15.1% in a right sleep position and 36.8% in a prone sleep position. Finally, subject 16 spent 469.0 min (~7 h 45 m) lying in bed and spent 27.2% of this time in a left sleep position, 37.9% in a supine sleep position and 34.9% in a right sleep position. It is noticeable how subject 2 spent most of the time (>50%) in a supine sleep position compared to subjects 6 and 16. Additionally, subject 6 spent 36.8% of the time (~2 h) sleeping in a prone sleep position, which was its preferred sleep position compared to the time spent in the lateral positions (106.3 min, 34.2% of the time) or in the supine position (90.6 min, 29.1% of the time). Finally, the angular-based high-resolution sleep position reveals how subject 16 has a lot of position shifts when compared to subjects 2 and 6. It also reveals the existence of angular differences within the supine sleep position and within the right sleep position in subject 2. These angular differences within the same sleep position can also be seen in subject 6 and 16. This indicates how a high-resolution sleep position would be needed to better determine the sleep position and the movement of the subject when sleeping. Figure 4. Screenshots of the ‘SleepPos’ app results for subject 2 (a), 6 (b) and 16 (c). For each subject, the angular sleep position is provided, as well as the summary of results for each sleep position. It is possible to observe how subject 2 (a) and 6 (b) have few position changes, whereas the subject 16 (c) has a lot of position changes. This behavior is only noticeable on the angular-based high-resolution sleep position as it is not possible to be seen in the summary table. Table 1 shows the summary of the discrete sleep position performance for all the subjects included in this study. The minutes and percentage of time spent lying or standing, and at each of the sleep positions were obtained from the ‘SleepPos’ app. From the Figure 4. Screenshots of the ‘SleepPos’ app results for subject 2 ( a ), 6 ( b ) and 16 ( c ). For each subject, the angular sleep position is provided, as well as the summary of results for each sleep position. It is possible to observe how subject 2 ( a ) and 6 ( b ) have few position changes, whereas the subject 16 ( c ) has a lot of position changes. This behavior is only noticeable on the angular-based high-resolution sleep position as it is not possible to be seen in the summary table. Table 1shows the summary of the discrete sleep position performance for all the subjects included in this study. The minutes and percentage of time spent lying or standing, and at each of the sleep positions were obtained from the ‘SleepPos’ app. From the raw accelerometry files provided by the ‘SleepPos’ app, we also calculated the mean and standard deviation of the angles obtained for each sleep position and patient. When observing the table, we can determine that the supine sleep position was only the preferred option for 9 of the 17 subjects, and only 3 of these subjects (10, 12 and 13) spent more than 60% of the time at that specific sleep position. It is also noticeable how only 3 subjects (1, 6 and 14) slept occasionally in a prone-like sleep position. Subjects 6 and 14 spent a reasonable amount of time in the prone position, but subject 1 spent only 2.3 min, which is likely that the time spent on that sleep position was part of a transition between right and left sleep positions through the prone sleep position.
Sensors 2021,21, 4531 16 of 22 positions [ 46 – 48 ], the results obtained can be reliably interpretated as a proof-of-concept confirming the feasibility of the app to conduct positional therapy. Regarding the positional treatment efficacy, it is remarkable to see how subject 10 changed from spending 95.2% of the time in the supine position to only 3.2% of the time when being treated. The same good results were obtained in all the subjects who underwent positional treatment. This demonstrates the efficacy of the vibration in avoiding certain sleep positions, and that the pattern of vibration used was satisfactory in achieving its purpose. All the subjects who underwent positional treatment reported that the vibration pattern used was noticeable, but not annoying, while being awake and in supine position. Once having fallen asleep, none of the subjects reported to be neither awaken nor annoyed by the vibration applied as positional treatment, which is important to avoid poor sleep. In addition, the subjects reported having a comfortable sleep of good quality. Nevertheless, quantitative relation between the sleep quality and the application of positional treatment was not assessed, as no objective measures of sleep quality, such as electroencephalography (EEG), were available. Nevertheless, knowing that the vibrational devices achieve the same results as other passive techniques, such as the TBT, but with improved sleep quality, quality of life, and compliance [ 49 ], the ‘SleepPos’ app proposed in this study could be a feasible solution to be considered as a sleep position trainer. This reveals the need to monitor sleep positions with a higher resolution, and the necessity to use less obtrusive techniques which allow the monitoring of sleep positions at the usual sleeping environment, which is at home. 4.2. Sleep Position and Oximetry The measurement of oxygen saturation is a widely used technique in medicine nowadays. It has been proved that hypoxia can lead to multiple health complications, increasing the risk to suffer from multiple cerebrovascular and cardiovascular diseases [ 8 – 10 ]. There have been multiple studies which revealed how the position can influence the appearance of these hypoxic events [ 20 , 21 ], indicating that position can play an important role. In this study we have explored how the combination of the ‘SleepPos’ app with a medical-grade pulse oximeter could provide relevant information on the number of desaturation events and their occurrence linked to the sleep position. An important indicator to measure the relevance of the occurrence of desaturation events is the ODI. This index normalizes the number of desaturations by the total amount of time of the acquisition performed and allows to better compare the occurrence of events between subjects. There were four healthy subjects, three mild subjects, eight moderate subjects and two severe subjects in the database according to their ODI value [ 64 ], even though multiple subjects had their ODI values close to the threshold values between the four different severity categories. It is important to remark that the ODI could underestimate the severity provided by the AHI, as apneas could occur without the presence of a desaturation event and hypopneas could also be detected linked to an arousal. This situation could significate that the subjects might be more severe in terms of apneas and hypopneas than the ODI severity values reported. Nevertheless, the ODI can usually be used as a good estimator of the sleep apnea severity [ 64 ] and can provide clinically relevant information to clinicians. We used the ODI instead of the AHI, as we used a simplified system that only used a pulse oximeter and a smartphone. Although the ODI is a good metric to determine the severity of the occurrence of desaturation events, it provides a summary of the information of the whole night and does not account for the variability introduced by other factors. For instance, it is known that position plays an important role on the occurrence of apneic events [ 20 , 21 ], which are usually accompanied by hypoxia. In this scenario, the combination of the information on the sleep position obtained from the ‘SleepPos’ app allowed linkage of the occurrence of the desaturation events to its sleep position angle of occurrence. This combination revealed very useful clinical information about the subjects of the database in two different
Sensors 2021,21, 4531 17 of 22 variables: the local ODI and the ratio of the percentage of events versus the percentage of time spent at a specific sleep position angle. These variables allowed us to assess two important aspects: the severity according to the number of desaturations found and the positional behavior. The severity is evaluated by the local ODI and indicates how critical is the situation regarding to the occurrence of hypoxic events, and the positional behavior is assessed by the ratio and indicates if there is a sleep position where these hypoxic events are more prevalent. When looking at Figure 5, we can observe various subjects with different severities and positional behaviors. Subjects 1 and 4 are cases whose severity varies significantly depending on the sleep position. Both have a severe ODI value at the supine sleep position and a healthy to mild behavior in the lateral sleep positions. It is worth mentioning that subject 4 has an ODI value of around 70 h −1 in the supine sleep position, whereas in the right sleep position this value drops significantly to values below 20 h −1 . This can easily be seen in Figure 5c, where their ratio values are between 2 and 3, indicating that more than double of the desaturation events occurred when compared to the percentage of time spent at that specific sleep position. On the contrary, subject 11 would be a clear case of a severe subject without positional differences. It is possible to observe in Figure 5c how this ratio does not vary between the supine and the lateral sleep positions, and Figure 5d reveals that the ODI is around 40 h −1 in all these sleep positions. Subjects 5 and 6 would be a clear case of healthy patients (Figure 5d) with a positional behavior (Figure 5c) since they did around three times more events in the supine sleep position than in the lateral sleep position. However, it is important to notice that these subjects did very few events since they are classified as healthy, and thus the ratio between the percentage of desaturation events and the percentage of sleep position could be overestimated due to this low number of events. Moreover, there are subjects in which the positional behavior variable cannot be assessed. The reason is that they do not significantly change their sleep position, and it is not possible to detect differences between sleep positions. An example of this case would be subject 12, who sleeps mostly in a supine sleep position, and even though his ODI is very high (around 100 h −1 ), it is not possible to determine if it is increased due to the supine sleep position and if it would be reduced in lateral positions. After treating some of the subjects of this study with positional treatment provided by the ‘SleepPos’ app, it was reported how the positional occurrence of desaturation events varied. After positional treatment, it is remarkable how subjects 4 and 7 lowered their ODI value from 25.7 to 12.6 and from 26.2 to 6.9. If we compare the behavior of these subjects before and after applying positional treatment we can observe that, by preventing the supine sleep position, most of the events disappeared. Subject 4 still presents a positional behavior around the sleep angles close to the threshold value used between the supine and right sleep positions, as it can be seen in Figures 5c and 6c, but the severity of the local ODI value has varied. When observing the differences in the local ODI values from Figures 5d and 6d we can observe how this subject changed from a value around 70 to a value around 40 in the sleep angle values close to the edge between the supine and right sleep positions. This indicates that this subject could benefit even more of this reduction if the positional treatment therapy were more restrictive regarding which sleep positions should be avoided. Similar good results can also be seen in subject 1, who also lowered the ODI value. In this case, it is possible to observe that when applying positional treatment multiple events appear close to the supine position, which might indicate that there could still exist some positional behavior, and that a more restrictive positional treatment could lower even more the ODI value. On the other hand, subject 2 appears to have slightly increased the ODI value even after positional therapy. This reveals that this subject might not benefit from positional therapy. Even though this subject increased its ODI value, it is also noticeable that the sleep position of this subject was always close to the supine sleep position, which could also be a reason for the increased appearance of desaturation events. More tests
Sensors 2021,21, 4531 18 of 22 would be needed to better determine if there could exist a positional behavior on this subject. Most of the subjects treated remained with the same severity classification and similar ODI values. These subjects were mostly healthy and mild, and this would indicate that they would not benefit from the positional therapy. These results suggest that the information obtained by the combination of the ‘Sleep- Pos’ app and the pulse oximeter can provide useful clinical information, and that a highresolution sleep position is needed to better assess the influence of the sleep position in the appearance of desaturation events. 4.3. Smartphones and Their Role as Portable mHealth Tools Over the last few years, telemedicine has appeared as a promising field for improving the quality of the health system and reducing the associated costs [ 66 ]. However, there are multiple technical aspects to be considered and research is still needed in how to better apply it [ 67 ]. Derived from telemedicine, mobile health (mHealth) is an interesting solution to provide high quality medical assistance. The use of mobile devices, such as smartphones or tablets, has opened a broad field of study in developing multiple tools for health data acquisitions at home, due to their advantages. Smartphones, which are devices available worldwide, have a lot of sensors which can be used to monitor different health parameters. These sensors can either be embedded or external portable devices, known as wearables. In our study we developed an Android app, named ‘SleepPos’, which monitors the sleep position with high resolution and allows to perform positional treatment. The monitoring of high-resolution sleep position is important to better determine the occurrence and severity of pOSA [ 37 , 38 ] and could be of high relevance for other diseases. We also studied how this app could be used in combination with a pulse oximeter, to determine the positional occurrence of desaturation events and their severity. Because the availability of portable pulse oximeters is high, the combination of these two devices can be used to assess the sleep quality by means of sleep position and occurrence of sleep events in an easy and affordable manner, providing high relevant clinical information. For our approach, the smartphone has to be placed over the sternum in a configuration already tested in several studies [ 53 , 55 , 59 ]. To hold the device in position, a fixation system is also needed. We proposed the use of an elastic band, as seen in Figure 1a, which was reported by the subjects who tested it as a comfortable system to hold the smartphone in position while sleeping. When using smartphones, several aspects should be considered, such as the electromagnetic radiation and the heat that they might produce, as well as the size of the device and their comfort when placed in position. For our study, we configured the smartphones in airplane mode and disabled Wi-Fi and Bluetooth. By adopting these measures, we reduced or removed the risk of harm produced by the possible emissions and heat generated by the smartphone. Regarding the size of the device, the smartphone used measured 142 ×72.5 ×8.1 mm , and neither any issues related to the comfort of the system, nor issues related to problems regarding the radiation or heat emission were reported by any of the subjects of the database. The same positive feedback was obtained regarding the comfort of the pulse oximeters used for this study. It is important to underline that the system proposed in our research is of a smaller size and weight than multiple portable devices for home polygraphy, and we expected the comfort to be, at least, the same. Another important aspect to consider when using smartphones is the battery capacity and the maximum duration of the acquisitions. The smartphones used in this study contained a battery of 2800 mAh, and each acquisition of around 7 h reduced the battery by approximately 30%. This power consumption ensures that the smartphone can run for approximately 24 h straight, which would allow it to perform at least three acquisitions without having to charge the phone. Finally, the design of the ‘SleepPos’ Android app allows retrieval of high resolution sleep positions, and its use combined with a pulse oximeter can provide relevant clinical information for pOSA detection. To sum up, the novel results presented in this study
Sensors 2021,21, 4531 19 of 22 reinforce the idea that smartphones are promising mHealth tools to be used at home providing relevant information for sleep medicine. 5. Conclusions In our study we developed an Android application, named ‘SleepPos’, which allows to monitor high-resolution sleep position and apply positional treatment by vibration. We combined this app with a pulse oximeter, and we were able to determine the occurrence of desaturation events linked to the sleep position. This allowed us to validate that positional therapy applied with a smartphone helped reducing the supine position and improve the ODI severity. We revealed how a high-resolution sleep position is necessary to better assess the patient position and the occurrence of desaturation events. The novel results presented in this study suggest that smartphones are promising mHealth tools that can provide clinically relevant information by monitoring sleep position and its relationship with sleep disorders at home. 6. Patents The Android application designed in this study and the algorithms used are under a process to recognize the industrial property. Author Contributions: Conceptualization, I.F.-L., Y.C.-E., J.M.M. and R.J.; methodology, I.F.-L., Y.C.- E., J.M.M. and R.J.; software, I.F.-L.; validation, I.F.-L., Y.C.-E., J.M.M. and R.J.; formal analysis, I.F.-L., Y.C.-E., J.M.M. and R.J.; investigation, I.F.-L., Y.C.-E., J.M.M. and R.J.; resources, I.F.-L., Y.C.-E., J.M.M. and R.J.; data curation, I.F.-L., Y.C.-E., J.M.M. and R.J.; writing—original draft preparation, I.F.-L.; writing—review and editing, I.F.-L., Y.C.-E., J.M.M. and R.J.; visualization, I.F.-L., Y.C.-E., J.M.M. and R.J.; supervision, R.J. and J.M.M.; project administration, I.F.-L., Y.C.-E., J.M.M. and R.J.; funding acquisition, I.F.-L., Y.C.-E., J.M.M. and R.J. All authors have read and agreed to the published version of the manuscript. Funding: This work was supported in part by the “La Caixa” Foundation (ID 100010434) under fellowship codes LCF/BQ/DI17/11620029 and LCF/BQ/DE18/11670019; in part by the European Union’s Horizon 2020 Research and Innovation Program under the Marie Sklodowska-Curie Grant number 713673; in part by the CERCA Program/Generalitat de Catalunya, in part by the Secretaria d’Universitats i Recerca de la Generalitat de Catalunya under grant GRC 2017 SGR 01770; in part by the Spanish Ministry of Science, Innovation and Universities under grant RTI2018-098472-B-I00 MCIU/AEI/FEDER, UE; and in part by the Instituto de Salud Carlos III under grant FIS PI17/01068. Institutional Review Board Statement: The study was conducted according to the guidelines of the Declaration of Helsinki, and approved by the Ethics Committee of Hospital Clínic de Barcelona (protocol code HCB/2017/0106 from 27 February 2017). Informed Consent Statement: Informed consent was obtained from all subjects involved in the study and written informed consent has been obtained from the patients to publish this paper. Acknowledgments: We thank the patients who accepted to participate in this study as well as all the technicians from the Hospial Clínic who helped us in the management to acquire this database. Conflicts of Interest: The authors declare no conflict of interest. References 1. Lee, K.A. An overview of sleep and common sleep problems. ANNA J. 1997,24, 614–623. 2. Aminoff, M.J.; Boller, F.; Swaab, D.F. We spend about one-third of our life either sleeping or attempting to do so. Handb. Clin. Neurol. 2011,98, vii. [CrossRef] 3. Koo, D.L.; Kim, J. The Physiology of Normal Sleep. Hanyang Med. Rev. 2013,33, 190. [CrossRef] 4. Hirshkowitz, M.; Whiton, K.; Albert, S.M.; Alessi, C.; Bruni, O.; DonCarlos, L.; Hazen, N.; Herman, J.; Katz, E.S.; Kheirandish-Gozal, L.; et al. National Sleep Foundation’s sleep time duration recommendations: Methodology and results summary. Sleep Health 2015,1, 40–43. [CrossRef] 5. Bishop, T.M.; Walsh, P.G.; Ashrafioun, L.; Lavigne, J.E.; Pigeon, W.R. Sleep, suicide behaviors, and the protective role of sleep medicine. Sleep Med. 2020,66, 264–270. [CrossRef]
Sensors 2021,21, 4531 20 of 22 6. Stowkowy, J.; Brummitt, K.; Bonneville, D.; Goldstein, B.I.; Wang, J.; Kennedy, S.H.; Bray, S.; Lebel, C.; MacQueen, G.; Addington, J. Sleep disturbances in youth at-risk for serious mental illness. Early Interv. Psychiatry 2020,14, 373–378. [CrossRef] [PubMed] 7. Augner, C. Associations of Subjective Sleep Quality with Depression Score, Anxiety, Physical Symptoms and Sleep Onset Latency in Young Students. Cent. Eur. J. Public Health 2011,19, 115–117. [CrossRef] [PubMed] 8. Bartlett, D.J.; Marshall, N.S.; Williams, A.; Grunstein, R.R. Sleep health New South Wales: Chronic sleep restriction and daytime sleepiness. Intern. Med. J. 2007. [CrossRef] 9. Yoshihisa, A.; Takeishi, Y. Sleep Disordered Breathing and Cardiovascular Diseases. J. Atheroscler. Thromb. 2019 ,26, 315–327. [CrossRef] [PubMed] 10. Durgan, D.J.; Bryan, R.M. Cerebrovascular Consequences of Obstructive Sleep Apnea. J. Am. Heart Assoc. 2012,1. [CrossRef] 11. Ahmad, F.B.; Anderson, R.N. The Leading Causes of Death in the US for 2020. JAMA 2021,325, 1829. [CrossRef] 12. Organization World Health. The Top 10 Causes of Death. Available online: https://www.who.int/news-room/fact-sheets/ detail/the-top-10-causes-of-death (accessed on 15 May 2021). 13. Kaplowitz, K.; Blizzard, S.; Blizzard, D.J.; Nwogu, E.; Hamill, C.E.; Weinreb, R.N.; Mohsenin, V.; Loewen, N.A. Time Spent in Lateral Sleep Position and Asymmetry in Glaucoma. Investig. Opthalmol. Vis. Sci. 2015,56, 3869. [CrossRef] 14. Alevi, D.; Perry, H.D.; Wedel, A.; Rosenberg, E.; Alevi, L.; Donnenfeld, E.D. Effect of Sleep Position on the Ocular Surface. Cornea 2017,36, 567–571. [CrossRef] [PubMed] 15. Kaplowitz, K.; Dredge, J.; Honkanen, R. Relationship between sleep position and glaucoma progression. Curr. Opin. Ophthalmol. 2019,30, 484–490. [CrossRef] 16. Kerr, M.G.; Scott, D.B.; Samuel, E. Studies of the Inferior Vena Cava in Late Pregnancy. Br. Med. J. 1964 ,1, 522-4, 532–533. [CrossRef] 17. Jeffreys, R.; Stepanchak, W.; Lopez, B.; Hardis, J.; Clapp, J. Uterine blood flow during supine rest and exercise after 28 weeks of gestation. BJOG Int. J. Obstet. Gynaecol. 2006,113, 1239–1247. [CrossRef] [PubMed] 18. Warland, J.; Dorrian, J.; Morrison, J.L.; O’Brien, L.M. Maternal sleep during pregnancy and poor fetal outcomes: A scoping review of the literature with meta-analysis. Sleep Med. Rev. 2018,41, 197–219. [CrossRef] [PubMed] 19. Robertson, N.T.; Turner, J.M.; Kumar, S. Pathophysiological changes associated with sleep disordered breathing and supine sleep position in pregnancy. Sleep Med. Rev. 2019,46, 1–8. [CrossRef] 20. Oksenberg, A.; Arons, E.; Radwan, H.; Silverberg, D.S. Positional vs Nonpositional Obstructive Sleep Apnea Patients. Chest 1997 , 112, 629–639. [CrossRef] 21. Yalciner, G.; Babademez, M.A.; Gul, F. Association of sleep time in supine position with apnea-hypopnea index as evidenced by successive polysomnography. Sleep Breath. 2017,21, 289–294. [CrossRef] 22. Eckert, D.J.; Malhotra, A. Pathophysiology of Adult Obstructive Sleep Apnea. Proc. Am. Thorac. Soc. 2008 ,5, 144–153. [CrossRef] 23. Patil, S.P.; Schneider, H.; Schwartz, A.R.; Smith, P.L. Adult Obstructive Sleep Apnea. Chest 2007,132, 325–337. [CrossRef] 24. Osman, A.M.; Carter, S.G.; Carberry, J.C.; Eckert, D.J. Obstructive sleep apnea: Current perspectives. Nat. Sci. Sleep 2018 ,10, 21–34. [CrossRef] 25. Rundo, J.V. Obstructive sleep apnea basics. Cleve. Clin. J. Med. 2019,86, 2–9. [CrossRef] [PubMed] 26. Chung, F.; Yegneswaran, B.; Liao, P.; Chung, S.A.; Vairavanathan, S.; Islam, S.; Khajehdehi, A.; Shapiro, C.M. STOP Questionnaire. Anesthesiology 2008,108, 812–821. [CrossRef] 27. Netzer, N.C.; Stoohs, R.A.; Netzer, C.M.; Clark, K.; Strohl, K.P. Using the Berlin Questionnaire To Identify Patients at Risk for the Sleep Apnea Syndrome. Ann. Intern. Med. 1999,131, 485. [CrossRef] [PubMed] 28. Lomeli, H.A.; Pérez-Olmos, I.; Talero-Gutiérrez, C.; Moreno, C.B.; González-Reyes, R.; Palacios, L.; de la Peña, F.; Muñoz-Delgado, J. Sleep evaluation scales and questionaries: A review. Actas Esp. Psiquiatr. 2008,36, 50–59. 29. Russo, K.; Bianchi, M.T. How Reliable Is Self-Reported Body Position during Sleep? J. Clin. Sleep Med. 2016 ,12, 127–128. [CrossRef] [PubMed] 30. Warland, J.; Dorrian, J. Accuracy of Self-Reported Sleep Position in Late Pregnancy. PLoS ONE 2014 ,9, e115760. [CrossRef] [PubMed] 31. Kai-Ching Yu, C. Why is Self-Report of Sleep Position Sometimes Unreliable? Sleep Hypn. Int. J. 2017. [CrossRef] 32. Vonk, P.E.; de Vries, N.; Ravesloot, M.J.L. Polysomnography and sleep position, a Heisenberg phenomenon? HNO 2019 ,67, 679–684. [CrossRef] 33. Metersky, M.L.; Castriotta, R.J. The Effect of Polysomnography on Sleep Position: Possible Implications on the Diagnosis of Positional Obstructive Sleep Apnea. Respiration 1996,63, 283–287. [CrossRef] 34. Wang, Y.-K.; Chen, H.-Y.; Chen, J.-R. Unobtrusive Sleep Monitoring Using Movement Activity by Video Analysis. Electronics 2019 , 8, 812. [CrossRef] 35. Cary, D.; Collinson, R.; Sterling, M.; Briffa, K. Examining the Relationship between Sleep Posture and Morning Spinal Symptoms in the Habitual Environment Using Infrared Cameras. J. Sleep Disord. Treat. Care 2016,5. [CrossRef] 36. Akbarian, S.; Delfi, G.; Zhu, K.; Yadollahi, A.; Taati, B. Automated Non-Contact Detection of Head and Body Positions During Sleep. IEEE Access 2019,7, 72826–72834. [CrossRef] 37. Tate, A.; Walsh, J.; Kurup, V.; Shenoy, B.; Mann, D.; Freakley, C.; Eastwood, P.; Terrill, P. An emerging technology for the identification and characterization of postural-dependent obstructive sleep apnea. J. Clin. Sleep Med. 2020 ,16, 309–318. [CrossRef] [PubMed]
Sensors 2021,21, 4531 21 of 22 38. Ferrer-Lluis, I.; Castillo-Escario, Y.; Montserrat, J.M.; Jané, R. Enhanced Monitoring of Sleep Position in Sleep Apnea Patients: Smartphone Triaxial Accelerometry Compared with Video-Validated Position from Polysomnography. Sensors 2021 ,21, 3689. [CrossRef] 39. Xia, F.; Sawan, M. Clinical and Research Solutions to Manage Obstructive Sleep Apnea: A Review. Sensors 2021 ,21, 1784. [CrossRef] 40. Bloomfield, R.; Noble, D.W.; Sudlow, A. Prone position for acute respiratory failure in adults. Cochrane Database Syst. Rev. 2015 . [CrossRef] 41. Gattinoni, L.; Busana, M.; Giosa, L.; Macrì, M.; Quintel, M. Prone Positioning in Acute Respiratory Distress Syndrome. Semin. Respir. Crit. Care Med. 2019,40, 094–100. [CrossRef] 42. Epstein, L.J.; Kristo, D.; Strollo, P.J.; Friedman, N.; Malhotra, A.; Patil, S.P.; Ramar, K.; Rogers, R.; Schwab, R.J.; Weaver, E.M.; et al. Clinical guideline for the evaluation, management and long-term care of obstructive sleep apnea in adults. J. Clin. Sleep Med. 2009,5, 263–276. 43. Ravesloot, M.J.L.; van Maanen, J.P.; Dun, L.; de Vries, N. The undervalued potential of positional therapy in position-dependent snoring and obstructive sleep apnea—a review of the literature. Sleep Breath. 2013,17, 39–49. [CrossRef] 44. Oksenberg, A.; Silverberg, D.; Offenbach, D.; Arons, E. Positional Therapy for Obstructive Sleep Apnea Patients: A 6-Month Follow-Up Study. Laryngoscope 2006,116, 1995–2000. [CrossRef] [PubMed] 45. Skinner, M.A.; Kingshott, R.N.; Filsell, S.; Taylor, D.R. Efficacy of the “tennis ball technique” versus nCPAP in the management of position-dependent obstructive sleep apnoea syndrome. Respirology 2008,13, 708–715. [CrossRef] 46. van Maanen, J.P.; Richard, W.; Van Kesteren, E.R.; Ravesloot, M.J.L.; Laman, D.M.; Hilgevoord, A.A.J.; de Vries, N. Evaluation of a new simple treatment for positional sleep apnoea patients. J. Sleep Res. 2012,21, 322–329. [CrossRef] 47. Laub, R.R.; Tønnesen, P.; Jennum, P.J. A Sleep Position Trainer for positional sleep apnea: A randomized, controlled trial. J. Sleep Res. 2017,26, 641–650. [CrossRef] [PubMed] 48. Heinzer, R. ‘Good vibrations’: Positional treatments for obstructive sleep apnoea. Thorax 2020,75, 296. [CrossRef] [PubMed] 49. Eijsvogel, M.M.; Ubbink, R.; Dekker, J.; Oppersma, E.; de Jongh, F.H.; van der Palen, J.; Brusse-Keizer, M.G. Sleep Position Trainer versus Tennis Ball Technique in Positional Obstructive Sleep Apnea Syndrome. J. Clin. Sleep Med. 2015,11, 139–147. [CrossRef] 50. Bignold, J.J.; Deans-Costi, G.; Goldsworthy, M.R.; Robertson, C.A.; McEvoy, D.; Catcheside, P.G.; Mercer, J.D. Poor long-term patient compliance with the tennis ball technique for treating positional obstructive sleep apnea. J. Clin. Sleep Med. 2009 ,5, 428–430. [CrossRef] [PubMed] 51. Fino, E.; Mazzetti, M. Monitoring healthy and disturbed sleep through smartphone applications: A review of experimental evidence. Sleep Breath. 2019,23, 13–24. [CrossRef] 52. Behar, J.; Roebuck, A.; Domingos, J.S.; Gederi, E.; Clifford, G.D. A review of current sleep screening applications for smartphones. Physiol. Meas. 2013,34, R29–R46. [CrossRef] 53. Nakano, H.; Hirayama, K.; Sadamitsu, Y.; Toshimitsu, A.; Fujita, H.; Shin, S.; Tanigawa, T. Monitoring Sound To Quantify Snoring and Sleep Apnea Severity Using a Smartphone: Proof of Concept. J. Clin. Sleep Med. 2014,10, 73–78. [CrossRef] [PubMed] 54. Castillo-Escario, Y.; Ferrer-Lluis, I.; Montserrat, J.M.; Jane, R. Automatic Silence Events Detector from Smartphone Audio Signals: A Pilot mHealth System for Sleep Apnea Monitoring at Home. In Proceedings of the 2019 41st Annual International Conference of the IEEE Engineering in Medicine and Biology Society (EMBC), Berlin, Germany, 23–27 July 2019; pp. 4982–4985. 55. Castillo-Escario, Y.; Ferrer-Lluis, I.; Montserrat, J.M.; Jane, R. Entropy Analysis of Acoustic Signals Recorded With a Smartphone for Detecting Apneas and Hypopneas: A Comparison With a Commercial System for Home Sleep Apnea Diagnosis. IEEE Access 2019,7, 128224–128241. [CrossRef] 56. Behar, J.; Roebuck, A.; Shahid, M.; Daly, J.; Hallack, A.; Palmius, N.; Stradling, J.; Clifford, G.D. SleepAp: An Automated Obstructive Sleep Apnoea Screening Application for Smartphones. IEEE J. Biomed. Health Inform. 2015 ,19, 325–331. [CrossRef] [PubMed] 57. Bates, A.; Ling, M.J.; Mann, J.; Arvind, D.K. Respiratory rate and flow waveform estimation from tri-axial accelerometer data. In Proceedings of the 2010 International Conference on Body Sensor Networks, Singapore, 7–9 June 2010; pp. 144–150. 58. Ferrer-Lluis, I.; Castillo-Escario, Y.; Montserrat, J.M.; Jane, R. Automatic Event Detector from Smartphone Accelerometry: Pilot mHealth Study for Obstructive Sleep Apnea Monitoring at Home. In Proceedings of the 2019 41st Annual International Conference of the IEEE Engineering in Medicine and Biology Society (EMBC), Berlin, Germany, 23–27 July 2019; pp. 4990–4993. 59. Ferrer-Lluis, I.; Castillo-Escario, Y.; Montserrat, J.M.; Jane, R. Analysis of Smartphone Triaxial Accelerometry for Monitoring Sleep-Disordered Breathing and Sleep Position at Home. IEEE Access 2020,8, 71231–71244. [CrossRef] 60. Liu, G.-Z.; Guo, Y.-W.; Zhu, Q.-S.; Huang, B.-Y.; Wang, L. Estimation of Respiration Rate from Three-Dimensional Acceleration Data Based on Body Sensor Network. Telemed. e-Health 2011,17, 705–711. [CrossRef] [PubMed] 61. Haas, D.; Birk, R.; Maurer, J.T.; Hörmann, K.; Stuck, B.A.; Sommer, J.U. Therapie rückenlagebezogener obstruktiver Schlafapnoe mittels Smartphone-App. HNO 2017,65, 148–153. [CrossRef] 62. Berry, R.B.; Budhiraja, R.; Gottlieb, D.J.; Gozal, D.; Iber, C.; Kapur, V.K.; Marcus, C.L.; Mehra, R.; Parthasarathy, S.; Quan, S.F.; et al. Rules for Scoring Respiratory Events in Sleep: Update of the 2007 AASM Manual for the Scoring of Sleep and Associated Events. J. Clin. Sleep Med. 2012,08, 597–619. [CrossRef] 63. Temirbekoy, D.; Gunes, S.; Yazici, Z.M.; Sayin, ˙ I. The Ignored Parameter in the Diagnosis of Obstructive Sleep Apnea Syndrome The Oxygen Desaturation Index. Turk Otolarengoloji Arsivi Turkish Arch. Otolaryngol. 2018, 1–6. [CrossRef]
Sensors 2021,21, 4531 22 of 22 64. Fietze, I.; Dingli, K.; Diefenbach, K.; Douglas, N.J.; Glos, M.; Tallafuss, M.; Terhalle, W.; Witt, C. Night-to-night variation of the oxygen desaturation index in sleep apnoea syndrome. Eur. Respir. J. 2004,24, 987–993. [CrossRef] 65. Skarpsno, E.S.; Mork, P.J.; Nilsen, T.I.L.; Holtermann, A. Sleep positions and nocturnal body movements based on free-living accelerometer recordings: Association with demographics, lifestyle, and insomnia symptoms. Nat. Sci. Sleep 2017. [CrossRef] 66. Freed, J.; Lowe, C.; Flodgren, G.; Binks, R.; Doughty, K.; Kolsi, J. Telemedicine: Is it really worth it? A perspective from evidence and experience. BMJ Heal. Care Inform. 2018,25, 14–18. [CrossRef] [PubMed] 67. Ekeland, A.G.; Bowes, A.; Flottorp, S. Effectiveness of telemedicine: A systematic review of reviews. Int. J. Med. Inform. 2010 ,79, 736–771. [CrossRef] [PubMed]