Difference between revisions of "System Menu/BS2"

From WiiBrew
Jump to: navigation, search
(Types)
(Types)
Line 29: Line 29:
 
|-
 
|-
 
| 5  
 
| 5  
| Update cache.dat if necessary, setup 800030E6 [16bit] based on drive info
+
| wait for dvd command to finish, update cache.dat if necessary, setup 800030E6 [16bit] based on drive info
 
| 8
 
| 8
 
|-
 
|-
Line 45: Line 45:
 
|-
 
|-
 
| 9  
 
| 9  
| Update cache.dat if necessary, copy the 0x20 byte long disk id to 0x80000000.
+
| wait for dvd command to finish, update cache.dat if necessary, copy the 0x20 byte long disk id to 0x80000000.
 
   if [disk_id + 0x18] is 0x5d1c9ea3, and the [disk_id + 0] is not 'RAAE', treat as a wii disc.
 
   if [disk_id + 0x18] is 0x5d1c9ea3, and the [disk_id + 0] is not 'RAAE', treat as a wii disc.
 
   otherwise, if [disk_id + 0x1c] is 0xc2339f3d, treat as gamecube disk
 
   otherwise, if [disk_id + 0x1c] is 0xc2339f3d, treat as gamecube disk
Line 79: Line 79:
 
|-
 
|-
 
| 15  
 
| 15  
|
+
| read 0x20 bytes from disk (game toc?)
|
+
| 16
 
|-
 
|-
 
| 16  
 
| 16  
|
+
| wait for dvd command to finish, update cache.dat if necessary
|
+
| 17
 
|-
 
|-
 
| 17  
 
| 17  

Revision as of 21:00, 18 May 2010

States taken from System Menu 257 (3.1U)

Types

State number action next states
0 prints out status flags ("No Disk", "Drive Reset", "Wait Spinup", "Boot from Cache"), delay?, enable waiting-for-disk? 2, 52
1 delay 2
2 delay, check for update, enable waiting-for-disk?, DVDResetAsync 3
3 bs2_issue_dvd_command, delay, __DVDGetCoverStatusAsync, create cache.dat? 4
4 ReadDriveInfo via cache.dat or DVDInquiryAsync 5
5 wait for dvd command to finish, update cache.dat if necessary, setup 800030E6 [16bit] based on drive info 8
6
7
8 Read 0x20 bytes of disk id [from cache.dat or disk via DVDReadDiskID] 9
9 wait for dvd command to finish, update cache.dat if necessary, copy the 0x20 byte long disk id to 0x80000000.
 if [disk_id + 0x18] is 0x5d1c9ea3, and the [disk_id + 0] is not 'RAAE', treat as a wii disc.
 otherwise, if [disk_id + 0x1c] is 0xc2339f3d, treat as gamecube disk
 otherwise, the disk type is unknown
gamecube disk = 11, wii disk = 15, unknown = 54
10
11 if not waiting for a disk, exit to state 50

if waiting, disable the waiting-for-disk and check streaming [0x80000008]

if streaming and no streaming buffer size defined [0x80000009], set to size 10

if streaming, setup via __DVDAudioBufferConfig

12
12 wait for DVD command to finish 13
13 async unencrypted 0x2000 byte dvd read 14
14 wait for DVD command to finish

once finished, check game region

region ok = 50

region not match = 54

15 read 0x20 bytes from disk (game toc?) 16
16 wait for dvd command to finish, update cache.dat if necessary 17
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72