Used this day to progress on my ATAPI driver, which is (somehow) based on BI's code, and (otherhow) on HALE's realmode driver. As far as i can tell, reading a "block" from a cdrom mainly consist in sending a "command" packet such as
Code: Select all
byte pkt[12]={
ATAPI_CMD_READ12, 0,
BYTE(b,3),BYTE(b,2), BYTE(b,1), BYTE(b,0),
BYTE(n,3), BYTE(n,2), BYTE(n,1), BYTE(n,0),
0,0
};
So far, i've been reading blocks 0 and 1, and if i retrieved them properly, they're just zeroes!? That might not be _that_ surprising since the ISO file looks like this:
Code: Select all
00000000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00008000 01 43 44 30 30 31 01 00 57 69 6e 33 32 20 20 20 |.CD001..Win32 |
00008010 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | |
00008020 20 20 20 20 20 20 20 20 42 6c 75 65 49 6c 6c 75 | BlueIllu|
00008030 73 69 6f 6e 20 4f 53 20 30 2e 30 35 20 20 20 20 |sion OS 0.05 |
00008040 20 20 20 20 20 20 20 20 00 00 00 00 00 00 00 00 | ........|
00008050 f1 10 00 00 00 00 10 f1 00 00 00 00 00 00 00 00 |................|
Or isn't the ISO image starting with logical block zero ? ...
Any hint is welcome.