diff --git a/PSNee_V8/PSNee_V8.ino b/PSNee_V8/PSNee_V8.ino index 07c36b3..89cdaa8 100644 --- a/PSNee_V8/PSNee_V8.ino +++ b/PSNee_V8/PSNee_V8.ino @@ -40,15 +40,16 @@ //------------------------------------------------------------------------------------------------ #define AUTOREGION // If disable, send all SCEX codes, instead of the code selected model. -#define PATCH_SW // Enables hardware support for disabling BIOS patching. +//#define PATCH_SW // Enables hardware support for disabling BIOS patching. +//#define MOD_SW // Enables hardware support for disabling the entire modchip. //------------------------------------------------------------------------------------------------ // Code section //------------------------------------------------------------------------------------------------ -#include "config.h" -#include "settings.h" -#include "patching.h" +#include "include/config.h" +#include "include/settings.h" +#include "include/patching.h" volatile uint8_t count_isr = 0; volatile uint32_t microsec = 0; @@ -177,16 +178,16 @@ int main() uint16_t highs = 0, lows = 0; #if !defined(UC_ALL) && !defined(PAL_FAT) && !defined(SCPH_103) && \ - !defined(SCPH_102) && !defined(SCPH_100) && !defined(SCPH_7000_9000) && \ - !defined(SCPH_5500) && !defined(SCPH_3500_5000) && !defined(SCPH_3000) && \ - !defined(SCPH_1000) - #error "Console not selected! Please uncoment #define with SCPH model number." - #elif !(defined(UC_ALL) ^ defined(PAL_FAT) ^ defined(SCPH_103) ^ \ - defined(SCPH_102) ^ defined(SCPH_100) ^ defined(SCPH_7000_9000) ^ \ - defined(SCPH_5500) ^ defined(SCPH_3500_5000) ^ defined(SCPH_3000) ^ \ - defined(SCPH_1000)) - #error "May be selected only one console! Please check #define with SCPH model number." - #endif + !defined(SCPH_102) && !defined(SCPH_100) && !defined(SCPH_7000_9000) && \ + !defined(SCPH_5500) && !defined(SCPH_3500_5000) && !defined(SCPH_3000) && \ + !defined(SCPH_1000) + #error "Console not selected! Please uncomment #define with SCPH model number." + #elif !(defined(UC_ALL) ^ defined(PAL_FAT) ^ defined(SCPH_103) ^ \ + defined(SCPH_102) ^ defined(SCPH_100) ^ defined(SCPH_7000_9000) ^ \ + defined(SCPH_5500) ^ defined(SCPH_3500_5000) ^ defined(SCPH_3000) ^ \ + defined(SCPH_1000)) + #error "May be selected only one console! Please check #define with SCPH model number." + #endif #ifndef AUTOREGION const char region[3] = {'e', 'a', 'i'}; @@ -194,6 +195,11 @@ int main() Init(); + #if defined(MOD_SW) + if (MOD_SW_CHECK == 0) + return 0; + #endif + #ifdef LED_USE LED_ON; #endif diff --git a/PSNee_V8/include/config.h b/PSNee_V8/include/config.h index ec24baf..cc6e9d8 100644 --- a/PSNee_V8/include/config.h +++ b/PSNee_V8/include/config.h @@ -38,6 +38,9 @@ #define SW_USE PORTD |= (1<<5) #define SW_CHECK (PIND & (1<<5)) +#define MOD_SW_USE PORTB |= (1<<2) +#define MOD_SW_CHECK (PINB & (1<<2)) + #define LED_USE DDRB |= (1<<5) #define LED_ON PORTB |= (1<<5) #define LED_OFF PORTB &= ~(1<<5) @@ -52,6 +55,10 @@ void Init() #ifdef PATCH_SW SW_USE; #endif + + #ifdef MOD_SW + MOD_SW_USE; + #endif LED_USE; sei(); diff --git a/README.md b/README.md index aad58cb..7d478ce 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,15 @@ -# PSNee V8 +# PSNee V8.1 -The first stealth modchip supporting unlocking BIOS of Japanese versions Sony PlayStation 1 +The first stealth modchip supporting unlocking BIOS of Japanese versions Sony PlayStation 1, and disabling the modchip itself. ![Logo](images/PSNee_V8_logo.png) Developed by **brill** & **postal2201**, based on PSNee V7 open source project. - http://www.emu-land.net/forum/index.php/topic,85934.0.html +The MOD_SWITCH feature added by **Victini378** and designed in cooperation with **SunAlphiusWu**. + ## Supported platforms -PsNee V8 supports the following MCU's: +PsNee V8.1 supports the following MCU's: - ATmega328(A/P/PA) @16Mhz - ATmega168(A/P/PA) @16Mhz @@ -28,7 +30,7 @@ Example of correct setting for ATmega328P:\ ![ArduinoIDE](images/example.png) -After that select the type console - uncoment define in file project(*.ino) +After that select the type console - uncomment define in file project(*.ino) ![Console](images/console.png)