-
How to hotswap with an USB/IDE enclosure and softmod.
Tools you need:
1. xboxhdm ver 1.9
2. qemu For Windows ver 0.9.1
3. USB/IDE enclosure.
4. Kingroach Ndure 3.1
Hotswapping won't be covered in details here.
1. Run Ndure 3.1
2. Populate the C and E folders in linux folder of xboxhdm with kingroach installer created files.
3. Run make-iso-win.bat. (Double click on it)
4. Copy the linux.iso file to the qemu folder.
5. Edit the following line qemu-win.bat
CODE
qemu.exe -L . -m 512 -hda //./PhysicalDrive1 -cdrom linux.iso -boot d -soundhw all -localtime -M pc
PhysicalDrive1 is the second physical hdd attached to the PC, in this case through USB.
6. Hotswap now. Throughout the process later, power must be supplied to the xbox hdd.
7. Run qemu-win.bat (Double click on it)
8. Select 1 or 2 once xboxhdm has started.
9. Type xbrowser. Copy the C and E folders from the CD to your xbox hdd. If xbrowser complains hdd is locked, you have to type poweroff and redo steps 6 and 7.
10. Type poweroff when done.
This post has been edited by ldotsfan: Apr 24 2008, 01:44 PM
-
does qemu supports ATA locking/unlocking?. I was able to hotswap using vmware before but it didnt support unlocking/locking..
-
Hi,
even if qemu supports locking/unlocking, the ide to usb converter simply won't. The firmware into the converter chip allows the reading and writing of disk sectors, but it doesn't allow the lowlevel disk lock and unlock commands. At least, that is my experience with them.
regards.
-
This setup does not support locking hence the hotswapping.
Here's why:
1. Physical connection. obcd is right, most usb/ide adapters don't implement ATA security BUT there is one that does it, cypress ezusb series - check the datasheet and I believe that's used in quite a few products out there. Assuming we use that...
2. Host OS. Windows doesn't implement ATA security functions in its API. Depending on how qemu or any other virtualization software interfaces with the host OS, unless it does its work at a lower level than the API it is unlikely to work. Btw the cypress ezchip windows driver doesn't implement ATA security as far as I can tell.
There's one free software: hdparm for cygwin that claims to support locking functions from Windows but I don't have a freeze lock free BIOS on my notebook to test it. My PC used for xboxhdm work is too low end to run XP properly (IMG:style_emoticons/default/tongue.gif)
3. The virtualization layer. detectpm confirmed qemu does not implement security feature in its virtual hdd. Even if it does, you need to feed the hdd model and serial no into the locking tool.
So for the forseeable future, locking remains out of reach for tools like qemu or vmware.
This post has been edited by ldotsfan: Apr 25 2008, 01:24 AM
-
QUOTE(ldotsfan @ Apr 24 2008, 08:40 PM)

PhysicalDrive1 is the second physical hdd attached to the PC, in this case through USB.
Somebody reported that this works for a single IDE connection for the xbox hdd while the rest of the hdd connections are SATA.
-
QUOTE
There's one free software: hdparm for cygwin that claims to support locking functions from Windows but I don't have a freeze lock free BIOS on my notebook to test it. My PC used for xboxhdm work is too low end to run XP properly
You could try the tool to lock a harddisk. If that works, you have a proof it is possible to do it that way. If the harddisk is initially unlocked, your bios won't interfer with it..
I have checked the windows low level disk api's, and couldn't find a way to send raw commands to the harddisk. This indeed means that you have to search it on a lower level, but since the windows atapi drivers are running and controlling the disk, you would need to disable those first....
The same with an usb enclosure. Either, windows sees it as a standard usb disk, and will load it's standard driver, without any locking support, or you can make it appear as a different device, in which case you have to redesign the mass storage driver and add the locking options to it.
regards.
-
QUOTE(obcd @ Jul 22 2009, 03:02 PM)

