Open FintasticMan opened 1 year ago
Build size and comparison to main: | Section | Size | Difference |
---|---|---|---|
text | 397104B | 1324B | |
data | 1020B | 24B | |
bss | 63428B | 8B |
Actually I was mistaken. This is not quite like a circular buffer. A class that tracks the changes made to a variable, with template parameters specifying the resolution and how much history is stored would be more appropriate for this use case. You would access the value an hour ago through a function that you pass a time point or duration to.
Depends on #1696.
This adds a feature that sends the user a notification if they haven't walked a certain number of steps within the past hour. It works by keeping track of the number of steps every half hour, storing them in a circular buffer. It checks whether difference between the number of steps from the last half hour and the number of steps from an hour before that is lower than the threshold.
The majority of the size increase comes from the settings screen, so if I can make that smaller, that would be good.
I'm not sure if a notification is the best way to handle alerting the user. Suggestions welcome.