* NUS downloader: ensure a IOS4 & 9 for full updates

* adding 3 more full updates

git-svn-id: http://wiiqt.googlecode.com/svn/trunk@55 389f4c8b-5dfe-645f-db0e-df882bc27289
This commit is contained in:
giantpune@gmail.com 2011-01-16 16:05:01 +00:00
parent e8bd408ba6
commit 7994575033
3 changed files with 121 additions and 85 deletions

View File

@ -228,6 +228,7 @@ bool NandBin::CreateNew( const QString &path, const QByteArray &keys, const QByt
}
//find 90 blocks to reserve. they always appear to be close to the end of the nand
//TODO - this isnt always 90, all my nands have a different number, and 90 is right in the middle
//sometimes IOS adds more
quint16 bCnt = badBlocks.size();
quint16 offset = 0;
for( quint16 i = 0; i < bCnt; i++ )
@ -1540,8 +1541,8 @@ bool NandBin::SetData( quint16 idx, const QByteArray &data )
fts << cl; //add this one to the clusters that will be used to hold the data
quint16 block = cl / 8; //try to find other clusters in the same block
//for( quint16 i = block * 8; i < ( ( block + 1 ) * 8 ) && fts.size() < clCnt; i++ )
quint16 max = freeClusters.at( freeClusters.size() - 1 );
//for( quint16 i = block * 8; i < ( ( block + 1 ) * 8 ) && fts.size() < clCnt; i++ )// <- this one scatters files all over the place
quint16 max = freeClusters.at( freeClusters.size() - 1 ); // <- this one keeps files together; appears to closer mimic IOS's behavior
for( quint16 i = block * 8; i < max && fts.size() < clCnt; i++ )
{
if( cl == i ) //this one is already added to the list
@ -1570,6 +1571,7 @@ bool NandBin::SetData( quint16 idx, const QByteArray &data )
}
}
//sort clusters so file is written in order ( not like it matters on flash memory, though )
qSort( fts.begin(), fts.end() );
//qDebug() << "about to writing shit" << clCnt << fts.size();
//qDebug() << "file will be on clusters\n" << hex << fts;

View File

