libctr9
Nintendo 3DS ARM9 library
ctr_system.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright (C) 2016 Gabriel Marcano
3  *
4  * Refer to the COPYING.txt file at the top of the project directory. If that is
5  * missing, this file is licensed under the GPL version 2.0 or later.
6  *
7  ******************************************************************************/
8 
11 #ifndef CTR_SYSTEM_H_
12 #define CTR_SYSTEM_H_
13 
14 #include <stdbool.h>
15 
16 #ifdef __cplusplus
17 extern "C" {
18 #endif
19 
22 typedef enum
23 {
24  SYSTEM_O3DS,
25  SYSTEM_N3DS,
27 
32 bool ctr_detect_a9lh_entry(void);
33 
41 void ctr_twl_keyslot_setup(void);
42 
50 void ctr_system_poweroff(void);
51 
58 void ctr_system_reset(void);
59 
64 ctr_system_type ctr_get_system_type(void);
65 
71 void ctr_flush_cache(void);
72 
73 #ifdef __cplusplus
74 }
75 #endif
76 
77 #endif//CTR_SYSTEM_H_
78 
ctr_system_type ctr_get_system_type(void)
Returns the enumeration corresponding to the running system.
void ctr_twl_keyslot_setup(void)
Sets up the TWL keyslot.
ctr_system_type
Enumeration describing the running system.
Definition: ctr_system.h:22
void ctr_flush_cache(void)
Flushes all of the ARM9 CPU caches, and drains the write buffer.
bool ctr_detect_a9lh_entry(void)
Returns whether the arm9 entry was a9lh or not.
void ctr_system_poweroff(void)
Powers off the 3DS.
void ctr_system_reset(void)
Resets the 3DS.