Author Topic: SVC Chaos driver infos.  (Read 47022 times)

Offline Xeon

  • Newbies
  • *
  • Posts: 45
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #45 on: November 27, 2004, 11:14:59 PM »
can someone please post a complete driver for svcboot? i have my own driver and got it to compile but one of the void itself seems to require too much RAM (as the loading takes eternity after the m1). also, im not too sure if i did put it in the right place (i  put the svcboot_cx_decrypt on d_neogeo.cpp)

Offline James33

  • Expert
  • *****
  • Posts: 532
  • Karma: +3/-0
  • The Mame Man
    • Emulation Zone
SVC Chaos driver infos.
« Reply #46 on: November 27, 2004, 11:57:56 PM »
Quote from: iq_132
Here's my source to get svcchaos working in FBA :)
This uses the correct(?) PCB roms (32mb P & Cs)

Adding this code is Fairly complicated, so if it doesn't work correctly the first time, try it again maybe you'll get better results ;)


useing your driver.
I have tried many times with this and keeps comming up with this error
And I allready been useing kof2003b init (bankswitch) for kof2003b

Quote

src/burn/neogeo/d_neogeo.cpp: In function `int svcchaosInit()':
src/burn/neogeo/d_neogeo.cpp:5513: `kof2003b_tbl' undeclared (first use this function)
src/burn/neogeo/d_neogeo.cpp:5513: (Each undeclared identifier is reported only once for each function it appears in.)
src/burn/neogeo/d_neogeo.cpp:5517: `kof2003bMapHandler' undeclared (first use this function)
src/burn/neogeo/d_neogeo.cpp: At global scope:
src/burn/neogeo/d_neogeo.cpp:6850: `short unsigned int kof2003b_tbl[4096]' used prior to declaration
src/burn/neogeo/d_neogeo.cpp: In function `void kof2003bMapHandler()':
src/burn/neogeo/d_neogeo.cpp:6914: `void kof2003bMapHandler()' used prior to declaration
make: *** [d_neogeo.o] Error 1
IQ Forum Member

Offline FerchogtX

  • FBNeo Dev
  • ******
  • Posts: 375
  • Karma: +7/-0
  • FB Alpha Team ;)
    • FB Alpha Plus! Web Site
SVC Chaos driver infos.
« Reply #47 on: November 28, 2004, 12:26:12 AM »
Quote from: Badablek
Again with a new stupid question  :D

I tried some combinaisons between P1 AB053D97 and P1 93855C0B, and when I replace the first 1Mo of AB053D97 with the one from 93855C0B, the game boots fine and works without any problem.......
Here is my question : Only the first chunk (first 1Mo) of the P1 is protected ?????? By comparing the 2 files, there isn't a lot of diff' (SNK Giga power logo added for example).

Is there some kind of protection like on svcplus (1 bit that prevents the game to work) as the P1 AB053D97 boots fine the reboots ?

Not quite, the game sems to have 2 bankswitches..., the one for kof2003b (that seems to be almost universal) and the other one that seems to be the protection itself... I'm not sure of this but the fact is that svcchaos and kof2003 have 2 bankswitchs instead of only one, so when you replace the first MB of data the whole protections were removed, the problem is that in that chunk (of the decrypted and fixed p1 you're truing to use) there are a lot of bugs that aren't present in the original p1, the only problem is that we need the second bankswitch in order to get working the last not working game in fba (kof2003 and kof2k3nd)...
Thats the point...
See ya!!!!!! :D

Good and evil co-exist because of the balance, lies are not part of it...

FB Alpha Plus! site infos updated, see the latest info clicking on my profile link...

Offline iq_132

  • Administrator
  • *****
  • Posts: 3724
  • Karma: +411/-0
  • Definitely not Dink!
    • NeoSource
SVC Chaos driver infos.
« Reply #48 on: November 28, 2004, 04:32:32 AM »
Quote from: Xeon
can someone please post a complete driver for svcboot? i have my own driver and got it to compile but one of the void itself seems to require too much RAM (as the loading takes eternity after the m1). also, im not too sure if i did put it in the right place (i  put the svcboot_cx_decrypt on d_neogeo.cpp)


Try this version of the svcboot_cx_decrypt code.
It should require less ram than the old one, but it may take a little longer for it to decrypt.

btw. Yes, I have my code in d_neogeo.cpp

Code: [Select]
static void svcboot_cx_decrypt()
{
int i,j;
int fsize = 0x100000;

for (j = 0; j < 0x4000000; j=j+fsize)
{
int ofst;
UINT8 *src = NeoSpriteROM + j;
UINT8 *dst = (UINT8*)malloc( fsize );

const unsigned char sec[ 0x10 ] = {
0, 1, 0, 1, 2, 3, 2, 3, 3, 4, 3, 4, 4, 5, 4, 5,
};

const unsigned char swap[ 6 ][ 4 ] = {
{ 3, 0, 1, 2 },
{ 2, 3, 0, 1 },
{ 1, 2, 3, 0 },
{ 0, 1, 2, 3 },
{ 3, 2, 1, 0 },
{ 3, 0, 2, 1 },
};

memcpy( dst, src, fsize );

for( i = 0; i < fsize / 0x80; i++ ){
int tbl = sec[ (i & 0xf00) >> 8 ];

int bit0 = swap[ tbl ][ 0 ];
int bit1 = swap[ tbl ][ 1 ];
int bit2 = swap[ tbl ][ 2 ];
int bit3 = swap[ tbl ][ 3 ];

ofst = BITSWAP08( (i & 0x0000ff), 7, 6, 5, 4, bit3, bit2, bit1, bit0 );
ofst += (i & 0xfffff00);

memcpy( &src[ i * 0x80 ], &dst[ ofst * 0x80 ], 0x80 );
}
free( dst );
}
}


