Used for ejecting the Didj, will also cause it to check for new lighting boot or firmware file versions, and install them if present (Return Buffer Size 0).

0xC7 = Num Device Commands

Not Implemented

0xFF = Device Cmd Undefined

Not Implemented

Sending the commands

All the custom commands are 10 byte, some of the standard SCSI Commands are 6 byte, and may require extra values than 00 for certain bytes. For the Get/Set commands, you'll need to have Byte 1 the second byte, be the number of the setting you want, and for get you'll need to provide a buffer size.

In Windows

Turn on Didj with USB connected. Then open SCSI Utility, under devices look for "LeapFrogDidj" and right click on it, choose 'Execute Custom CDB' which will bring up the Custom CDB dialog.

In BYTE 0 put the Command value, C1,C2,C3...Cn

For BYTE 1 thru BYTE 9 put the value 0 in

For BYTE 10 thru BYTE 15 leave them blank.

CDB Size should equal 10.

For Buffer Size value put 0.

Then click Execute, there will be a warning dialog box, as the wrong command to the wrong drive, could cause serious issues, make sure LeapFrogDidj is the drive selected, and click Yes.

In the Output windows you should get something like "Custom CDB: Custom CDB executed successfuly".

If ejecting, the Didj should change screen images to the Ok to disconnect screen, if unlocking in WinXP Autoplay searches, before coming up with the dialog asking what you want to do.

In Linux

Turn on Didj with USB connected.

Tail your messages with

$ sudo tail -f /var/log/messages

Plug in your Didj to the USB

Look in your messages for something like this

kernel: sd 5:0:0:0: Attached scsi generic sg2 type 0

Your looking for the sg with a number sg0, sg1, sg2 etc.

Make sure you got sg3_utils installed, it came stock with Ubuntu 9.10 for me. The command you'll be using is sg_raw.

To unlock the Didj

$ sg_raw /dev/sg2 C2 00 00 00 00 00 00 00 00 00

To eject the Didj

First unmount the Didj

$ sg_raw /dev/sg2 C6 00 00 00 00 00 00 00 00 00

To lock the Didj

$ sg_raw /dev/sg2 C1 00 00 00 00 00 00 00 00 00

Caution

Double check you got the right device, as the wrong command to the wrong device, can be catastrophic.