I have checked the windows low level disk api's, and couldn't find a way to send raw commands to the harddisk. This indeed means that you have to search it on a lower level, but since the windows atapi drivers are running and controlling the disk, you would need to disable those first....
Google for hdparm-6.9-1.src.tar.bz2 , inside hdparm-6.9-1.src.patch, look at the source for rawio.c and rawio.h. That's the source for hdparm for cygwin and the lowlevel stuff you're looking for.
-
I'm trying this again on ubuntu with my usb enclosure configured to hda using Qemu.
I'm getting the error that a xbox partition can't be found. Even with nothing connected to the adapter.
I've been at this for a couple of hours and I'm not even sure if the hard drive is connecting.
I've tried the soundtrack unlock and also the error 12.
-
Mismatch of hda/sda between host OS and qemu? How does ubuntu see the xbox hdd? You can check with dmesg
-
I'm in work at the moment so don't have access to run that utility. Ubuntu doesn't seem to recognise the Xbox HDD though. I have a Western Digital Caviar ready to go into the Xbox (my next project) and Ubuntu recognises it no problem. I'll be home in a few hours and will try that util.
-
Drive is on sdc in Ubuntu, have mapped it to hda in Qemu.
-
This is the output from dmesg:
[ 4644.954170] scsi 21:0:0:0: Direct-Access WDC WD32 00AAJB-00J3A0 3E01 PQ: 0 ANSI: 2 CCS
[ 4644.955213] sd 21:0:0:0: Attached scsi generic sg5 type 0
[ 4644.973419] sd 21:0:0:0: [sdd] 625142448 512-byte logical blocks: (320 GB/298 GiB)
[ 4644.975890] sd 21:0:0:0: [sdd] Write Protect is off
[ 4644.975899] sd 21:0:0:0: [sdd] Mode Sense: 00 38 00 00
[ 4644.975906] sd 21:0:0:0: [sdd] Assuming drive cache: write through
[ 4644.979866] sd 21:0:0:0: [sdd] Assuming drive cache: write through
[ 4644.979876] sdd:
[ 4645.009116] sd 21:0:0:0: [sdd] Assuming drive cache: write through
[ 4645.009133] sd 21:0:0:0: [sdd] Attached SCSI disk
[ 5096.401268] usb 1-2: USB disconnect, address 7
[ 5134.552076] usb 1-2: new high speed USB device using ehci_hcd and address 8
[ 5134.687714] usb 1-2: configuration #1 chosen from 1 choice
[ 5134.703631] scsi22 : SCSI emulation for USB Mass Storage devices
[ 5134.705232] usb-storage: device found at 8
[ 5134.705244] usb-storage: waiting for device to settle before scanning
[ 5139.704377] usb-storage: device scan complete
[ 5139.706167] scsi 22:0:0:0: Direct-Access WDC WD80 EB-28CGH2 4G24 PQ: 0 ANSI: 2 CCS
[ 5139.707143] sd 22:0:0:0: Attached scsi generic sg5 type 0
[ 5139.717556] sd 22:0:0:0: [sdd] 15633072 512-byte logical blocks: (8.00 GB/7.45 GiB)
[ 5139.722979] sd 22:0:0:0: [sdd] Write Protect is off
[ 5139.722995] sd 22:0:0:0: [sdd] Mode Sense: 00 38 00 00
[ 5139.723004] sd 22:0:0:0: [sdd] Assuming drive cache: write through
[ 5139.726915] sd 22:0:0:0: [sdd] Assuming drive cache: write through
[ 5139.726936] sdd:
[ 5139.740225] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.740236] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.740247] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.740259] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.740271] end_request: I/O error, dev sdd, sector 0
[ 5139.740282] __ratelimit: 14 callbacks suppressed
[ 5139.740290] Buffer I/O error on device sdd, logical block 0
[ 5139.754231] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.754243] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.754253] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.754265] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.754276] end_request: I/O error, dev sdd, sector 0
[ 5139.754289] Buffer I/O error on device sdd, logical block 0
[ 5139.771233] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.771245] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.771256] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.771268] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.771278] end_request: I/O error, dev sdd, sector 0
[ 5139.771292] Buffer I/O error on device sdd, logical block 0
[ 5139.786233] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.786246] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.786256] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.786267] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.786278] end_request: I/O error, dev sdd, sector 0
[ 5139.786291] Buffer I/O error on device sdd, logical block 0
[ 5139.802484] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.802496] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.802506] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.802518] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.802529] end_request: I/O error, dev sdd, sector 0
[ 5139.802542] Buffer I/O error on device sdd, logical block 0
[ 5139.802578] ldm_validate_partition_table(): Disk read failed.
[ 5139.818235] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.818248] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.818258] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.818269] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.818281] end_request: I/O error, dev sdd, sector 0
[ 5139.818295] Buffer I/O error on device sdd, logical block 0
[ 5139.835233] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.835245] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.835255] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.835266] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.835278] end_request: I/O error, dev sdd, sector 0
[ 5139.835291] Buffer I/O error on device sdd, logical block 0
[ 5139.851234] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.851247] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.851257] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.851269] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.851281] end_request: I/O error, dev sdd, sector 0
[ 5139.851294] Buffer I/O error on device sdd, logical block 0
[ 5139.867234] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.867246] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.867256] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.867268] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.867279] end_request: I/O error, dev sdd, sector 0
[ 5139.867292] Buffer I/O error on device sdd, logical block 0
[ 5139.867327] Dev sdd: unable to read RDB block 0
[ 5139.894233] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.894246] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.894256] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.894268] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.894279] end_request: I/O error, dev sdd, sector 0
[ 5139.894293] Buffer I/O error on device sdd, logical block 0
[ 5139.910492] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.910506] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.910516] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.910528] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.910539] end_request: I/O error, dev sdd, sector 0
[ 5139.927243] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.927256] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.927267] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.927279] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.927292] end_request: I/O error, dev sdd, sector 24
[ 5139.942243] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.942255] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.942265] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.942277] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.942288] end_request: I/O error, dev sdd, sector 24
[ 5139.957232] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.957245] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.957255] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.957267] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.957278] end_request: I/O error, dev sdd, sector 0
[ 5139.972356] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5139.972368] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5139.972378] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5139.972389] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5139.972401] end_request: I/O error, dev sdd, sector 0
[ 5139.972440] unable to read partition table
[ 5139.979861] sd 22:0:0:0: [sdd] Assuming drive cache: write through
[ 5139.979878] sd 22:0:0:0: [sdd] Attached SCSI disk
[ 5140.002250] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.002263] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.002273] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.002285] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.002297] end_request: I/O error, dev sdd, sector 0
[ 5140.017250] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.017262] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.017273] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.017285] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.017297] end_request: I/O error, dev sdd, sector 8
[ 5140.034233] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.034245] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.034255] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.034266] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.034278] end_request: I/O error, dev sdd, sector 248
[ 5140.049234] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.049246] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.049257] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.049268] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.049280] end_request: I/O error, dev sdd, sector 0
[ 5140.073231] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.073244] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.073254] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.073265] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.073278] end_request: I/O error, dev sdd, sector 0
[ 5140.092364] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.092377] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.092387] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.092398] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.092409] end_request: I/O error, dev sdd, sector 0
[ 5140.106284] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.106297] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.106309] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.106321] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.106334] end_request: I/O error, dev sdd, sector 0
[ 5140.348978] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.348985] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.348990] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.348996] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.349026] end_request: I/O error, dev sdd, sector 0
[ 5140.362212] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.362218] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.362223] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.362228] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.362233] end_request: I/O error, dev sdd, sector 240
[ 5140.374206] sd 22:0:0:0: [sdd] Unhandled sense code
[ 5140.374209] sd 22:0:0:0: [sdd] Result: hostbyte=DID_ERROR driverbyte=DRIVER_SENSE
[ 5140.374213] sd 22:0:0:0: [sdd] Sense Key : Hardware Error [current]
[ 5140.374217] sd 22:0:0:0: [sdd] Add. Sense: No additional sense information
[ 5140.374221] end_request: I/O error, dev sdd, sector 0
Note that the first set of messages refer to the WD Caviar that has been disconnected for about half an hour. Initially I was seeing nothing in dmesg for the IDE adapter but I switched from the USBs at the side of my laptop to the one at the back and was able to see the 320GB drive. Now the laptop is recognising the 8GB Xbox drive but I'm getting the above errors.
I also tried connecting from cold start and dmesg says that the drive is not write-protected. Does this mean that my Xbox has previously been modded and my drive is not even locked? Apologies if that's a stupid question. I just bought this used for $44 a fortnight ago.
This post has been edited by spraoi: Feb 3 2010, 11:24 AM
-
1. ubuntu sees xbox 8gb hdd as sdd but you mapped to sdc? Am I missing anything here?
2. Check if ubuntu comes with hdparm which tells you the security status of the hdd. But an unlocked stock hdd in a unmodded xbox is unlikely. It will boot to an error screen.
3. Alternatively xboxhdm2.1 (a variant of SLAX Linux customized) comes with the necessary hdparm tool.
-
The drive it maps to varies. I tried mapping that drive as hda in Qemu but it can't connect to it. Any idea what the errors mean? I looked and it doesn't look like the box has been chipped. I'll give hdparm a go.
-
Thanks for this tip. It worked really well and really easily. I want to follow up with my experience.
I used a laptop with Windows XP SP3, an IDE to USB attachment and XBoxhdm. I "hotswapped" using the error 12 method.
QEmu 0.12.2 works well. I downloaded the -Lite windows binary from QEmu on Windows.
And I ran QEmu with these parameters
CODE
qemu.exe -L . -m 512 -hda //./PhysicalDrive2 -cdrom linux.iso -boot d -localtime -M pc -parallel none
The biggest difference is -parallel none and no sound. This is because I received IRQ errors. My laptop doesn't have a parallel port and I suppose the default is to attach one. I also removed the sound because of the IRQ errors.
After the IRQ errors I changed the physical drive. ./PhysicalDrive2 is because I kept another USB drive attached to my computer. It was trial and error (either 1 or 2) to find the correct one. I knew 2 was correct because xbrowser worked and the intro for linux displayed the device with the correct size.
Again, thanks for the great tip. You saved me a headache to find a computer with an IDE... Again.
Will
-
QUOTE(wpalmer @ Mar 20 2010, 08:41 PM)

Again, thanks for the great tip. You saved me a headache to find a computer with an IDE... Again.
Thank you for reporting back on your results
-
QUOTE(CimSlunt @ Apr 5 2010, 10:37 PM)

when i open qemu.bat it just opens then closes straight away.
You don't open qemu.bat. google command prompt.