Add "Steps per hour" system setting (#211)

* Implements a steps per hour (global) setting that gets returned by PTM GetStepHistory

* Make setting label text clearer

* Add setting to SDL frontend

* Add setting to Android (no UI)

* Remove IntSetting enum value

* Follow convension in android default ini
This commit is contained in:
szdarkhack 2024-08-20 22:04:29 +03:00 committed by GitHub
parent 8538a57be0
commit e1ff3b8dbe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 42 additions and 9 deletions

View file

@ -84,9 +84,8 @@ void Module::Interface::GetStepHistory(Kernel::HLERequestContext& ctx) {
ASSERT_MSG(sizeof(u16) * hours == buffer.GetSize(),
"Buffer for steps count has incorrect size");
// Stub: set zero steps count for every hour
const u16_le steps_per_hour = Settings::values.steps_per_hour.GetValue();
for (u32 i = 0; i < hours; ++i) {
const u16_le steps_per_hour = 0;
buffer.Write(&steps_per_hour, i * sizeof(u16), sizeof(u16));
}