Android Question Count steps with sensor

ifz3ft

New Member
Hi there

I am referring to this post:

https://www.b4x.com/android/forum/threads/kitkat-step-detector.40563/#post-242811, and the lines

B4X:
AddSensor(18, "TYPE_STEP_DETECTOR", False)
AddSensor(19, "TYPE_STEP_COUNTER", False)

Sorry to come back on such an old topic but when I execute this code on Redmi11 I get a fixed value of 98.508 and despite my moves.
(and TYPE_STEP_DETECTOR appears with value 1 when I start moving)

What is wrong here please ?

Only Targetsdkversion=28 displays those 2 values. Higher version says "not supported". So another question is how to count steps with version 33 ?

Thanks in advance
 
Top