Offline Badablek

  • Jr. Member
  • **
  • Posts: 63
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #49 on: November 28, 2004, 07:44:42 AM »
Quote from: FerchogtX
Not quite, the game sems to have 2 bankswitches..., the one for kof2003b (that seems to be almost universal) and the other one that seems to be the protection itself... I'm not sure of this but the fact is that svcchaos and kof2003 have 2 bankswitchs instead of only one, so when you replace the first MB of data the whole protections were removed, the problem is that in that chunk (of the decrypted and fixed p1 you're truing to use) there are a lot of bugs that aren't present in the original p1, the only problem is that we need the second bankswitch in order to get working the last not working game in fba (kof2003 and kof2k3nd)...
Thats the point...
See ya!!!!!! :D


thx for the info ^^

So i'll wait for a clean really decrypted non bootleg P.....

Offline James33

  • Expert
  • *****
  • Posts: 532
  • Karma: +3/-0
  • The Mame Man
    • Emulation Zone
SVC Chaos driver infos.
« Reply #50 on: November 28, 2004, 08:22:05 AM »
I think the decrypted P will turn out to be allready released Since the bootleg P roms came from the original set anyway
IQ Forum Member

Offline Xeon

  • Newbies
  • *
  • Posts: 45
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #51 on: November 28, 2004, 08:27:15 AM »
thanks iq, now, not to be a request b*tch but do you think something can be done on svcchaos/svcnd P1 to load quicker? i mean, the last time i tried svcnd on kdev it took a little more time to load the P1 but after that short while everything went nicely. overall, its still a lot quicker than with the current code now.

also, i made a CRC check with Uni-BIOS and it seems were getting closer now, everything else is correct except for the ROM Region.

Offline James33

  • Expert
  • *****
  • Posts: 532
  • Karma: +3/-0
  • The Mame Man
    • Emulation Zone
SVC Chaos driver infos.
« Reply #52 on: November 28, 2004, 08:53:33 AM »
What rom set did you check with the UNI BIOS ? I checked svchaosa and svcchaos and is 100% ok with version 2.0.
IQ Forum Member

Offline Xeon

  • Newbies
  • *
  • Posts: 45
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #53 on: November 28, 2004, 09:21:31 AM »
svcnd, havent gotten around to encrypt the C ROMs :P

and btw, iq, the new svcboot c decrypt code didnt work :(

Offline iq_132

  • Administrator
  • *****
  • Posts: 3724
  • Karma: +411/-0
  • Definitely not Dink!
    • NeoSource
SVC Chaos driver infos.
« Reply #54 on: November 28, 2004, 12:32:46 PM »
It looks like that because of your S rom.  The correct one for svcboot is scrambled.


Offline Xeon

  • Newbies
  • *
  • Posts: 45
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #55 on: November 28, 2004, 01:27:27 PM »
i have already set the NeoTextROMFixType to 2 though (value according to Ferchogtx). is the CRC of the S1 supposed to be the same as the one KDev uses (thats what im using), another S1 needed, or have i used the wrong ROMFixType value?

Offline iq_132

  • Administrator
  • *****
  • Posts: 3724
  • Karma: +411/-0
  • Definitely not Dink!
    • NeoSource
SVC Chaos driver infos.
« Reply #56 on: November 28, 2004, 01:55:11 PM »
I'm using this S1:
{"svc-s1.bin", 0x020000, 0x70b44df1,    1}, //  1 Text data

and this descrambling code:

Code: [Select]
/* Descrambling S1 by FerchogtX, based on DorriGa's code */
unsigned char* srom = NeoTextROM+0x20000;
unsigned char* dst = (unsigned char*)malloc(0x20000);
memcpy( dst+0x00000, srom+0x10000, 0x10000 );
memcpy( dst+0x10000, srom+0x00000, 0x10000 );
memcpy( srom, dst, 0x20000 );
free(dst);


Offline Xeon

  • Newbies
  • *
  • Posts: 45
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #57 on: November 28, 2004, 02:07:52 PM »
weird, im using those exactly as well :|

Offline FerchogtX

  • FBNeo Dev
  • ******
  • Posts: 375
  • Karma: +7/-0
  • FB Alpha Team ;)
    • FB Alpha Plus! Web Site
SVC Chaos driver infos.
« Reply #58 on: November 28, 2004, 08:39:24 PM »
Chek in you init of flags that you don't have anything that enables some configs for texts... i mean:
-HARDWARE_SNK_ALTERNATE_TEXT
-nNeoTextROMSize
If you have any of them in your driver, delete them
See ya!!!! :D
P.D. Also check the case number (init value) maybe you've mistaken the number, check against the whole code in neo_run.cpp, it seems that you are using svcsplus value instead of svcboot one...

Good and evil co-exist because of the balance, lies are not part of it...

FB Alpha Plus! site infos updated, see the latest info clicking on my profile link...

Offline Xeon

  • Newbies
  • *
  • Posts: 45
  • Karma: +0/-0
  • Member
SVC Chaos driver infos.
« Reply #59 on: November 29, 2004, 12:59:30 AM »
im fairly sure i dont have those and have matched the descrambling code iq used. i guess ill just try other values :\