Module ctr.ptm

The ptm module.

Usage:

    local ptm = require("ctr.ptm")

Functions

init () Initialize the PTM module.
shutdown () Disable the PTM module.
getShellState () Return the shell state.
getBatteryLevel () Return the battery level.
getBatteryChargeState () Return whether or not the battery is charging.
getPedometerState () Return whether or not the pedometer is counting.
getTotalStepCount () Return the total steps taken with the system.
configureNew3DSCPU (enable) (N3DS only) Setup the new 3DS CPU features (overclock, 4 cores ...)


Functions

init ()
Initialize the PTM module.
shutdown ()
Disable the PTM module.
getShellState ()
Return the shell state.

Returns:

    boolean shell state, true if open, false if closed.
getBatteryLevel ()
Return the battery level.

Returns:

    number battery level (5: fully charged; 0: empty)
getBatteryChargeState ()
Return whether or not the battery is charging.

Returns:

    boolean true if the battery is charging
getPedometerState ()
Return whether or not the pedometer is counting.

Returns:

    boolean true if the pedometer is counting
getTotalStepCount ()
Return the total steps taken with the system.

Returns:

    number step count
configureNew3DSCPU (enable) (N3DS only)
Setup the new 3DS CPU features (overclock, 4 cores ...)

Parameters:

  • enable boolean enable the New3DS CPU features

Returns:

    boolean true if everything went fine

Or

  1. boolean false in case of error
  2. integer error code
generated by LDoc 1.4.3 Last updated 2017-06-05 14:35:27