You might try
When the Screen closes or when you change to use another app, the pedometer still counts.