Create BIOS Info Overlay
This commit is contained in:
parent
1ae51f9aa4
commit
a8fafdc32e
|
@ -1,5 +1,8 @@
|
||||||
{
|
{
|
||||||
"slot_0": {
|
"slot_0": {
|
||||||
|
"bios_info": {
|
||||||
|
"pattern": "bin/*/src/Overlay/BIOSInfo/*.o"
|
||||||
|
},
|
||||||
"controller_tests": {
|
"controller_tests": {
|
||||||
"pattern": "bin/*/src/Overlay/ControllerTest/*.o"
|
"pattern": "bin/*/src/Overlay/ControllerTest/*.o"
|
||||||
},
|
},
|
||||||
|
|
|
@ -20,6 +20,7 @@ namespace Assets {
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace Overlay {
|
namespace Overlay {
|
||||||
|
void load_bios_info();
|
||||||
void load_controller_test();
|
void load_controller_test();
|
||||||
void load_gpu_test();
|
void load_gpu_test();
|
||||||
void load_gte_test();
|
void load_gte_test();
|
||||||
|
|
|
@ -0,0 +1,38 @@
|
||||||
|
#include "../../../include/asset_mgr.hpp"
|
||||||
|
#include "../../../include/shared.hpp"
|
||||||
|
#include <PSX/Periphery/periphery.hpp>
|
||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
|
namespace BIOSInfo {
|
||||||
|
using namespace JabyEngine;
|
||||||
|
|
||||||
|
static void setup() {
|
||||||
|
Shared::back_menu.reset();
|
||||||
|
printf("Planschbecken!\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool update_or_exit() {
|
||||||
|
Periphery::query_controller();
|
||||||
|
if(Shared::back_menu.update(Make::PositionI16(0, GPU::Display::Height - 32))) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void render() {
|
||||||
|
Shared::back_menu.render();
|
||||||
|
}
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
setup();
|
||||||
|
|
||||||
|
while(true) {
|
||||||
|
if(update_or_exit()) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
GPU::swap_buffers_vsync(1);
|
||||||
|
render();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,6 +1,10 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
#include <PSX/File/cd_file_types.hpp>
|
#include <PSX/File/cd_file_types.hpp>
|
||||||
|
|
||||||
|
namespace BIOSInfo {
|
||||||
|
void main();
|
||||||
|
}
|
||||||
|
|
||||||
namespace ControllerTest {
|
namespace ControllerTest {
|
||||||
extern const volatile JabyEngine::AutoLBAEntry lba[];
|
extern const volatile JabyEngine::AutoLBAEntry lba[];
|
||||||
extern JabyEngine::CDFile Assets[1];
|
extern JabyEngine::CDFile Assets[1];
|
||||||
|
|
|
@ -36,6 +36,7 @@ static const Menu::SimpleMenu::Entry MenuEntries[] = {
|
||||||
{"GTE Test"},
|
{"GTE Test"},
|
||||||
{"Font Cycler"},
|
{"Font Cycler"},
|
||||||
{"Screen Center"},
|
{"Screen Center"},
|
||||||
|
{"BIOS Information"}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const auto doener_fish = Make::SPRT(
|
static const auto doener_fish = Make::SPRT(
|
||||||
|
@ -94,6 +95,11 @@ static void setup() {
|
||||||
state_changer.asset_load = Assets::Overlay::load_screen_center;
|
state_changer.asset_load = Assets::Overlay::load_screen_center;
|
||||||
state_changer.main = ScreenCenter::main;
|
state_changer.main = ScreenCenter::main;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 5:
|
||||||
|
state_changer.asset_load = Assets::Overlay::load_bios_info;
|
||||||
|
state_changer.main = BIOSInfo::main;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
},MenuEntries);
|
},MenuEntries);
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
#include <PSX/AutoLBA/auto_lba_declaration.hpp>
|
#include <PSX/AutoLBA/auto_lba_declaration.hpp>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
|
extern "C" uint32_t __bios_info_start;
|
||||||
extern "C" uint32_t __controller_tests_start;
|
extern "C" uint32_t __controller_tests_start;
|
||||||
extern "C" uint32_t __gpu_tests_start;
|
extern "C" uint32_t __gpu_tests_start;
|
||||||
extern "C" uint32_t __screen_center_start;
|
extern "C" uint32_t __screen_center_start;
|
||||||
|
@ -14,6 +15,7 @@ namespace Assets {
|
||||||
__jabyengine_start_lba_request
|
__jabyengine_start_lba_request
|
||||||
__jabyengine_request_lba_for(PACO, "ASSETS/MAIN/PACO.BIN"),
|
__jabyengine_request_lba_for(PACO, "ASSETS/MAIN/PACO.BIN"),
|
||||||
__jabyengine_request_lba_for(DFISH, "ASSETS/MAIN/DFISH.BIN"),
|
__jabyengine_request_lba_for(DFISH, "ASSETS/MAIN/DFISH.BIN"),
|
||||||
|
__jabyengine_request_lba_for(BIOS_INFO_OVL, "BIO.BIN"),
|
||||||
__jabyengine_request_lba_for(GPU_TEST_OVL, "GTO.BIN"),
|
__jabyengine_request_lba_for(GPU_TEST_OVL, "GTO.BIN"),
|
||||||
__jabyengine_request_lba_for(GTE_TEST_OVL, "GTE.BIN"),
|
__jabyengine_request_lba_for(GTE_TEST_OVL, "GTE.BIN"),
|
||||||
__jabyengine_request_lba_for(CONT_TEST_OVL, "CTO.BIN"),
|
__jabyengine_request_lba_for(CONT_TEST_OVL, "CTO.BIN"),
|
||||||
|
@ -63,7 +65,16 @@ namespace Assets {
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace Overlay {
|
namespace Overlay {
|
||||||
// All these loadings can be done by one function taking the LBA of ther overlay, the new LBA and the new Asset array
|
// TODO: All these loadings can be done by one function taking the LBA of ther overlay, the new LBA and the new Asset array
|
||||||
|
|
||||||
|
void load_bios_info() {
|
||||||
|
const CDFile Files[] = {
|
||||||
|
CDFileBuilder::overlay(LBA::BIOS_INFO_OVL, &__bios_info_start)
|
||||||
|
};
|
||||||
|
|
||||||
|
::Assets::load(lba, Files);
|
||||||
|
}
|
||||||
|
|
||||||
void load_controller_test() {
|
void load_controller_test() {
|
||||||
const CDFile Files[] = {
|
const CDFile Files[] = {
|
||||||
CDFileBuilder::overlay(LBA::CONT_TEST_OVL, &__controller_tests_start)
|
CDFileBuilder::overlay(LBA::CONT_TEST_OVL, &__controller_tests_start)
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
<Track>
|
<Track>
|
||||||
<File name = "SYSTEM.CNF">System.cnf.subst</File>
|
<File name = "SYSTEM.CNF">System.cnf.subst</File>
|
||||||
<Main name = "%PSX_BOOT_FILE%" lba_source = "../application/src/asset_mgr.cpp">../application/bin/%PSX_TV_FORMAT%/PSX-release/PoolBox.psexe</Main>
|
<Main name = "%PSX_BOOT_FILE%" lba_source = "../application/src/asset_mgr.cpp">../application/bin/%PSX_TV_FORMAT%/PSX-release/PoolBox.psexe</Main>
|
||||||
|
<Overlay name = "BIO.BIN">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.bios_info</Overlay>
|
||||||
<Overlay name = "CTO.BIN" lba_source = "../application/src/Overlay/ControllerTest/controller_test_assets.cpp">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.controller_tests</Overlay>
|
<Overlay name = "CTO.BIN" lba_source = "../application/src/Overlay/ControllerTest/controller_test_assets.cpp">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.controller_tests</Overlay>
|
||||||
<Overlay name = "GTO.BIN" lba_source = "../application/src/Overlay/GPUTest/gpu_test_assets.cpp">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.gpu_tests</Overlay>
|
<Overlay name = "GTO.BIN" lba_source = "../application/src/Overlay/GPUTest/gpu_test_assets.cpp">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.gpu_tests</Overlay>
|
||||||
<Overlay name = "GTE.BIN">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.gte_tests</Overlay>
|
<Overlay name = "GTE.BIN">../application/bin/%PSX_TV_FORMAT%/PSX-release/Overlay.gte_tests</Overlay>
|
||||||
|
|
Loading…
Reference in New Issue