@ -533,8 +533,9 @@ bool NusDownloader::GetUpdate( const QString & upd, bool decrypt )
if( s == "2.1e" ) titles = List21e();
else if( s == "3.0e" ) titles = List30e();
else if( s == "3.1e" ) titles = List31e();
else if( s == "3.3e" ) titles = List33e();
else if( s == "3.1e" ) titles = List31e();
else if( s == "3.2e" ) titles = List32e();
else if( s == "3.3e" ) titles = List33e();
else if( s == "3.4e" ) titles = List34e();
else if( s == "4.0e" ) titles = List40e();
else if( s == "4.1e" ) titles = List41e();
@ -557,8 +558,10 @@ bool NusDownloader::GetUpdate( const QString & upd, bool decrypt )
else if( s == "4.2k" ) titles = List42k();
else if( s == "4.3k" ) titles = List43k();
else if( s == "2.0j" ) titles = List20j();
else if( s == "3.1j" ) titles = List31j();
else if( s == "2.0j" ) titles = List20j();
else if( s == "3.0j" ) titles = List30j();
else if( s == "3.1j" ) titles = List31j();
else if( s == "3.2j" ) titles = List33j();
else if( s == "3.3j" ) titles = List33j();
else if( s == "3.4j" ) titles = List34j();
else if( s == "4.0j" ) titles = List40j();
@ -568,6 +571,12 @@ bool NusDownloader::GetUpdate( const QString & upd, bool decrypt )
else return false;//unknown update
//make sure there is an IOS4 & 9
if( titles.find( 0x100000004ull ) == titles.end() )
titles.insert( 0x100000004ull, 0xff00 );
if( titles.find( 0x100000009ull ) == titles.end() )
titles.insert( 0x100000009ull, 520 );
//hell, give everybody these.
titles.insert( 0x1000248414741ull, 0x3 );//news channel HAGA
titles.insert( 0x1000248414641ull, 0x3 );//Weather Channel HAFA
@ -582,28 +591,44 @@ bool NusDownloader::GetUpdate( const QString & upd, bool decrypt )
}
QMap< quint64, quint16 > NusDownloader::List20j()
{
QMap< quint64, quint16 > titles;
//titles.insert( 0x100000001ull, 2 );//boot2
titles.insert( 0x100000002ull, 128 );//sys menu
titles.insert( 0x10000000bull, 10 );//11v10
titles.insert( 0x10000000cull, 6 );//12v6
titles.insert( 0x10000000dull, 10 );//13v10
titles.insert( 0x10000000full, 257 );//15v257
titles.insert( 0x100000011ull, 512 );//17v512
titles.insert( 0x100000023ull, 0xc10 ); // IOS35 - not really part of this update, but needed for sneek
titles.insert( 0x100000100ull, 0x2 );//bcv2
titles.insert( 0x100000101ull, 0x4 );//miosv4
titles.insert( 0x1000848414B4aull, 0 );//EULA - HAKJ
titles.insert( 0x1000848414C4aull, 0x2 );//regsel //region select isnt in the paper mario update, but putting it here just to be safe
titles.insert( 0x1000248414341ull, 0x2 );//nigaoeNRv2 - MII
titles.insert( 0x1000248414141ull, 0x1 );//photov1
titles.insert( 0x1000248414241ull, 0x4 );//shoppingv4
return titles;
QMap< quint64, quint16 > titles;
//titles.insert( 0x100000001ull, 2 );//boot2
titles.insert( 0x100000002ull, 128 );//sys menu
titles.insert( 0x10000000bull, 10 );//11v10
titles.insert( 0x10000000cull, 6 );//12v6
titles.insert( 0x10000000dull, 10 );//13v10
titles.insert( 0x10000000full, 257 );//15v257
titles.insert( 0x100000011ull, 512 );//17v512
titles.insert( 0x100000023ull, 0xc10 ); // IOS35 - not really part of this update, but needed for sneek
titles.insert( 0x100000100ull, 0x2 );//bcv2
titles.insert( 0x100000101ull, 0x4 );//miosv4
titles.insert( 0x1000848414B4aull, 0 );//EULA - HAKJ
titles.insert( 0x1000848414C4aull, 0x2 );//regsel //region select isnt in the paper mario update, but putting it here just to be safe
titles.insert( 0x1000248414341ull, 0x2 );//nigaoeNRv2 - MII
titles.insert( 0x1000248414141ull, 0x1 );//photov1
titles.insert( 0x1000248414241ull, 0x4 );//shoppingv4
return titles;
}
QMap< quint64, quint16 > NusDownloader::List30j()
{
QMap< quint64, quint16 > titles = List20j();
titles.insert( 0x100000002ull, 128 ); //sys menu
titles.insert( 0x100000023ull, 0xc10 ); // IOS35 - not really part of this update, but needed for sneek
titles.insert( 0x100000101ull, 5 ); //miosv5
titles.insert( 0x1000848414B4aull, 2 ); //EULA v2- HAKJ
titles.insert( 0x1000848414C4aull, 0x2 ); //regsel
titles.insert( 0x1000248414341ull, 4 ); //nigaoeNRv4 - MII
titles.insert( 0x1000248414141ull, 0x1 ); //photov1
titles.insert( 0x1000248414241ull, 7 ); //shoppingv7
titles.insert( 0x100024841464aull, 0x7 ); // forcast v7 HAFJ
titles.insert( 0x100024841474aull, 0x7 ); // news v7 HAGJ
return titles;
}
QMap< quint64, quint16 > NusDownloader::List31j()
{
QMap< quint64, quint16 > titles = List20j();//TODO - missing a few in here
QMap< quint64, quint16 > titles = List30j();
titles.insert( 0x100000002ull, 256 );//sys menu
titles.insert( 0x100000014ull, 12 );//20v12
titles.insert( 0x100000015ull, 514 );//21v514
@ -616,37 +641,38 @@ QMap< quint64, quint16 > NusDownloader::List31j()
titles.insert( 0x100000023ull, 1040 );//35v1040
titles.insert( 0x100000024ull, 1042 );//36v1042
//titles.insert( 0x100000025ull, 2070 );//37v2070 //3.1u has this one but not 3.1j??
titles.insert( 0x1000248415941ull, 0x1 );//photo2v1
titles.insert( 0x1000848414B4aull, 0 );//EULA - HAKJ
titles.insert( 0x100024841464aull, 0x7 );// forcast v7 HAFJ
titles.insert( 0x100000101ull, 5 );//miosv5
titles.insert( 0x1000848414C4aull, 0x2 );//regsel //region select isnt in the paper mario update, but putting it here just to be safe
titles.insert( 0x1000248414341ull, 0x2 );//nigaoeNRv2 - MII
titles.insert( 0x1000248414141ull, 0x1 );//photov1
titles.insert( 0x1000248414241ull, 7 );//shoppingv7
titles.insert( 0x100024841474aull, 0x7 ); // news v7 HAGJ
titles.insert( 0x1000248415941ull, 0x1 );//photo2v1
return titles;
}
//TODO - if anybody has a wii on ORIGINAL 3.2j firmware, i would like to get the real listing from them.
//this may not be correct
QMap< quint64, quint16 > NusDownloader::List32j()
{
QMap< quint64, quint16 > titles = List31j();
titles.insert( 0x100000002ull, 288 );//sys menu
return titles;
}
QMap< quint64, quint16 > NusDownloader::List33j()
{
QMap< quint64, quint16 > titles = List31j();//TODO - missing 3.2j
titles.insert( 0x100000002ull, 352 );//sys menu
titles.insert( 0x10000000bull, 10 );//11v10
titles.insert( 0x10000000cull, 6 );//12v6
titles.insert( 0x10000000dull, 10 );//13v10
titles.insert( 0x10000000full, 257 );//15v257
titles.insert( 0x100000011ull, 512 );//17v512
titles.insert( 0x10000001eull, 2576 );//30v2576
titles.insert( 0x10000001full, 2576 );//31v2576
titles.insert( 0x100000025ull, 2070 );//37v2070
titles.insert( 0x100000100ull, 0x4 );//bcv4
titles.insert( 0x1000248415941ull, 0x1 );//photo2v1
titles.insert( 0x1000848414B4aull, 2 );//EULA - HAKJ
titles.insert( 0x100000101ull, 8 );//miosv8
titles.insert( 0x1000248414341ull, 5 );//nigaoeNRv5 - MII
titles.insert( 0x1000248414241ull, 10 );//shoppingv10
return titles;
QMap< quint64, quint16 > titles = List32j();
titles.insert( 0x100000002ull, 352 );//sys menu
titles.insert( 0x10000000bull, 10 );//11v10
titles.insert( 0x10000000cull, 6 );//12v6
titles.insert( 0x10000000dull, 10 );//13v10
titles.insert( 0x10000000full, 257 );//15v257
titles.insert( 0x100000011ull, 512 );//17v512
titles.insert( 0x10000001eull, 2576 );//30v2576
titles.insert( 0x10000001full, 2576 );//31v2576
titles.insert( 0x100000025ull, 2070 );//37v2070
titles.insert( 0x100000100ull, 0x4 );//bcv4
titles.insert( 0x1000248415941ull, 0x1 );//photo2v1
titles.insert( 0x1000848414B4aull, 2 );//EULA - HAKJ
titles.insert( 0x100000101ull, 8 );//miosv8
titles.insert( 0x1000248414341ull, 5 );//nigaoeNRv5 - MII
titles.insert( 0x1000248414241ull, 10 );//shoppingv10
return titles;
}
QMap< quint64, quint16 > NusDownloader::List34j()
@ -862,42 +888,50 @@ QMap< quint64, quint16 > NusDownloader::List30e()
QMap< quint64, quint16 > NusDownloader::List31e()
{
QMap< quint64, quint16 > titles = List30e();
//( from rayman raving rabbids tv party )
//titles.insert( 0x10000000eull, 257 );//14v257 //dunno where this one came from?
titles.insert( 0x10000001eull, 1040 );//30v1040
titles.insert( 0x10000001full, 1040 );//31v1040
titles.insert( 0x100000021ull, 1040 );//33v1040
titles.insert( 0x100000022ull, 1039 );//34v1039
titles.insert( 0x100000023ull, 1040 );//35v1040
titles.insert( 0x100000024ull, 1042 );//36v1042
titles.insert( 0x100000002ull, 258 );//sys menu
titles.insert( 0x1000248415941ull, 0x2 ); // photo channel 1.1 HAYA
return titles;
QMap< quint64, quint16 > titles = List30e();
//( from rayman raving rabbids tv party )
//titles.insert( 0x10000000eull, 257 );//14v257 //dunno where this one came from?
titles.insert( 0x10000001eull, 1040 );//30v1040
titles.insert( 0x10000001full, 1040 );//31v1040
titles.insert( 0x100000021ull, 1040 );//33v1040
titles.insert( 0x100000022ull, 1039 );//34v1039
titles.insert( 0x100000023ull, 1040 );//35v1040
titles.insert( 0x100000024ull, 1042 );//36v1042
titles.insert( 0x100000002ull, 258 );//sys menu
titles.insert( 0x1000248415941ull, 0x2 ); // photo channel 1.1 HAYA
return titles;
}
//TODO - if anybody has a wii on ORIGINAL 3.2e firmware, i would like to get the real listing from them.
//this may not be correct
QMap< quint64, quint16 > NusDownloader::List32e()
{
QMap< quint64, quint16 > titles = List31e();
titles.insert( 0x100000002ull, 290 );//sys menu
return titles;
}
QMap< quint64, quint16 > NusDownloader::List33e()
{
QMap< quint64, quint16 > titles = List31e();
titles.insert( 0x100000002ull, 354 );//RVL-WiiSystemmenu-v354.wad
titles.insert( 0x10000000bull, 10 );//11v10
titles.insert( 0x10000000cull, 6 );//12v6
titles.insert( 0x10000000dull, 10 );//13v10
titles.insert( 0x10000000eull, 262 );//14v262 - should actually be 14v257 but that version isnt available on NUS
titles.insert( 0x10000000full, 257 );//15v257
titles.insert( 0x100000011ull, 512 );//17v512
titles.insert( 0x100000014ull, 12 );//20v12
titles.insert( 0x100000015ull, 514 );//21v514
titles.insert( 0x100000016ull, 777 );//22v777 - should be v772
titles.insert( 0x10000001cull, 1292 );//28v1292 - should be 1228
titles.insert( 0x10000001eull, 2576 );//30v2576
titles.insert( 0x10000001full, 2576 );//31v2576
titles.insert( 0x100000025ull, 2070 );//37v2070
titles.insert( 0x100000100ull, 4 );//bcv4
titles.insert( 0x100000101ull, 8 );//miosv8
titles.insert( 0x1000248414341ull, 5 );//nigaoeNRv5 - MII
titles.insert( 0x1000248414241ull, 10 );//shoppingv10
return titles;
QMap< quint64, quint16 > titles = List32e();
titles.insert( 0x100000002ull, 354 );//RVL-WiiSystemmenu-v354.wad
titles.insert( 0x10000000bull, 10 );//11v10
titles.insert( 0x10000000cull, 6 );//12v6
titles.insert( 0x10000000dull, 10 );//13v10
titles.insert( 0x10000000eull, 262 );//14v262 - should actually be 14v257 but that version isnt available on NUS
titles.insert( 0x10000000full, 257 );//15v257
titles.insert( 0x100000011ull, 512 );//17v512
titles.insert( 0x100000014ull, 12 );//20v12
titles.insert( 0x100000015ull, 514 );//21v514
titles.insert( 0x100000016ull, 777 );//22v777 - should be v772
titles.insert( 0x10000001cull, 1292 );//28v1292 - should be 1228
titles.insert( 0x10000001eull, 2576 );//30v2576
titles.insert( 0x10000001full, 2576 );//31v2576
titles.insert( 0x100000025ull, 2070 );//37v2070
titles.insert( 0x100000100ull, 4 );//bcv4
titles.insert( 0x100000101ull, 8 );//miosv8
titles.insert( 0x1000248414341ull, 5 );//nigaoeNRv5 - MII
titles.insert( 0x1000248414241ull, 10 );//shoppingv10
return titles;
}
QMap< quint64, quint16 > NusDownloader::List34e()

View File

@ -72,7 +72,7 @@ public:
static QMap< quint64, quint16 > List21e();
static QMap< quint64, quint16 > List30e();
static QMap< quint64, quint16 > List31e();
//static QMap< quint64, quint16 > List32e();
static QMap< quint64, quint16 > List32e(); //* there are no games ive seen that contain this update, i have only copied 3.1e and changed the system menu
static QMap< quint64, quint16 > List33e();
static QMap< quint64, quint16 > List34e();
static QMap< quint64, quint16 > List40e();
@ -86,9 +86,9 @@ public:
static QMap< quint64, quint16 > List43k();
static QMap< quint64, quint16 > List20j();
//static QMap< quint64, quint16 > List30j();
static QMap< quint64, quint16 > List30j();
static QMap< quint64, quint16 > List31j();
//static QMap< quint64, quint16 > List32j();
static QMap< quint64, quint16 > List32j();//* there are no games ive seen that contain this update, i have only copied 3.1j and changed the system menu
static QMap< quint64, quint16 > List33j();
static QMap< quint64, quint16 > List34j();
static QMap< quint64, quint16 > List40j();