libctru  v1.6.0
Functions
ns.h File Reference

NS (Nintendo Shell) service. More...

Go to the source code of this file.

Functions

Result nsInit (void)
 Initializes NS.
 
void nsExit (void)
 Exits NS.
 
Result NS_LaunchFIRM (u64 titleid)
 Launches a title and the required firmware (only if necessary). More...
 
Result NS_LaunchTitle (u64 titleid, u32 launch_flags, u32 *procid)
 Launches a title. More...
 
Result NS_TerminateTitle (void)
 Terminates the application from which this function is called.
 
Result NS_LaunchApplicationFIRM (u64 titleid, u32 flags)
 Launches a title and the required firmware. More...
 
Result NS_RebootToTitle (u8 mediatype, u64 titleid)
 Reboots to a title. More...
 
Result NS_TerminateProcessTID (u64 titleid, u64 timeout)
 Terminates the process with the specified titleid. More...
 
Result NS_RebootSystem (void)
 Reboots the system.
 

Detailed Description

NS (Nintendo Shell) service.

Function Documentation

◆ NS_LaunchApplicationFIRM()

Result NS_LaunchApplicationFIRM ( u64  titleid,
u32  flags 
)

Launches a title and the required firmware.

Parameters
titleidID of the title to launch, 0 for gamecard.
flagsFlags for firm-launch. bit0: require an application title-info structure in FIRM paramters to be specified via FIRM parameters. bit1: if clear, NS will check certain Configuration Memory fields.

◆ NS_LaunchFIRM()

Result NS_LaunchFIRM ( u64  titleid)

Launches a title and the required firmware (only if necessary).

Parameters
titleidID of the title to launch, 0 for gamecard, JPN System Settings' titleID for System Settings.

◆ NS_LaunchTitle()

Result NS_LaunchTitle ( u64  titleid,
u32  launch_flags,
u32 procid 
)

Launches a title.

Parameters
titleidID of the title to launch, or 0 for gamecard.
launch_flagsFlags used when launching the title.
procidPointer to write the process ID of the launched title to.

◆ NS_RebootToTitle()

Result NS_RebootToTitle ( u8  mediatype,
u64  titleid 
)

Reboots to a title.

Parameters
mediatypeMediatype of the title.
titleidID of the title to launch.

◆ NS_TerminateProcessTID()

Result NS_TerminateProcessTID ( u64  titleid,
u64  timeout 
)

Terminates the process with the specified titleid.

Parameters
titleidID of the title to terminate.
timeoutTimeout in nanoseconds. Pass 0 if not required.