Changes

Jump to navigation Jump to search
15,476 bytes added ,  16:18, 17 September 2020
→‎PrepareForJit: jit details
Line 114: Line 114:  
|-
 
|-
 
| 100 || [6.0.0+] [[#PopRequestLaunchApplicationForDebug]] ||
 
| 100 || [6.0.0+] [[#PopRequestLaunchApplicationForDebug]] ||
 +
|-
 +
| 110 || [9.0.0+] [[#IsForceTerminateApplicationDisabledForDebug]] ||
 
|-
 
|-
 
| 200 || [8.0.0+] [[#LaunchDevMenu]] ||
 
| 200 || [8.0.0+] [[#LaunchDevMenu]] ||
Line 144: Line 146:     
==== PopRequestLaunchApplicationForDebug ====
 
==== PopRequestLaunchApplicationForDebug ====
Takes a type-0x6 output buffer containing an array of u128 userIDs, returns an output u64 titleID (<code>nn::ncm::ApplicationId</code>) and an output s32 '''total_userIDs'''.
+
Takes a type-0x6 output buffer containing an array of u128 userIDs, returns an output [[NCM_services#ApplicationId|ApplicationId]] and an output s32 '''total_userIDs'''.
    
The total entries in the userID buffer must be >= {total userIDs in state}.
 
The total entries in the userID buffer must be >= {total userIDs in state}.
 +
 +
==== IsForceTerminateApplicationDisabledForDebug ====
 +
No input, returns an output u8 bool.
 +
 +
When the cached value loaded from [[Settings_services#GetDebugModeFlag]] is 0 this will just set the bool to 0. Otherwise, the bool is loaded using data from [[System_Settings|system-setting]] <code>am.debug!disable_force_terminate_application</code>.
    
==== LaunchDevMenu ====
 
==== LaunchDevMenu ====
Line 167: Line 174:  
|-
 
|-
 
| 3 || [[#GetEvent]]
 
| 3 || [[#GetEvent]]
 +
|-
 +
| 4 || [10.0.0+] [[#IsLocked]]
 
|}
 
|}
   Line 181: Line 190:  
===== GetEvent =====
 
===== GetEvent =====
 
No input, returns an output Event handle with autoclear=false.
 
No input, returns an output Event handle with autoclear=false.
 +
 +
==== IsLocked ====
 +
No input, returns an output u8 bool.
    
=== IGlobalStateController ===
 
=== IGlobalStateController ===
Line 283: Line 295:     
==== CreateApplication ====
 
==== CreateApplication ====
Takes an input u64 titleID (<code>nn::ncm::ApplicationId</code>), returns an [[#IApplicationAccessor]].
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an [[#IApplicationAccessor]].
    
==== PopLaunchRequestedApplication ====
 
==== PopLaunchRequestedApplication ====
Line 289: Line 301:     
==== CreateSystemApplication ====
 
==== CreateSystemApplication ====
Takes an input u64 titleID (<code>nn::ncm::SystemApplicationId</code>), returns an [[#IApplicationAccessor]].
+
Takes an input [[NCM_services#ApplicationId|SystemApplicationId]], returns an [[#IApplicationAccessor]].
   −
[[qlaunch]] only uses this with a hard-coded titleID for the "starter" title.
+
[[qlaunch]] only uses this with a hard-coded id for the "starter" title.
    
==== PopFloatingApplicationForDevelopment ====
 
==== PopFloatingApplicationForDevelopment ====
Line 346: Line 358:  
|-
 
|-
 
| 170 || [8.0.0+] [[#HasSaveDataAccessPermission]] ||
 
| 170 || [8.0.0+] [[#HasSaveDataAccessPermission]] ||
 +
|-
 +
| 180 || [9.0.0+] [[#PushToFriendInvitationStorageChannel]] ||
 +
|-
 +
| 190 || [9.0.0+] [[#PushToNotificationStorageChannel]] ||
 +
|-
 +
| 200 || [10.0.0+] [[#RequestApplicationSoftReset]] ||
 +
|-
 +
| 201 || [10.0.0+] [[#RestartApplicationTimer]] ||
 
|}
 
|}
   Line 357: Line 377:     
===== GetApplicationId =====
 
===== GetApplicationId =====
No input, returns an output u64 titleID.
+
No input, returns an output [[NCM_services#ApplicationId|ApplicationId]].
 
  −
Gets the Application titleID.
      
===== PushLaunchParameter =====
 
===== PushLaunchParameter =====
Line 410: Line 428:     
===== HasSaveDataAccessPermission =====
 
===== HasSaveDataAccessPermission =====
Takes an input u64 titleID, returns an output u8 bool flag.
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output u8 bool flag.
   −
Gets whether the savedata specified by the input titleID is accessible. The output flag indicates whether it's accessible.
+
Gets whether the savedata specified by the input ApplicationId is accessible. The output flag indicates whether it's accessible.
   −
If the titleID matches the current application titleID, this immediately returns success with flag=1.
+
If the ApplicationId matches the current application, this immediately returns success with flag=1.
 +
 
 +
===== PushToFriendInvitationStorageChannel =====
 +
Takes an input [[#IStorage]], no output.
 +
 
 +
Clears the FriendInvitation StorageChannel, then pushes the input storage there.
 +
 
 +
===== PushToNotificationStorageChannel =====
 +
Takes an input [[#IStorage]], no output.
 +
 
 +
Clears the Notification StorageChannel, then pushes the input storage there.
 +
 
 +
[[qlaunch]] will only push data for this when launching the Application when the Alarm was triggered, where the system was previously in sleep-mode. This data is the [[Glue_services|Notification]] ApplicationParameter.
 +
 
 +
===== RequestApplicationSoftReset =====
 +
No input/output.
 +
 
 +
===== RestartApplicationTimer =====
 +
No input/output.
    
===== IAppletAccessor =====
 
===== IAppletAccessor =====
Line 458: Line 494:  
|-
 
|-
 
! Cmd || Name || Notes
 
! Cmd || Name || Notes
 +
|-
 +
| 0 || [9.0.0+] [[#SetTerminateResult]] ||
 
|-
 
|-
 
| 10 || [[#ReadThemeStorage]] ||  
 
| 10 || [[#ReadThemeStorage]] ||  
 
|-
 
|-
 
| 11 || [[#WriteThemeStorage]] ||  
 
| 11 || [[#WriteThemeStorage]] ||  
 +
|-
 +
| 20 || [9.0.0+] [[#PushToAppletBoundChannel]] ||
 +
|-
 +
| 21 || [9.0.0+] [[#TryPopFromAppletBoundChannel]] ||
 
|-
 
|-
 
| 40 || [8.0.0+] [[#GetDisplayLogicalResolution]] ||  
 
| 40 || [8.0.0+] [[#GetDisplayLogicalResolution]] ||  
Line 470: Line 512:  
|-
 
|-
 
| 51 || [8.0.0+] [[#GetHomeButtonDoubleClickEnabled]] ||  
 
| 51 || [8.0.0+] [[#GetHomeButtonDoubleClickEnabled]] ||  
 +
|-
 +
| 52 || [10.0.0+] [[#IsHomeButtonShortPressedBlocked]] ||
 
|}
 
|}
   Line 479: Line 523:  
=== WriteThemeStorage ===
 
=== WriteThemeStorage ===
 
Takes an input u64 '''offset''' and a type-0x21 input buffer, no output.
 
Takes an input u64 '''offset''' and a type-0x21 input buffer, no output.
 +
 +
=== PushToAppletBoundChannel ===
 +
Takes an input [[#IStorage]], no output.
 +
 +
This is similar to [[#PushToAppletBoundChannelForDebug]] (no DebugMode check), except the used s32 is loaded from elsewhere and must be in the range 31-32.
 +
 +
=== TryPopFromAppletBoundChannel ===
 +
No input, returns an output [[#IStorage]].
 +
 +
This is similar to [[#TryPopFromAppletBoundChannelForDebug]] (no DebugMode check), except the used s32 is loaded from elsewhere and must be in the range 31-32.
    
=== GetDisplayLogicalResolution ===
 
=== GetDisplayLogicalResolution ===
Line 494: Line 548:     
=== GetHomeButtonDoubleClickEnabled ===
 
=== GetHomeButtonDoubleClickEnabled ===
 +
No input, returns an output u8 bool.
 +
 +
=== IsHomeButtonShortPressedBlocked ===
 
No input, returns an output u8 bool.
 
No input, returns an output u8 bool.
   Line 588: Line 645:  
|-
 
|-
 
| 110 || [6.0.0+] [[#GetMainAppletAvailableUsers]] ||
 
| 110 || [6.0.0+] [[#GetMainAppletAvailableUsers]] ||
 +
|-
 +
| 120 || [9.0.0+] [[#GetLaunchStorageInfoForDebug]] ||
 +
|-
 +
| 130 || [9.0.0+] [[#GetGpuErrorDetectedSystemEvent]] ||
 +
|-
 +
| 140 || [10.0.0+] [[#SetApplicationMemoryReservation]] ||
 +
|-
 +
| 150 || [10.0.0+] [[#ShouldSetGpuTimeSliceManually]] ||
 
|}
 
|}
   Line 673: Line 738:     
==== GetCurrentApplicationId ====
 
==== GetCurrentApplicationId ====
No input, returns an output u64.
+
No input, returns an output [[NCM_services#ApplicationId|ApplicationId]].
   −
Gets the titleID for the currently running Application. titleID=0 when no Application is running.
+
Gets the [[NCM_services#ApplicationId|ApplicationId]] for the currently running Application. ApplicationId=0 when no Application is running.
    
==== RequestExitToSelf ====
 
==== RequestExitToSelf ====
Line 683: Line 748:     
==== CreateApplicationAndPushAndRequestToLaunch ====
 
==== CreateApplicationAndPushAndRequestToLaunch ====
Takes an input u64 titleID and an input #IStorage, no output.
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]] and an input #IStorage, no output.
    
This is is similar to [[#CreateApplicationAndPushAndRequestToStart]].
 
This is is similar to [[#CreateApplicationAndPushAndRequestToStart]].
Line 712: Line 777:     
Normally the output bool is set to 0, however when no users are available it's set to 1 with '''total_entries''' = -1.
 
Normally the output bool is set to 0, however when no users are available it's set to 1 with '''total_entries''' = -1.
 +
 +
==== SetApplicationMemoryReservation ====
 +
Takes an input u64, no output.
 +
 +
An Application must be currently running. The input u64 must be 0x1000-byte aligned.
 +
 +
==== ShouldSetGpuTimeSliceManually ====
 +
No input, returns an output u8 bool.
    
== IOverlayAppletProxy ==
 
== IOverlayAppletProxy ==
Line 763: Line 836:  
|-
 
|-
 
| 20 || [8.0.0+] [[#SetHandlingHomeButtonShortPressedEnabled]]
 
| 20 || [8.0.0+] [[#SetHandlingHomeButtonShortPressedEnabled]]
 +
|-
 +
| 30 || [9.0.0+] [[#SetHealthWarningShowingState]]
 +
|-
 +
| 31 || [10.0.0+] [[#IsHealthWarningRequired]]
 
|-
 
|-
 
| 90 || [7.0.0+] [[#SetRequiresGpuResourceUse]]
 
| 90 || [7.0.0+] [[#SetRequiresGpuResourceUse]]
Line 776: Line 853:     
==== GetApplicationIdForLogo ====
 
==== GetApplicationIdForLogo ====
No input, returns an output u64 titleID.
+
No input, returns an output [[NCM_services#ApplicationId|ApplicationId]].
   −
Gets the application titleID for displaying the logo screen during application launch.
+
Gets the ApplicationId for displaying the logo screen during application launch.
   −
When no application is running, this returns success with titleID=0.
+
When no application is running, this returns success with ApplicationId=0.
    
==== SetGpuTimeSliceBoost ====
 
==== SetGpuTimeSliceBoost ====
Line 806: Line 883:  
==== SetHandlingHomeButtonShortPressedEnabled ====
 
==== SetHandlingHomeButtonShortPressedEnabled ====
 
Takes an input u8 bool, no output.
 
Takes an input u8 bool, no output.
 +
 +
==== SetHealthWarningShowingState ====
 +
Takes an input u8 bool, no output.
 +
 +
This writes the input bool into state, signals an Event, and returns 0.
 +
 +
==== IsHealthWarningRequired ====
 +
No input, returns an output u8 bool.
    
==== SetRequiresGpuResourceUse ====
 
==== SetRequiresGpuResourceUse ====
Line 885: Line 970:  
|-
 
|-
 
| 33 || [[#EndBlockingHomeButton]] ||
 
| 33 || [[#EndBlockingHomeButton]] ||
 +
|-
 +
| 34 || [10.0.0+] [[#SelectApplicationLicense]] ||
 
|-
 
|-
 
| 40 || [[#NotifyRunning]] ||
 
| 40 || [[#NotifyRunning]] ||
Line 903: Line 990:  
|-
 
|-
 
| 71 || [3.0.0+] [[#RequestToReboot]] ||
 
| 71 || [3.0.0+] [[#RequestToReboot]] ||
 +
|-
 +
| 72 || [10.0.0+] [[#RequestToSleep]] ||
 
|-
 
|-
 
| 80 || [4.0.0+] [[#ExitAndRequestToShowThanksMessage]] ||  
 
| 80 || [4.0.0+] [[#ExitAndRequestToShowThanksMessage]] ||  
Line 930: Line 1,019:  
| 130 || [8.0.0+] [[#GetGpuErrorDetectedSystemEvent]] ||  
 
| 130 || [8.0.0+] [[#GetGpuErrorDetectedSystemEvent]] ||  
 
|-
 
|-
| 500 || [5.0.0+] StartContinuousRecordingFlushForDebug ||  
+
| 140 || [9.0.0+] [[#GetFriendInvitationStorageChannelEvent]] ||
 +
|-
 +
| 141 || [9.0.0+] [[#TryPopFromFriendInvitationStorageChannel]] ||
 +
|-
 +
| 150 || [9.0.0+] [[#GetNotificationStorageChannelEvent]] ||
 +
|-
 +
| 151 || [9.0.0+] [[#TryPopFromNotificationStorageChannel]] ||
 +
|-
 +
| 160 || [9.0.0+] [[#GetHealthWarningDisappearedSystemEvent]] ||
 +
|-
 +
| 170 || [9.0.0+] [[#SetHdcpAuthenticationActivated]] ||
 +
|-
 +
| 180 || [10.1.0+] [[#GetLaunchRequiredVersion]] ||
 +
|-
 +
| 181 || [10.1.0+] [[#UpgradeLaunchRequiredVersion]] ||
 +
|-
 +
| 500 || [5.0.0+] [[#StartContinuousRecordingFlushForDebug]] ||  
 
|-
 
|-
 
| 1000 || [5.0.0+] [[#CreateMovieMaker]] ||  
 
| 1000 || [5.0.0+] [[#CreateMovieMaker]] ||  
Line 950: Line 1,055:     
==== CreateApplicationAndPushAndRequestToStart ====
 
==== CreateApplicationAndPushAndRequestToStart ====
Takes an input u64 titleID and an input [[#IStorage]], no output. titleID=0 can be used to relaunch the current application.
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]] and an input [[#IStorage]], no output. ApplicationId=0 can be used to relaunch the current application.
    
==== CreateApplicationAndPushAndRequestToStartForQuest ====
 
==== CreateApplicationAndPushAndRequestToStartForQuest ====
Takes 2 input u32s (loaded from struct [[#ApplicationAttributeForQuest]]), an input u64 titleID, and an input [[#IStorage]], no output.
+
Takes 2 input u32s (loaded from struct [[#ApplicationAttributeForQuest]]), an input [[NCM_services#ApplicationId|ApplicationId]], and an input [[#IStorage]], no output.
    
==== CreateApplicationAndRequestToStart ====
 
==== CreateApplicationAndRequestToStart ====
Takes an input u64 titleID, no output.
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]], no output.
    
Same as [[#CreateApplicationAndPushAndRequestToStart]] except without the input storage, official sw uses this when no input storage is specified.
 
Same as [[#CreateApplicationAndPushAndRequestToStart]] except without the input storage, official sw uses this when no input storage is specified.
    
==== CreateApplicationAndRequestToStartForQuest ====
 
==== CreateApplicationAndRequestToStartForQuest ====
Takes 2 input u32s (loaded from struct [[#ApplicationAttributeForQuest]]) and an input u64 titleID, no output.
+
Takes 2 input u32s (loaded from struct [[#ApplicationAttributeForQuest]]) and an input [[NCM_services#ApplicationId|ApplicationId]], no output.
    
Same as [[#CreateApplicationAndPushAndRequestToStartForQuest]] except without the input storage, official sw uses this when no input storage is specified.
 
Same as [[#CreateApplicationAndPushAndRequestToStartForQuest]] except without the input storage, official sw uses this when no input storage is specified.
    
==== CreateApplicationWithAttributeAndPushAndRequestToStartForQuest ====
 
==== CreateApplicationWithAttributeAndPushAndRequestToStartForQuest ====
Takes an input u64 titleID, a type-0x15 input buffer containing an [[#ApplicationAttribute]], an input [[#IStorage]], no output.
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]], a type-0x15 input buffer containing an [[#ApplicationAttribute]], an input [[#IStorage]], no output.
    
Same as [[#CreateApplicationAndPushAndRequestToStartForQuest]] except the entire attributes structure is directly specified via the input buffer. This command replaces [[#CreateApplicationAndPushAndRequestToStartForQuest]], official user-processes no longer use [[#CreateApplicationAndPushAndRequestToStartForQuest]].
 
Same as [[#CreateApplicationAndPushAndRequestToStartForQuest]] except the entire attributes structure is directly specified via the input buffer. This command replaces [[#CreateApplicationAndPushAndRequestToStartForQuest]], official user-processes no longer use [[#CreateApplicationAndPushAndRequestToStartForQuest]].
    
==== CreateApplicationWithAttributeAndRequestToStartForQuest ====
 
==== CreateApplicationWithAttributeAndRequestToStartForQuest ====
Takes an input u64 titleID and a type-0x15 input buffer containing an [[#ApplicationAttribute]], no output.
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]] and a type-0x15 input buffer containing an [[#ApplicationAttribute]], no output.
    
Same as [[#CreateApplicationAndRequestToStartForQuest]] except the entire attributes structure is directly specified via the input buffer. This command replaces [[#CreateApplicationAndRequestToStartForQuest]], official user-processes no longer use [[#CreateApplicationAndPushAndRequestToStartForQuest]].
 
Same as [[#CreateApplicationAndRequestToStartForQuest]] except the entire attributes structure is directly specified via the input buffer. This command replaces [[#CreateApplicationAndRequestToStartForQuest]], official user-processes no longer use [[#CreateApplicationAndPushAndRequestToStartForQuest]].
Line 1,019: Line 1,124:  
==== EndBlockingHomeButton ====
 
==== EndBlockingHomeButton ====
 
No input/output.
 
No input/output.
 +
 +
==== SelectApplicationLicense ====
 +
Takes an input array of [[#ApplicationLicenseType]], returns an output [[#ApplicationLicenseType]].
    
==== NotifyRunning ====
 
==== NotifyRunning ====
Line 1,042: Line 1,150:  
==== RequestFlushGamePlayingMovieForDebug ====
 
==== RequestFlushGamePlayingMovieForDebug ====
 
No input/output.
 
No input/output.
 +
 +
Requests to save the video recording, as if the Capture-button was held.
    
==== RequestToShutdown ====
 
==== RequestToShutdown ====
Line 1,052: Line 1,162:     
On success, official sw will enter an infinite loop with sleep-thread value 86400000000000.
 
On success, official sw will enter an infinite loop with sleep-thread value 86400000000000.
 +
 +
==== RequestToSleep ====
 +
No input/output.
    
==== ExitAndRequestToShowThanksMessage ====
 
==== ExitAndRequestToShowThanksMessage ====
Line 1,089: Line 1,202:     
==== QueryApplicationPlayStatistics ====
 
==== QueryApplicationPlayStatistics ====
Takes a type-0x6 output buffer containing an array of [[Shared_Database_services|ApplicationPlayStatistics]] and a type-0x5 input buffer containing an array of u64 titleIDs. Returns an output s32 for actual total output entries.
+
Takes a type-0x6 output buffer containing an array of [[Shared_Database_services|ApplicationPlayStatistics]] and a type-0x5 input buffer containing an array of [[NCM_services#ApplicationId|ApplicationId]]. Returns an output s32 for actual total output entries.
    
The number of entries in each array is the same.
 
The number of entries in each array is the same.
Line 1,098: Line 1,211:     
==== QueryApplicationPlayStatisticsByUid ====
 
==== QueryApplicationPlayStatisticsByUid ====
Takes a u128 userID, a type-0x6 output buffer containing an array of [[Shared_Database_services|ApplicationPlayStatistics]] and a type-0x5 input buffer containing an array of u64 titleIDs. Returns an output s32 for actual total output entries.
+
Takes a u128 userID, a type-0x6 output buffer containing an array of [[Shared_Database_services|ApplicationPlayStatistics]] and a type-0x5 input buffer containing an array of [[NCM_services#ApplicationId|ApplicationId]]. Returns an output s32 for actual total output entries.
    
Same as [[#QueryApplicationPlayStatistics]] except this uses [[Shared_Database_services|pdm:qry]] cmd16, to get playstats specific to userIDs.  
 
Same as [[#QueryApplicationPlayStatistics]] except this uses [[Shared_Database_services|pdm:qry]] cmd16, to get playstats specific to userIDs.  
Line 1,119: Line 1,232:  
==== GetPreviousProgramIndex ====
 
==== GetPreviousProgramIndex ====
 
No input, returns an output s32.
 
No input, returns an output s32.
 +
 +
Gets the ProgramIndex of the Application which launched this title. The output ProgramIndex is -1 when there was no previous title.
    
==== EnableApplicationAllThreadDumpOnCrash ====
 
==== EnableApplicationAllThreadDumpOnCrash ====
Line 1,126: Line 1,241:  
No input, returns an output Event handle with autoclear=false.
 
No input, returns an output Event handle with autoclear=false.
   −
This is used by sdknso during applet-application initialization. A seperate thread is setup where event-waiting is handled. When the Event is signaled, official sw will assert.
+
This is used by sdknso during applet-application initialization. A separate thread is setup where event-waiting is handled. When the Event is signaled, official sw will assert.
   −
==== CreateMovieMaker ====
+
==== GetFriendInvitationStorageChannelEvent ====
Takes an input u64 and handle, returns an [[#IMovieMaker]].
+
No input, returns an output Event handle with EventClearMode=0.
   −
==== PrepareForJit ====
+
This is exposed by sdknso under <code>nn::friends::</code>. This returns a ptr to the cached Event in global state, with the Event being loaded if not previously initialized.
Takes no input. Launches title 010000000000003B (currently not present on retail systems) if some context variable is not set, with that context variable being initialized afterwards.
+
 
 +
==== TryPopFromFriendInvitationStorageChannel ====
 +
No input, returns an output [[#IStorage]].
 +
 
 +
This uses the same StorageChannel as [[#PushToFriendInvitationStorageChannel]].
 +
 
 +
This is exposed by sdknso under <code>nn::friends::</code>. When the storage_size is <0x10, this returns false. <code>data_size = storage_size-0x10;</code> Then the first 0x10-bytes from storage are read to stack, which is later copied to the output Uid on success prior to returning. Then the storage is read into the specified output buffer with storage-offset 0x10, where the size is <code>size = data_size > buf_size ? buf_size : data_size</code>. Reading is skipped if size is zero. Afterwards the used size is written to an output param. On success, true is returned.
 +
 
 +
==== GetNotificationStorageChannelEvent ====
 +
No input, returns an output Event handle with EventClearMode=0.
 +
 
 +
This is exposed by sdknso under <code>nn::notification::</code>. This returns a ptr to the cached Event in global state, with the Event being loaded if not previously initialized.
 +
 
 +
==== TryPopFromNotificationStorageChannel ====
 +
No input, returns an output [[#IStorage]].
 +
 
 +
This uses the same StorageChannel as [[#PushToNotificationStorageChannel]].
 +
 
 +
This is exposed by sdknso under <code>nn::notification::</code>. The storage is read into the specified output buffer, where the size is <code>size = storage_size > buf_size ? buf_size : storage_size</code>. Reading is skipped if size is zero. Afterwards the used size is written to an output param.
 +
 
 +
==== GetHealthWarningDisappearedSystemEvent ====
 +
No input, returns an output Event with EventClearMode=0.
 +
 
 +
==== SetHdcpAuthenticationActivated ====
 +
Takes an input u8 bool, no output.
 +
 
 +
==== GetLaunchRequiredVersion ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], an u64, returns an output [[#LaunchRequiredVersion]].
 +
 
 +
sdknso passes hard-coded value 0 for the u64.
 +
 
 +
==== UpgradeLaunchRequiredVersion ====
 +
Takes an input [[#LaunchRequiredVersion]], an [[NCM_services#ApplicationId|ApplicationId]], an u64, no output.
 +
 
 +
sdknso passes hard-coded value 0 for the u64.
 +
 
 +
==== StartContinuousRecordingFlushForDebug ====
 +
Takes an input s64 nanoseconds-value, returns an output Event handle with autoclear=false.
 +
 
 +
The cached value loaded from [[System_Settings|system-setting]] <code>am.debug!dev_function</code> must be set to 0x1 with size 0x1, otherwise an error is returned.
 +
 
 +
==== CreateMovieMaker ====
 +
Takes an input u64 size and a TransferMemory handle, returns an [[#IMovieMaker]].
 +
 
 +
Official sw retries using the cmd in a loop on error 0x8D4 with svcSleepThread(100000000) being used first.
 +
 
 +
Official sw uses permissions=None for the TransferMemory, with an user-specified buffer. The size of the buffer used by official sw is 0x6000000.
 +
 
 +
==== PrepareForJit ====
 +
Takes no input. Launches the [[JIT_services|jit-sysmodule]] if it has not already been launched for the current application, storing a std::shared_ptr<> for jit-sysmodule process tracking object as an IApplicationFunctions member.
 +
 
 +
~IApplicationFunctions() includes:
 +
 
 +
    if (this->jit_process) {
 +
        Terminate(this->jit_process);
 +
        this->jit_process = nullptr;
 +
    }
 +
 
 +
Thus the lifetime of the jit sysmodule is tied to the application which uses it, and each application gets its own fresh copy of the jit sysmodule.
    
=== IMovieMaker ===
 
=== IMovieMaker ===
Line 1,220: Line 1,393:  
|-
 
|-
 
| 50 || [[#SetOutOfFocusApplicationSuspendingEnabled]] ||
 
| 50 || [[#SetOutOfFocusApplicationSuspendingEnabled]] ||
 +
|-
 +
| 60 || [10.0.0+] [[#PresetLibraryAppletGpuTimeSliceZero]] ||
 
|-
 
|-
 
| 100 || [[#PushInData]] ||  
 
| 100 || [[#PushInData]] ||  
Line 1,250: Line 1,425:     
Official sw will assert prior to using this if applet-service was not initialized as *Application.
 
Official sw will assert prior to using this if applet-service was not initialized as *Application.
 +
 +
==== PresetLibraryAppletGpuTimeSliceZero ====
 +
No input/output.
 +
 +
sdknso only uses with with [[Software_Keyboard|swkbd-inline]], immediately after creating the LibraryApplet.
    
==== PushInData ====
 
==== PushInData ====
Line 1,355: Line 1,535:  
|-
 
|-
 
| 66 || [6.0.0+] [[#SetCpuBoostMode]] ||
 
| 66 || [6.0.0+] [[#SetCpuBoostMode]] ||
 +
|-
 +
| 67 || [10.0.0+] [[#CancelCpuBoostMode]] ||
 
|-
 
|-
 
| 80 || [6.0.0+] [[#PerformSystemButtonPressingIfInFocus]] ||
 
| 80 || [6.0.0+] [[#PerformSystemButtonPressingIfInFocus]] ||
Line 1,361: Line 1,543:  
|-
 
|-
 
| 91 || [7.0.0+] [[#GetCurrentPerformanceConfiguration]] ||
 
| 91 || [7.0.0+] [[#GetCurrentPerformanceConfiguration]] ||
 +
|-
 +
| 100 || [9.1.0+] [[#SetHandlingHomeButtonShortPressedEnabled]] ||
 
|-
 
|-
 
| 200 || [7.0.0+] [[#GetOperationModeSystemInfo]] ||
 
| 200 || [7.0.0+] [[#GetOperationModeSystemInfo]] ||
 +
|-
 +
| 300 || [9.0.0+] [[#GetSettingsPlatformRegion]] ||
 +
|-
 +
| 400 || [10.0.0+] [[#ActivateMigrationService]] ||
 +
|-
 +
| 401 || [10.0.0+] [[#DeactivateMigrationService]] ||
 
|}
 
|}
   Line 1,497: Line 1,687:     
=== GetApplicationIdByContentActionName ===
 
=== GetApplicationIdByContentActionName ===
Takes a type-0x5 input buffer containing a string, returns an output u64 titleID.
+
Takes a type-0x5 input buffer containing a string, returns an output [[NCM_services#ApplicationId|ApplicationId]].
   −
Gets the application titleID for the specified ContentActionName string. Returns an error when the current [[#AppletId]] isn't 0x04 (when the current applet isn't a SystemApplication).
+
Gets the ApplicationId for the specified ContentActionName string. Returns an error when the current [[#AppletId]] isn't 0x04 (when the current applet isn't a SystemApplication).
    
=== SetCpuBoostMode ===
 
=== SetCpuBoostMode ===
 
Takes an input u32 '''CpuBoostMode''' (only modes 0 and 1 are valid) and passes it to [[PPC_services#apm:sys|SetCpuBoostMode]].
 
Takes an input u32 '''CpuBoostMode''' (only modes 0 and 1 are valid) and passes it to [[PPC_services#apm:sys|SetCpuBoostMode]].
 +
 +
=== CancelCpuBoostMode ===
 +
No input/output.
    
=== PerformSystemButtonPressingIfInFocus ===
 
=== PerformSystemButtonPressingIfInFocus ===
Line 1,518: Line 1,711:  
No input, returns an output u32.
 
No input, returns an output u32.
   −
This returns the output from omm [[#Cmd26]].
+
This returns the output from [[#GetOperationModeSystemInfo_2|omm GetOperationModeSystemInfo]].
 +
 
 +
=== GetSettingsPlatformRegion ===
 +
No input, returns an output u8.
 +
 
 +
This just returns the output from [[Settings_services#GetPlatformRegion|setsys GetPlatformRegion]].
 +
 
 +
=== ActivateMigrationService ===
 +
No input/output.
 +
 
 +
=== DeactivateMigrationService ===
 +
No input/output.
    
== ISelfController ==
 
== ISelfController ==
Line 1,566: Line 1,770:  
|-
 
|-
 
| 43 || [5.0.0+] [[#GetSystemSharedBufferHandle]]
 
| 43 || [5.0.0+] [[#GetSystemSharedBufferHandle]]
 +
|-
 +
| 44 || [10.0.0+] [[#CreateManagedDisplaySeparableLayer]]
 +
|-
 +
| 45 || [10.0.0+] [[#SetManagedDisplayLayerSeparationMode]]
 
|-
 
|-
 
| 50 || [[#SetHandlesRequestToDisplay]]
 
| 50 || [[#SetHandlesRequestToDisplay]]
Line 1,594: Line 1,802:  
|-
 
|-
 
| 71 || [5.0.0+] [[#GetCurrentIlluminanceEx]]
 
| 71 || [5.0.0+] [[#GetCurrentIlluminanceEx]]
 +
|-
 +
| 72 || [9.0.0+] [[#SetInputDetectionPolicy]]
 
|-
 
|-
 
| 80 || [4.0.0+] [[#SetWirelessPriorityMode]]
 
| 80 || [4.0.0+] [[#SetWirelessPriorityMode]]
Line 1,714: Line 1,924:     
Same as [[#GetSystemSharedLayerHandle]] except this just gets the SharedBufferHandle.
 
Same as [[#GetSystemSharedLayerHandle]] except this just gets the SharedBufferHandle.
 +
 +
=== CreateManagedDisplaySeparableLayer ===
 +
No input, returns two output u64 LayerIds.
 +
 +
sdknso now uses this instead of [[#CreateManagedDisplayLayer]]. sdknso caches the output from the cmd so that it's only used once. The first u64 is used the same as the original LayerId from [[#CreateManagedDisplayLayer]]. <code>nn::vi::CreateRecordingLayer</code> uses the second LayerId, the layer creation is identical besides which LayerId is used.
 +
 +
=== SetManagedDisplayLayerSeparationMode ===
 +
Takes an input u32, no output.
 +
 +
sdknso exposes this as <code>nn::vi::SetRecordingLayerEnabled(bool)</code>.
 +
 +
The input u32 must be 0-1.
    
=== SetHandlesRequestToDisplay ===
 
=== SetHandlesRequestToDisplay ===
Line 1,780: Line 2,002:     
Uses [[Backlight_services|lbl]] command GetAmbientLightSensorValue.
 
Uses [[Backlight_services|lbl]] command GetAmbientLightSensorValue.
 +
 +
=== SetInputDetectionPolicy ===
 +
Takes an input [[#InputDetectionPolicy]], no output.
    
=== SetWirelessPriorityMode ===
 
=== SetWirelessPriorityMode ===
Line 2,189: Line 2,414:  
| 0 || [[#NotifyMessageToHomeMenuForDebug]] ||
 
| 0 || [[#NotifyMessageToHomeMenuForDebug]] ||
 
|-
 
|-
| 1 || [[#OpenMainApplication]] ||  
+
| 1 || [1.0.0-9.2.0] [[#OpenMainApplication]] ||  
 
|-
 
|-
 
| 10 || [[#PerformSystemButtonPressing]] ||
 
| 10 || [[#PerformSystemButtonPressing]] ||
Line 2,200: Line 2,425:  
|-
 
|-
 
| 100 || [7.0.0+] [[#SetCpuBoostModeForApplet]] ||
 
| 100 || [7.0.0+] [[#SetCpuBoostModeForApplet]] ||
 +
|-
 +
| 101 || [10.0.0+] [[#CancelCpuBoostModeForApplet]] ||
 +
|-
 +
| 110 || [9.0.0+] [[#PushToAppletBoundChannelForDebug]] ||
 +
|-
 +
| 111 || [9.0.0+] [[#TryPopFromAppletBoundChannelForDebug]] ||
 +
|-
 +
| 120 || [9.0.0+] [[#AlarmSettingNotificationEnableAppEventReserve]] ||
 +
|-
 +
| 121 || [9.0.0+] [[#AlarmSettingNotificationDisableAppEventReserve]] ||
 +
|-
 +
| 122 || [9.0.0+] [[#AlarmSettingNotificationPushAppEventNotify]] ||
 +
|-
 +
| 130 || [9.0.0+] [[#FriendInvitationSetApplicationParameter]] ||
 +
|-
 +
| 131 || [9.0.0+] [[#FriendInvitationClearApplicationParameter]] ||
 +
|-
 +
| 132 || [9.0.0+] [[#FriendInvitationPushApplicationParameter]] ||
 
|}
 
|}
   Line 2,219: Line 2,462:     
=== RequestLaunchApplicationWithUserAndArgumentForDebug ===
 
=== RequestLaunchApplicationWithUserAndArgumentForDebug ===
Takes an input u8 bool flag, an u64 Application titleID, a type-0x5 input buffer containing an array of u128 userIDs, and a type-0x5 input buffer, no output.
+
Takes an input u8 bool flag, an [[NCM_services#ApplicationId|ApplicationId]], a type-0x5 input buffer containing an array of u128 userIDs, and a type-0x5 input buffer, no output.
    
Requests to launch the specified Application, with the specified users. When the bool flag is true, the content of the second input buffer is used to create a storage which is pushed to the UserChannel for this Application (see [[#LaunchParameterKind]]).
 
Requests to launch the specified Application, with the specified users. When the bool flag is true, the content of the second input buffer is used to create a storage which is pushed to the UserChannel for this Application (see [[#LaunchParameterKind]]).
Line 2,231: Line 2,474:  
The cached value loaded from [[Settings_services#GetDebugModeFlag]] must be 1, otherwise an error is returned.
 
The cached value loaded from [[Settings_services#GetDebugModeFlag]] must be 1, otherwise an error is returned.
   −
== IStorage ==
+
=== CancelCpuBoostModeForApplet ===
{| class="wikitable" border="1"
+
No input/output.
 +
 
 +
=== PushToAppletBoundChannelForDebug ===
 +
Takes an input [[#IStorage]] and a s32, no output.
 +
 
 +
The cached value loaded from [[Settings_services#GetDebugModeFlag]] must be 1, otherwise an error is returned.
 +
 
 +
The s32 must match the value already stored in state when the state value is non-zero, otherwise an error is returned. When the state value is 0, the s32 is written into state. Then the input storage is pushed to the StorageChannel.
 +
 
 +
=== TryPopFromAppletBoundChannelForDebug ===
 +
Takes an input s32, returns an output [[#IStorage]].
 +
 
 +
The cached value loaded from [[Settings_services#GetDebugModeFlag]] must be 1, otherwise an error is returned.
 +
 
 +
The s32 must not be 0 and must match the value previously saved by [[#PushToAppletBoundChannelForDebug]], otherwise errors are returned. Then the output storage is popped from the StorageChannel.
 +
 
 +
=== AlarmSettingNotificationEnableAppEventReserve ===
 +
Takes an input [[#IStorage]] and an [[NCM_services#ApplicationId|ApplicationId]], no output.
 +
 
 +
Clears a StorageChannel, pushes the input storage there, and writes the ApplicationId into state.
 +
 
 +
=== AlarmSettingNotificationDisableAppEventReserve ===
 +
No input/output.
 +
 
 +
Clears the StorageChannel/saved-ApplicationId used by [[#AlarmSettingNotificationEnableAppEventReserve]].
 +
 
 +
=== AlarmSettingNotificationPushAppEventNotify ===
 +
Takes an input [[#IStorage]], no output.
 +
 
 +
Same as [[#PushToNotificationStorageChannel]] except this uses the MainApplication.
 +
 
 +
=== FriendInvitationSetApplicationParameter ===
 +
Takes an input [[#IStorage]] and an [[NCM_services#ApplicationId|ApplicationId]], no output.
 +
 
 +
Clears a StorageChannel, pushes the input storage there, and writes the ApplicationId into state.
 +
 
 +
=== FriendInvitationClearApplicationParameter ===
 +
No input/output.
 +
 
 +
Clears the StorageChannel/saved-ApplicationId used by [[#FriendInvitationSetApplicationParameter]].
 +
 
 +
=== FriendInvitationPushApplicationParameter ===
 +
Takes an input [[#IStorage]], no output.
 +
 
 +
Same as [[#PushToFriendInvitationStorageChannel]] except this uses the MainApplication.
 +
 
 +
== IStorage ==
 +
{| class="wikitable" border="1"
 
|-
 
|-
 
! Cmd || Name || Notes
 
! Cmd || Name || Notes
Line 2,299: Line 2,589:  
|rowspan="2"| 1 || [1.0.0-3.0.2]
 
|rowspan="2"| 1 || [1.0.0-3.0.2]
 
|-
 
|-
| [7.0.0+]
+
| [7.0.0+] IsAutoPowerDownRequested
 
|-
 
|-
 
| 2 || [1.0.0-3.0.2]
 
| 2 || [1.0.0-3.0.2]
 
|-
 
|-
| 3 || SetHandlingContext
+
| 3 || [[#SetHandlingContext]]
 
|-
 
|-
 
| 4 || LoadAndApplySettings
 
| 4 || LoadAndApplySettings
Line 2,310: Line 2,600:  
|}
 
|}
   −
[3.0.0+] SetHandlingContext now takes an additional 0x10-bytes of input.
+
== SetHandlingContext ==
 +
[3.0.0+] Now takes an additional 0x10-bytes of input.
    
= omm =
 
= omm =
Line 2,316: Line 2,607:     
Operation Mode Manager (OMM) is a service responsible for arbitrating the operation changes between docked and handheld modes.
 
Operation Mode Manager (OMM) is a service responsible for arbitrating the operation changes between docked and handheld modes.
Besides [[PTM_services]], this is the only service that interacts with the [[Dock]] through [[USB_services|usb:pd*]].
+
Besides [[PTM_services|PTM]], this is the only service that interacts with the [[Dock]] through [[USB_services|usb:pd*]].
    
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
! Cmd || Name || Notes
+
! Cmd || Name
 +
|-
 +
| 0 || GetOperationMode
 
|-
 
|-
| 0 || GetOperationMode ||  
+
| 1 || GetOperationModeChangeEvent
 
|-
 
|-
| 1 || GetOperationModeChangeEvent ||  
+
| 2 || EnableAudioVisual
 
|-
 
|-
| 2 || EnableAudioVisual ||  
+
| 3 || DisableAudioVisual
 
|-
 
|-
| 3 || DisableAudioVisual ||  
+
| 4 || EnterSleepAndWait
 
|-
 
|-
| 4 || EnterSleepAndWait ||  
+
| 5 || GetCradleStatus
 
|-
 
|-
| 5 || GetCradleStatus ||  
+
| 6 || FadeInDisplay
 
|-
 
|-
| 6 || FadeInDisplay ||  
+
| 7 || FadeOutDisplay
 
|-
 
|-
| 7 || FadeOutDisplay ||  
+
| 8 || [2.0.0+] GetCradleFwVersion
 
|-
 
|-
| 8 || [2.0.0+] GetCradleFwVersion ||
+
| 9 || [2.0.0+] NotifyCecSettingsChanged
 
|-
 
|-
| 9 || [2.0.0+] NotifyCecSettingsChanged ||
+
| 10 || [3.0.0+] SetOperationModePolicy
 
|-
 
|-
| 10 || [3.0.0+] SetOperationModePolicy ||
+
| 11 || [3.0.0+] GetDefaultDisplayResolution
 
|-
 
|-
| 11 || [3.0.0+] GetDefaultDisplayResolution ||
+
| 12 || [3.0.0+] GetDefaultDisplayResolutionChangeEvent
 
|-
 
|-
| 12 || [3.0.0+] GetDefaultDisplayResolutionChangeEvent ||
+
| 13 || [3.0.0+] UpdateDefaultDisplayResolution
 
|-
 
|-
| 13 || [3.0.0+] UpdateDefaultDisplayResolution ||
+
| 14 || [3.0.0+] ShouldSleepOnBoot
 
|-
 
|-
| 14 || [3.0.0+] ShouldSleepOnBoot ||
+
| 15 || [4.0.0+] NotifyHdcpApplicationExecutionStarted
 
|-
 
|-
| 15 || [4.0.0+] NotifyHdcpApplicationExecutionStarted ||
+
| 16 || [4.0.0+] NotifyHdcpApplicationExecutionFinished
 
|-
 
|-
| 16 || [4.0.0+] NotifyHdcpApplicationExecutionFinished ||
+
| 17 || [4.0.0+] NotifyHdcpApplicationDrawingStarted
 
|-
 
|-
| 17 || [4.0.0+] NotifyHdcpApplicationDrawingStarted ||
+
| 18 || [4.0.0+] NotifyHdcpApplicationDrawingFinished
 
|-
 
|-
| 18 || [4.0.0+] NotifyHdcpApplicationDrawingFinished ||
+
| 19 || [4.0.0+] GetHdcpAuthenticationFailedEvent
 
|-
 
|-
| 19 || [4.0.0+] GetHdcpAuthenticationFailedEvent ||
+
| 20 || [4.0.0+] GetHdcpAuthenticationFailedEmulationEnabled
 
|-
 
|-
| 20 || [4.0.0+] GetHdcpAuthenticationFailedEmulationEnabled ||
+
| 21 || [4.0.0+] SetHdcpAuthenticationFailedEmulation
 
|-
 
|-
| 21 || [4.0.0+] SetHdcpAuthenticationFailedEmulation ||
+
| 22 || [4.0.0+] GetHdcpStateChangeEvent
 
|-
 
|-
| 22 || [4.0.0+] GetHdcpStateChangeEvent ||
+
| 23 || [4.0.0+] GetHdcpState
 
|-
 
|-
| 23 || [4.0.0+] GetHdcpState ||
+
| 24 || [5.0.0+] ShowCardUpdateProcessing
 
|-
 
|-
| 24 || [5.0.0+] ShowCardUpdateProcessing ||
+
| 25 || [5.0.0+] SetApplicationCecSettingsAndNotifyChanged
 
|-
 
|-
| 25 || [5.0.0+] SetApplicationCecSettingsAndNotifyChanged ||
+
| 26 || [7.0.0+] [[#GetOperationModeSystemInfo]]
 
|-
 
|-
| 26 || [7.0.0+] ||
+
| 27 || [9.0.0+] GetAppletFullAwakingSystemEvent
 
|}
 
|}
   −
== Cmd26 ==
+
== GetOperationModeSystemInfo ==
 
No input, returns an output u32.
 
No input, returns an output u32.
   −
This is used by [[#GetOperationModeSystemInfo]].
+
This is used by [[#GetOperationModeSystemInfo|ICommonStateGetter GetOperationModeSystemInfo]].
    
= spsm =
 
= spsm =
Line 2,389: Line 2,682:  
! Cmd || Name
 
! Cmd || Name
 
|-
 
|-
| 0 || GetState
+
| 0 || GetCurrentState
 
|-
 
|-
| 1 || SleepSystemAndWaitAwake
+
| 1 || EnterSleep
 
|-
 
|-
| 2 ||  
+
| 2 || GetLastWakeReason
 
|-
 
|-
| 3 ||  
+
| 3 || Shutdown
 
|-
 
|-
 
| 4 || GetNotificationMessageEventHandle
 
| 4 || GetNotificationMessageEventHandle
 
|-
 
|-
| 5 ||  
+
| 5 || ReceiveNotificationMessage
 
|-
 
|-
| 6 ||  
+
| 6 || AnalyzeLogForLastSleepWakeSequence
 
|-
 
|-
| 7 ||  
+
| 7 || ResetEventLog
 
|-
 
|-
 
| 8 || AnalyzePerformanceLogForLastSleepWakeSequence
 
| 8 || AnalyzePerformanceLogForLastSleepWakeSequence
Line 2,409: Line 2,702:  
| 9 || ChangeHomeButtonLongPressingTime
 
| 9 || ChangeHomeButtonLongPressingTime
 
|-
 
|-
| 10 ||  
+
| 10 || PutErrorState
 
|-
 
|-
| 11 || [1.0.0-3.0.2]
+
| 11 || [1.0.0-3.0.2] InvalidateCurrentHomeButtonPressing
 
|}
 
|}
   Line 2,455: Line 2,748:     
== SaveScreenShot ==
 
== SaveScreenShot ==
Takes two input u32s, an u64 AppletResourceUserId, a PID, and a type-0x45 input buffer. Returns a 0x20-byte struct '''ApplicationAlbumEntry'''.
+
Takes two input u32s, an u64 AppletResourceUserId, a PID, and a type-0x45 input buffer containing image data. Returns an [[Capture_services|ApplicationAlbumEntry]].
 +
 
 +
Official user-processes doesn't use this, instead [[#SaveScreenShotEx0]] is used: ScreenShotAttributeEx0 is all-zero, except +4 is set to an input u32 and u32 +0xC = 0x1.
   −
Official user-processes doesn't use this, instead [[#SaveScreenShotEx0]] is used: ScreenShotAttributeEx0 is all-zero except +0 is set to an input u32.
+
This cmd internally uses an all-zero ScreenShotAttributeEx0, with u32 +0 = input u32 and u32 +0x8 = 0x3.
    
== SaveScreenShotEx0 ==
 
== SaveScreenShotEx0 ==
Takes an input 0x40-byte struct '''ScreenShotAttributeEx0''', an input u32, an input u64 AppletResourceUserId, a PID, and a type-0x45 input buffer. Returns a 0x20-byte struct '''ApplicationAlbumEntry'''.
+
Takes an input 0x40-byte struct '''ScreenShotAttributeEx0''', an input u32, an input u64 AppletResourceUserId, a PID, and a type-0x45 input buffer containing image data. Returns an [[Capture_services|ApplicationAlbumEntry]].
 +
 
 +
== SaveScreenShotEx1 ==
 +
Takes an input 0x40-byte struct '''ScreenShotAttributeEx0''', an input u32, an input u64 AppletResourceUserId, a PID, a type-0x15 input buffer containing an [[Capture_services|ApplicationData]], and a type-0x45 input buffer containing image data. Returns an [[Capture_services|ApplicationAlbumEntry]].
 +
 
 +
== SaveScreenShotEx2 ==
 +
Takes an input 0x40-byte struct '''ScreenShotAttributeEx0''', an input u32, an input u64 AppletResourceUserId, a type-0x15 input buffer containing an [[Capture_services|UserIdList]], and a type-0x45 input buffer containing image data. Returns an [[Capture_services|ApplicationAlbumEntry]].
    
= Library Applets =
 
= Library Applets =
Line 2,500: Line 2,801:  
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
! ID
+
! Id
! Title-id
+
! ProgramId
! Description
+
! Description
 
|-
 
|-
 
| 0x01
 
| 0x01
 
|  
 
|  
| Application. Not valid for use with LibraryApplets.
+
| Application (not valid for use with LibraryApplets)
 
|-
 
|-
 
| 0x02
 
| 0x02
 
| 010000000000100C
 
| 010000000000100C
| "overlayDisp"
+
| overlayDisp (OverlayApplet)
 
|-
 
|-
 
| 0x03
 
| 0x03
 
| 0100000000001000
 
| 0100000000001000
| "qlaunch"
+
| qlaunch (SystemAppletMenu)
 
|-
 
|-
 
| 0x04
 
| 0x04
 
| 0100000000001012
 
| 0100000000001012
| "starter" SystemApplication.
+
| starter (DummyStarter)
 
|-
 
|-
 
| 0x0A
 
| 0x0A
 
| 0100000000001001
 
| 0100000000001001
| [[Auth_Applet|"auth"]]
+
| [[Auth_Applet|auth (LibraryAppletAuth)]]
 
|-
 
|-
 
| 0x0B
 
| 0x0B
 
| 0100000000001002
 
| 0100000000001002
| "cabinet"
+
| [[Cabinet_Applet|cabinet (LibraryAppletCabinet)]]
 
|-
 
|-
 
| 0x0C
 
| 0x0C
 
| 0100000000001003
 
| 0100000000001003
| "controller"
+
| [[Controller_Applet|controller (LibraryAppletController)]]
 
|-
 
|-
 
| 0x0D
 
| 0x0D
 
| 0100000000001004
 
| 0100000000001004
| "dataErase"
+
| dataErase (LibraryAppletDataErase)
 
|-
 
|-
 
| 0x0E
 
| 0x0E
 
| 0100000000001005
 
| 0100000000001005
| [[Error_Applet|"error"]]
+
| [[Error_Applet|error (LibraryAppletError)]]
 
|-
 
|-
 
| 0x0F
 
| 0x0F
 
| 0100000000001006
 
| 0100000000001006
| "netConnect"
+
| netConnect (LibraryAppletNetConnect)
 
|-
 
|-
 
| 0x10
 
| 0x10
 
| 0100000000001007
 
| 0100000000001007
| [[Profile_Selector|"playerSelect"]]
+
| [[Profile_Selector|playerSelect (LibraryAppletPlayerSelect)]]
 
|-
 
|-
 
| 0x11
 
| 0x11
 
| 0100000000001008
 
| 0100000000001008
| [[Software_Keyboard|"swkbd"]]
+
| [[Software_Keyboard|swkbd (LibraryAppletSwkbd)]]
 
|-
 
|-
 
| 0x12
 
| 0x12
 
| 0100000000001009
 
| 0100000000001009
| "miiEdit"
+
| [[MiiEdit_Applet|miiEdit (LibraryAppletMiiEdit)]]
 
|-
 
|-
 
| 0x13
 
| 0x13
 
| 010000000000100A
 
| 010000000000100A
| "LibAppletWeb" [[Internet_Browser#010000000000100A|WebApplet]] applet
+
| [[Internet_Browser#010000000000100A|web (LibraryAppletWeb)]]
 
|-
 
|-
 
| 0x14
 
| 0x14
 
| 010000000000100B
 
| 010000000000100B
| "LibAppletShop" [[Internet_Browser#ShopN|ShopN]] applet
+
| [[Internet_Browser#ShopN|shop (LibraryAppletShop)]]
 
|-
 
|-
 
| 0x15
 
| 0x15
 
| 010000000000100D
 
| 010000000000100D
| "photoViewer"
+
| [[Album_Applet|photoViewer (LibraryAppletPhotoViewer)]]
 
|-
 
|-
 
| 0x16
 
| 0x16
 
| 010000000000100E
 
| 010000000000100E
| "set"
+
| set (LibraryAppletSet)
 
|-
 
|-
 
| 0x17
 
| 0x17
 
| 010000000000100F
 
| 010000000000100F
| "LibAppletOff" [[Internet_Browser#Offline_Applet|Offline]] applet
+
| [[Internet_Browser#Offline_Applet|offlineWeb (LibraryAppletOfflineWeb)]]
 
|-
 
|-
 
| 0x18
 
| 0x18
 
| 0100000000001010
 
| 0100000000001010
| "LibAppletLns" [[Internet_Browser#Whitelisted_Applets|Whitelisted]] applet
+
| [[Internet_Browser#Whitelisted_Applets|loginShare (LibraryAppletLoginShare)]]
 
|-
 
|-
 
| 0x19
 
| 0x19
 
| 0100000000001011
 
| 0100000000001011
| "LibAppletAuth" [[Internet_Browser#WifiWebAuthApplet|WifiWebAuth]] applet
+
| [[Internet_Browser#WifiWebAuthApplet|wifiWebAuth (LibraryAppletWifiWebAuth)]]
 
|-
 
|-
 
| 0x1A
 
| 0x1A
 
| 0100000000001013
 
| 0100000000001013
| "myPage"
+
| [[MyPage_Applet|myPage (LibraryAppletMyPage)]]
 +
|-
 +
| 0x1B
 +
| 010000000000101A
 +
| gift (LibraryAppletGift)
 +
|-
 +
| 0x1C
 +
| 010000000000101C
 +
| userMigration (LibraryAppletUserMigration)
 +
|-
 +
| 0x1D
 +
| 010000000000101D
 +
| [9.0.0+] EncounterSys (LibraryAppletPreomiaSys)
 +
|-
 +
| 0x1E
 +
| 0100000000001020
 +
| [9.0.0+] story (LibraryAppletStory)
 +
|-
 +
| 0x1F
 +
| 010070000E3C0000
 +
| [9.0.0+] EncounterUsr (LibraryAppletPreomiaUsr)
 +
|-
 +
| 0x20
 +
| 010086000E49C000
 +
| [9.0.0+] EncounterUsrDummy (LibraryAppletPreomiaUsrDummy)
 +
|-
 +
| 0x21
 +
| 0100000000001038
 +
| [10.0.0+] sample (LibraryAppletSample)
 +
|-
 +
| 0x3F1
 +
| 010000000000D619
 +
| [10.0.0+]
 +
|-
 +
| 0x3F2
 +
| 010000000000D610
 +
| [10.0.0+]
 +
|-
 +
| 0x3F3
 +
| 010000000000D611
 +
| [10.0.0+]
 +
|-
 +
| 0x3F4
 +
| 010000000000D612
 +
| [10.0.0+]
 +
|-
 +
| 0x3F5
 +
| 010000000000D613
 +
| [10.0.0+]
 +
|-
 +
| 0x3F6
 +
| 010000000000D614
 +
| [10.0.0+]
 +
|-
 +
| 0x3F7
 +
| 010000000000D615
 +
| [10.0.0+]
 +
|-
 +
| 0x3F8
 +
| 010000000000D616
 +
| [10.0.0+]
 +
|-
 +
| 0x3F9
 +
| 010000000000D617
 +
| [10.0.0+]
 +
|-
 +
| 0x3FA
 +
| 010000000000D60A
 +
| [10.0.0+]
 +
|-
 +
| 0x3FB
 +
| 010000000000D60B
 +
| [10.0.0+]
 +
|-
 +
| 0x3FC
 +
| 010000000000D60C
 +
| [10.0.0+]
 +
|-
 +
| 0x3FD
 +
| 010000000000D60D
 +
| [10.0.0+]
 +
|-
 +
| 0x3FE
 +
| 010000000000D60E
 +
| [10.0.0+]
 
|}
 
|}
   Line 2,718: Line 3,103:  
!  Description
 
!  Description
 
|-
 
|-
| 0 || u8 ProgramIndex. "ExecuteProgram". [[NS_Services|NS]] handles ProgramIndex by launching titleID {application_titleID}+ProgramIndex. After using [[#ExecuteProgram]] with this successfully, official user-processes will enter an infinite loop with sleep-thread value 86400000000000.
+
| 0 || u8 ProgramIndex. "ExecuteProgram". [[NS_Services|NS]] handles ProgramIndex by launching ApplicationId+ProgramIndex. After using [[#ExecuteProgram]] with this successfully, official user-processes will enter an infinite loop with sleep-thread value 86400000000000.
 
|-
 
|-
| 1 || u64 titleID. "JumpToSubApplicationProgramForDevelopment". Only available when [[Settings_services#GetDebugModeFlag|DebugMode]] is 1.
+
| 1 || [[NCM_services#ApplicationId|ApplicationId]]. "JumpToSubApplicationProgramForDevelopment". Only available when [[Settings_services#GetDebugModeFlag|DebugMode]] is 1.
 
|-
 
|-
 
| 2 || u64 = value 0. "RestartProgram"
 
| 2 || u64 = value 0. "RestartProgram"
Line 2,727: Line 3,112:     
This is "nn::am::service::ProgramSpecifyKind". This controls the type of the u64 passed to [[#ExecuteProgram]].
 
This is "nn::am::service::ProgramSpecifyKind". This controls the type of the u64 passed to [[#ExecuteProgram]].
 +
 +
ProgramIndex values where the title is not installed should not be used: [[qlaunch]] will display an error message and the current title will become "corrupted", however Home Menu will have an option to repair it.
 +
 +
= InputDetectionPolicy =
 +
{| class="wikitable" border="1"
 +
|-
 +
!  Value
 +
!  Description
 +
|-
 +
| 0 || Unknown.
 +
|-
 +
| 1 || Unknown.
 +
|}
 +
 +
This is u32 enum "nn::applet::InputDetectionPolicy".
    
= AppletResourceUserId =
 
= AppletResourceUserId =
Line 2,783: Line 3,183:  
| 0x4 || 0x4 || Padding
 
| 0x4 || 0x4 || Padding
 
|-
 
|-
| 0x8 || 0x8 || titleID
+
| 0x8 || 0x8 || [[NCM_services#ApplicationId|ApplicationId]]
 
|}
 
|}
   Line 2,827: Line 3,227:  
! Offset || Size || Description
 
! Offset || Size || Description
 
|-
 
|-
| 0x0 || 0x8 || Application titleID.
+
| 0x0 || 0x8 || [[NCM_services#ApplicationId|ApplicationId]]
 
|-
 
|-
 
| 0x8 || 0x4 || Application title-version.
 
| 0x8 || 0x4 || Application title-version.
Line 2,871: Line 3,271:     
This struct is "nn::am::service::AppletResourceUsageInfo". This struct is 0x20-bytes.
 
This struct is "nn::am::service::AppletResourceUsageInfo". This struct is 0x20-bytes.
 +
 +
= ApplicationLicenseType =
 +
This is "nn::oe::ApplicationLicenseType". This is 1-byte.
 +
 +
= LaunchRequiredVersion =
 +
This is "nn::oe::LaunchRequiredVersion". This is a 0x40-byte struct with 1-byte alignment.
    
= Notes =
 
= Notes =

Navigation menu