summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/ptm/ptm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/service/ptm/ptm.h')
-rw-r--r--src/core/hle/service/ptm/ptm.h46
1 files changed, 35 insertions, 11 deletions
diff --git a/src/core/hle/service/ptm/ptm.h b/src/core/hle/service/ptm/ptm.h
index f697aae4d..493e6a11f 100644
--- a/src/core/hle/service/ptm/ptm.h
+++ b/src/core/hle/service/ptm/ptm.h
@@ -5,6 +5,7 @@
#pragma once
#include <array>
+#include "core/hle/service/service.h"
#include "core/hle/result.h"
namespace Service {
@@ -35,31 +36,54 @@ struct GameCoin {
};
/**
- * Returns whether the battery is charging or not.
* It is unknown if GetAdapterState is the same as GetBatteryChargeState,
* it is likely to just be a duplicate function of GetBatteryChargeState
* that controls another part of the HW.
- * @returns 1 if the battery is charging, and 0 otherwise.
+ * PTM::GetAdapterState service function
+ * Outputs:
+ * 1 : Result of function, 0 on success, otherwise error code
+ * 2 : Output of function, 0 = not charging, 1 = charging.
*/
-u32 GetAdapterState();
+void GetAdapterState(Interface* self);
/**
- * Returns whether the 3DS's physical shell casing is open or closed
- * @returns 1 if the shell is open, and 0 if otherwise
+ * PTM::GetShellState service function.
+ * Outputs:
+ * 1 : Result of function, 0 on success, otherwise error code
+ * 2 : Whether the 3DS's physical shell casing is open (1) or closed (0)
*/
-u32 GetShellState();
+void GetShellState(Interface* self);
/**
- * Get the current battery's charge level.
- * @returns The battery's charge level.
+ * PTM::GetBatteryLevel service function
+ * Outputs:
+ * 1 : Result of function, 0 on success, otherwise error code
+ * 2 : Battery level, 5 = completely full battery, 4 = mostly full battery,
+ * 3 = half full battery, 2 = low battery, 1 = critical battery.
*/
-ChargeLevels GetBatteryLevel();
+void GetBatteryLevel(Interface* self);
+
+/**
+ * PTM::GetBatteryChargeState service function
+ * Outputs:
+ * 1 : Result of function, 0 on success, otherwise error code
+ * 2 : Output of function, 0 = not charging, 1 = charging.
+ */
+void GetBatteryChargeState(Interface* self);
+
+/**
+ * PTM::IsLegacyPowerOff service function
+ * Outputs:
+ * 1: Result code, 0 on success, otherwise error code
+ * 2: Whether the system is going through a power off
+ */
+void IsLegacyPowerOff(Interface* self);
/// Initialize the PTM service
-void PTMInit();
+void Init();
/// Shutdown the PTM service
-void PTMShutdown();
+void Shutdown();
} // namespace PTM
} // namespace Service