1
0
Fork 0
mirror of https://github.com/suchmememanyskill/TegraExplorer.git synced 2024-11-22 11:56:42 +00:00

Fix compiling issues (hopefully)

This commit is contained in:
Such Meme, Many Skill 2020-05-10 21:51:30 +02:00
parent b484dc11d8
commit 91536268ad
14 changed files with 30 additions and 33 deletions

View file

@ -20,6 +20,9 @@
#include <string.h> #include <string.h>
#include "gfx.h" #include "gfx.h"
gfx_ctxt_t gfx_ctxt;
gfx_con_t gfx_con;
static const u8 _gfx_font[] = { static const u8 _gfx_font[] = {
0x00, 0x0C, 0x12, 0x7E, 0x42, 0x42, 0x7E, 0x00, // Char 030 (folder) 0x00, 0x0C, 0x12, 0x7E, 0x42, 0x42, 0x7E, 0x00, // Char 030 (folder)
0x00, 0x0E, 0x12, 0x22, 0x22, 0x22, 0x3E, 0x00, // Char 031 (file) 0x00, 0x0E, 0x12, 0x22, 0x22, 0x22, 0x3E, 0x00, // Char 031 (file)

View file

@ -61,7 +61,7 @@ void gfx_boxGrey(int x0, int y0, int x1, int y1, u8 shade);
*/ */
// Global gfx console and context. // Global gfx console and context.
gfx_ctxt_t gfx_ctxt; extern gfx_ctxt_t gfx_ctxt;
gfx_con_t gfx_con; extern gfx_con_t gfx_con;
#endif #endif

View file

@ -31,6 +31,10 @@
#define DEBUG_PRINTING*/ #define DEBUG_PRINTING*/
#define DPRINTF(...) #define DPRINTF(...)
u32 pkg2_newkern_ini1_val;
u32 pkg2_newkern_ini1_start;
u32 pkg2_newkern_ini1_end;
static u32 _pkg2_calc_kip1_size(pkg2_kip1_t *kip1) static u32 _pkg2_calc_kip1_size(pkg2_kip1_t *kip1)
{ {
u32 size = sizeof(pkg2_kip1_t); u32 size = sizeof(pkg2_kip1_t);

View file

@ -28,9 +28,9 @@
#define PKG2_NEWKERN_GET_INI1_HEURISTIC 0xD2800015 // Offset of OP + 12 is the INI1 offset. #define PKG2_NEWKERN_GET_INI1_HEURISTIC 0xD2800015 // Offset of OP + 12 is the INI1 offset.
u32 pkg2_newkern_ini1_val; extern u32 pkg2_newkern_ini1_val;
u32 pkg2_newkern_ini1_start; extern u32 pkg2_newkern_ini1_start;
u32 pkg2_newkern_ini1_end; extern u32 pkg2_newkern_ini1_end;
typedef struct _pkg2_hdr_t typedef struct _pkg2_hdr_t
{ {

View file

@ -44,10 +44,10 @@
//#include "keys/keys.h" //#include "keys/keys.h"
sdmmc_t sd_sdmmc; //sdmmc_t sd_sdmmc;
sdmmc_storage_t sd_storage; //sdmmc_storage_t sd_storage;
__attribute__ ((aligned (16))) FATFS sd_fs; //__attribute__ ((aligned (16))) FATFS sd_fs;
bool sd_mounted, sd_inited; //bool sd_mounted, sd_inited;
volatile nyx_storage_t *nyx_str = (nyx_storage_t *)NYX_STORAGE_ADDR; volatile nyx_storage_t *nyx_str = (nyx_storage_t *)NYX_STORAGE_ADDR;
hekate_config h_cfg; hekate_config h_cfg;
boot_cfg_t __attribute__((section ("._boot_cfg"))) b_cfg; boot_cfg_t __attribute__((section ("._boot_cfg"))) b_cfg;

View file

@ -27,6 +27,7 @@
#include "../soc/t210.h" #include "../soc/t210.h"
extern volatile nyx_storage_t *nyx_str; extern volatile nyx_storage_t *nyx_str;
void (*minerva_cfg)(mtc_config_t *mtc_cfg, void *);
u32 minerva_init() u32 minerva_init()
{ {

View file

@ -57,7 +57,7 @@ typedef enum
FREQ_1600 = 1600000 FREQ_1600 = 1600000
} minerva_freq_t; } minerva_freq_t;
void (*minerva_cfg)(mtc_config_t *mtc_cfg, void *); extern void (*minerva_cfg)(mtc_config_t *mtc_cfg, void *);
u32 minerva_init(); u32 minerva_init();
void minerva_change_freq(minerva_freq_t freq); void minerva_change_freq(minerva_freq_t freq);
void minerva_periodic_training(); void minerva_periodic_training();

View file

@ -32,6 +32,7 @@ extern sdmmc_storage_t sd_storage;
extern FATFS sd_fs; extern FATFS sd_fs;
extern hekate_config h_cfg; extern hekate_config h_cfg;
emummc_cfg_t emu_cfg;
extern bool sd_mount(); extern bool sd_mount();
extern void sd_unmount(); extern void sd_unmount();

View file

@ -47,7 +47,7 @@ typedef struct _emummc_cfg_t
int fs_ver; int fs_ver;
} emummc_cfg_t; } emummc_cfg_t;
emummc_cfg_t emu_cfg; extern emummc_cfg_t emu_cfg;
bool emummc_load_cfg(); bool emummc_load_cfg();
int emummc_storage_init_mmc(sdmmc_storage_t *storage, sdmmc_t *sdmmc); int emummc_storage_init_mmc(sdmmc_storage_t *storage, sdmmc_t *sdmmc);

View file

@ -25,6 +25,10 @@
bool sd_mounted = false, sd_inited = false; bool sd_mounted = false, sd_inited = false;
static u32 sd_mode = SD_UHS_SDR82; static u32 sd_mode = SD_UHS_SDR82;
sdmmc_t sd_sdmmc;
sdmmc_storage_t sd_storage;
FATFS sd_fs;
u32 sd_get_mode() u32 sd_get_mode()
{ {
return sd_mode; return sd_mode;

View file

@ -30,9 +30,9 @@ enum
SD_UHS_SDR82 = 3, SD_UHS_SDR82 = 3,
}; };
sdmmc_t sd_sdmmc; extern sdmmc_t sd_sdmmc;
sdmmc_storage_t sd_storage; extern sdmmc_storage_t sd_storage;
FATFS sd_fs; extern FATFS sd_fs;
u32 sd_get_mode(); u32 sd_get_mode();
int sd_init_retry(bool power_cycle); int sd_init_retry(bool power_cycle);

View file

@ -21,7 +21,7 @@
#include "../utils/types.h" #include "../utils/types.h"
#include "sdmmc_driver.h" #include "sdmmc_driver.h"
u32 sd_power_cycle_time_start; extern u32 sd_power_cycle_time_start;
typedef enum _sdmmc_type typedef enum _sdmmc_type
{ {

View file

@ -32,6 +32,8 @@
#pragma GCC push_options #pragma GCC push_options
#pragma GCC optimize ("Os") #pragma GCC optimize ("Os")
u32 sd_power_cycle_time_start;
//#define DPRINTF(...) gfx_printf(__VA_ARGS__) //#define DPRINTF(...) gfx_printf(__VA_ARGS__)
#define DPRINTF(...) #define DPRINTF(...)

View file

@ -198,24 +198,6 @@ int menu_make(menu_entry *entries, int amount, const char *toptext){
else { else {
break; break;
} }
/*
if (delay < 300){
scrolltimer = get_tmr_ms();
while (input->buttons & (KEY_A | KEY_LDOWN | KEY_LUP | KEY_B | KEY_RUP | KEY_RDOWN)){
if (scrolltimer + delay <= get_tmr_ms())
break;
input = hidRead();
}
}
if (delay > 46 && input->buttons & (KEY_A | KEY_LDOWN | KEY_LUP | KEY_B | KEY_RUP | KEY_RDOWN))
delay -= 45;
if (input->buttons & (KEY_RUP | KEY_RDOWN))
delay = 1;
*/
} }
if (delay > 46) if (delay > 46)