Commit Graph

43 Commits

Author SHA1 Message Date
Oreo639
0109837270 Fix blocking and add aptIsHomePressed 2019-04-24 17:12:29 -07:00
LiquidFenrir
f76df85633 Allow blocking HOME button
Signed-off-by: Alex Taber <alexftaber@gmail.com>
2019-04-23 19:17:05 -07:00
fincs
1ed97e8ba2 Implement RUNFLAG_APTCHAINLOAD 2017-04-14 22:01:13 +02:00
Jeffrey Pfau
635d3e6640 Add APT:ReceiveDeliverArg 2016-12-29 19:28:59 +01:00
fincs
15e24d19a5 Major APT rewrite, see details:
- Internal logic changes in order to follow official behavior
  more closely - the APT state machine has been removed.
- The following functions were removed:
  * aptSetStatus/aptGetStatus along with the APT_AppStatus enum
  * aptGetStatusPower/aptSetStatusPower
  * aptReturnToMenu
  * aptWaitStatusEvent, aptSignalReadyForSleep
- Library applet launching is now fully supported on both official
  environments (ncch/cia) and homebrew environments (3dsx).
  APT_LaunchLibraryApplet has been replaced with aptLaunchLibraryApplet.
- Added aptSetMessageCallback (intended for use with libapplet code)
- Added APT_CancelParameter
- Some other misc changes
2016-07-02 00:57:06 +02:00
fincs
14cdb5a9d3 Begin refactoring APT code, many changes to make code a bit more manageable 2016-06-11 19:48:05 +02:00
fincs
56a11197c7 () -> (void) 2016-06-10 18:14:30 +02:00
Steven Smith
c81239a407 Allow toggling sleep mode. 2016-05-08 12:45:18 -07:00
fincs
8b5e753235 Add shared system font parsing code. 2016-01-19 19:23:58 +01:00
Steven Smith
13a5a225b3 Reference count srv, cleanup launcher code. 2015-11-15 13:02:06 -08:00
Steven Smith
375fbce98a Service cleanup. 2015-11-11 08:57:54 -08:00
Lectem
13adb6a1c2 fixed enums for c++ 2015-10-07 16:00:19 -04:00
Steven Smith
fa5f3783ce Finish up basic documentation. 2015-10-05 18:35:15 -07:00
Steven Smith
173d386795 Document most of services. 2015-10-04 22:27:43 -07:00
Steven Smith
9a3baad7ed Rewrite most documentation to be consistent in format. 2015-10-04 10:37:28 -07:00
Lectem
bc3ef580b2 Use IPC helpers for apt, and update some commands 2015-10-03 06:56:11 -04:00
fincs
8912773f21 Merge branch 'master' into great-refactor
Conflicts:
	libctru/include/3ds/services/apt.h
	libctru/include/3ds/services/fs.h
	libctru/source/services/apt.c
2015-10-03 12:39:09 +02:00
suloku
2dc74a81ab Update apt.h 2015-10-01 17:18:17 +02:00
fincs
4603b972fa Merge branch 'master' into great-refactor
Conflicts:
	libctru/include/3ds/services/apt.h
	libctru/source/services/apt.c
2015-09-29 23:21:45 +02:00
smea
56b56955c0 Update apt.h 2015-09-27 21:35:55 -07:00
smea
520332e49e Update apt.h 2015-09-27 21:34:47 -07:00
megazig
27b5a49c59 implement APT_GetAppletInfo 2015-09-27 23:30:16 -05:00
fincs
649e95cd39 Merge branch 'master' into great-refactor
Conflicts:
	libctru/include/3ds/services/apt.h
	libctru/source/services/apt.c
2015-09-25 16:16:10 +02:00
yellows8
31b724a431 Added APT_GetAppletProgramInfo. 2015-09-24 04:26:48 -04:00
fincs
428a837224 Merge branch 'master' into great-refactor 2015-09-08 20:54:37 +02:00
megazig
6d1f409dfd added new NS_APPID values for latest apt module 2015-09-08 12:02:45 -05:00
fincs
9b1e6bfc39 Remove service handle parameter from APT IPC wrappers 2015-09-06 17:41:47 +02:00
fincs
a7aba7feae (I forgot to update the comment in the header file) 2015-06-20 18:21:06 +02:00
Steven Smith
40d0739ade Update NS_APPID values. 2015-05-23 10:57:40 -07:00
fincs
da680e0503 Add APT event hooking mechanism 2015-05-22 21:56:47 +02:00
fincs
350cb955b2 Added RUNFLAG_APTREINIT for supporting environments that require APT reinitialization 2015-05-06 22:01:40 +02:00
profi200
1a6bdc38a9 Implemented functions to start system applets. 2015-03-07 22:10:18 +01:00
yellows8
56b1c2755c Added note about broken applet process termination with APT_LaunchLibraryApplet(). 2014-11-28 01:26:20 -05:00
yellows8
7281abfcd7 Added code for APT_IsRegistered. Added code for launching library applets, which isn't usable from the homebrew launcher atm. 2014-11-21 00:35:37 -05:00
smea
99a5c4406b added APT_HardwareResetAsync (tested) 2014-11-19 17:25:40 -08:00
profi200
16ce5f4c7b Added functions for launching other apps/applets 2014-11-10 17:03:41 +01:00
fincs
7f10ad4097 Add aptMainLoop() for handling APT events in main() 2014-11-02 18:58:37 +01:00
yellows8
3135d1c344 Updated APT_CheckNew3DS to only use the APT cmds once(which also now calls aptOpenSession/aptCloseSession), then store the output value in a flag which is then used for all future APT_CheckNew3DS calls. Updated HID init/shutdown code to automatically call irrst init/shutdown code when running on new3ds. Updated irrst init code to only do init when it wasn't already initialized, likewise for the irrst shutdown code. 2014-11-01 23:48:35 -04:00
yellows8
c8795b1b79 Added APT CheckNew3DS code. Added code for attempting to use the other APT services when APT:U isn't accessible. 2014-11-01 21:39:18 -04:00
StapleButter
afd2140cb7 Create APT event handler thread as soon as possible, and complete initialization automatically when needed. No more 'call aptSetupEventHandler() as late as possible' shit.
Adapt examples to the changes (not tested).
2014-10-27 15:37:30 +01:00
StapleButter
1f413a7d44 Add synchronization mechanism for entering sleep mode.
When the APT status is APP_PREPARE_SLEEPMODE, the application main thread should call aptSignalReadyForSleep() to signal that it is ready to enter sleep mode, and then call aptWaitStatusEvent() as usual.

Example code:

APP_STATUS status;
while ((status = aptGetStatus()) != APP_EXITING)
{
	if(status==APP_RUNNING)
	{
		// application logic here
	}
	else if(status == APP_SUSPENDING)
	{
		aptReturnToMenu();
	}
	else if(status == APP_PREPARE_SLEEPMODE)
	{
		aptSignalReadyForSleep();
		aptWaitStatusEvent();
	}
}

This maybe isn't the proper/recommended way to do sleep mode, but I tested it multiple times and it always worked reliably.

(note: maybe the sample code above will not work if GPU drawing is done in a separate thread, haven't tested that)
2014-09-18 22:09:15 +02:00
profi200
3d34e123ee Added functions for sysCore usage 2014-09-01 15:49:32 +02:00
fincs
9b370c7eff Reorganize includes 2014-08-26 23:18:14 +02:00