Samsung/Tizen-CSharp-Samples

Sample HeartRateMonitor - Event OnDataUpdated not fired when screen off

Abesoddy opened this issue · 3 comments

Hello,

Is it possible to get the heart rate sensor data when the screen is off ? I tested the HeartRateMonitor sample but when the screen goes to sleep, the returned value is 0 on the event OnDataUpdated().

Best regards,

I found this on native development but I can't find a solution with Tizen FX : https://developer.tizen.org/ko/forums/native-application-development/sensors-sleep-mode?langswitch=ko

@Abesoddy I guess you can use SensorPausePolicy. (https://samsung.github.io/TizenFX/API6/api/Tizen.Sensor.SensorPausePolicy.html)
In your case, You can add this code heartRateMonitor.PausePolicy = SensorPausePolicy.None; to achieve what you want.

Hello,

Indeed, thank you very much for your answer, this is exactly what I need !