I just got a Dane-Elec PhotoMate Combo SmartMedia/CompactFlash reader
manufactured by SCM Microsystems. It is a USB device with ID 04e6:0005.
The http://www.qbik.ch/usb/devices/ list of supported devices
calls this thing unsupported, and [email protected] writes:
"I want this to work ! I'll help testing."
I think the status can be changed to fully supported, at least
it works fine in my first tests.
Changes required:
(i) in sd.c there is a peculiar code fragment that assumes
that a removable disk is write protected in case the status is unknown;
reversing this default allows writing to the flash card.
if (the_result) {
- printk("%s: test WP failed, assume Write Protected\n", nbuff);
- rscsi_disks[i].write_prot = 1;
+ printk("%s: test WP failed, assume Write Enabled\n", nbuff);
} else {
rscsi_disks[i].write_prot = ((buffer[2] & 0x80) != 0);
(ii) this card needs usb/storage/dpcm.c which is compiled when
CONFIG_USB_STORAGE_DPCM is set, but this variable is missing
from usb/Config.in. Add it.
(iii) add to unusual_devs.h:
diff -u --recursive --new-file ../linux-2.4.3/linux/drivers/usb/storage/unusual_devs.h ./l\
inux/drivers/usb/storage/unusual_devs.h
--- ../linux-2.4.3/linux/drivers/usb/storage/unusual_devs.h Sun Apr 1 20:44:19 2001
+++ ./linux/drivers/usb/storage/unusual_devs.h Sat Apr 28 14:39:20 2001
@@ -79,6 +79,12 @@
"CameraMate (DPCM_USB)",
US_SC_SCSI, US_PR_DPCM_USB, NULL,
US_FL_START_STOP ),
+
+UNUSUAL_DEV( 0x04e6, 0x0005, 0x0100, 0x0208,
+ "SCM Microsystems Inc",
+ "eUSB SmartMedia / CompactFlash Adapter",
+ US_SC_SCSI, US_PR_DPCM_USB, NULL,
+ US_FL_START_STOP ),
#endif
Maybe the device is slow, and I got read errors with a Compact Flash
card in the reader at boot time. A "blockdev --rereadpt /dev/sdX" worked.
Andries
On Sat, Apr 28, 2001 at 05:02:21PM +0200, [email protected] wrote:
> I just got a Dane-Elec PhotoMate Combo SmartMedia/CompactFlash reader
> manufactured by SCM Microsystems. It is a USB device with ID 04e6:0005.
>
> The http://www.qbik.ch/usb/devices/ list of supported devices
> calls this thing unsupported, and [email protected] writes:
> "I want this to work ! I'll help testing."
>
> I think the status can be changed to fully supported, at least
> it works fine in my first tests.
>
> Changes required:
> (i) in sd.c there is a peculiar code fragment that assumes
> that a removable disk is write protected in case the status is unknown;
> reversing this default allows writing to the flash card.
This is an unsafe assumption. The code fragment you call "peculiar" is
definately necessary.
> (ii) this card needs usb/storage/dpcm.c which is compiled when
> CONFIG_USB_STORAGE_DPCM is set, but this variable is missing
> from usb/Config.in. Add it.
This config option is considered so immature that it's not ready for the
kernel config, even as an EXPERIMENTAL. Use it at your own risk.
Matt
--
Matthew Dharm Home: [email protected]
Maintainer, Linux USB Mass Storage Driver
A female who groks UNIX? My universe is collapsing.
-- Mike
User Friendly, 10/11/1998
From: Matthew Dharm <[email protected]>
> (ii) this card needs usb/storage/dpcm.c which is compiled when
> CONFIG_USB_STORAGE_DPCM is set, but this variable is missing
> from usb/Config.in. Add it.
This config option is considered so immature that it's not ready for the
kernel config, even as an EXPERIMENTAL. Use it at your own risk.
Of course. But the choice is simple. Without it, one has a non-functional
device. With it, one has a device that works beautifully.
I would seriously argue with the "works beautifully" part of that.
The DPCM code relies on the SDDR09 code, which is horrendously buggy. It's
also being actively worked on. I can crash it at will with relatively
simple operations.
Matt
On Sun, Apr 29, 2001 at 02:21:11PM +0200, [email protected] wrote:
> From: Matthew Dharm <[email protected]>
>
> > (ii) this card needs usb/storage/dpcm.c which is compiled when
> > CONFIG_USB_STORAGE_DPCM is set, but this variable is missing
> > from usb/Config.in. Add it.
>
> This config option is considered so immature that it's not ready for the
> kernel config, even as an EXPERIMENTAL. Use it at your own risk.
>
> Of course. But the choice is simple. Without it, one has a non-functional
> device. With it, one has a device that works beautifully.
--
Matthew Dharm Home: [email protected]
Maintainer, Linux USB Mass Storage Driver
NYET! The evil stops here!
-- Pitr
User Friendly, 6/22/1998
>>> This config option is considered so immature that it's not ready for
>>> kernel config, even as an EXPERIMENTAL. Use it at your own risk.
>> Of course. But the choice is simple. Without it, one has a non-functional
>> device. With it, one has a device that works beautifully.
> I would seriously argue with the "works beautifully" part of that.
> The DPCM code relies on the SDDR09 code, which is horrendously buggy.
> I can crash it at will with relatively simple operations.
Let me be more precise then.
The commands
blockdev --rereadpt /dev/sdb
mount /dev/sdb1 /f -t msdos
mv /f/dcim/100mlt01/* .
umount /f
copy the digital camera images written by a Minolta from a Compact Flash
card to the current directory and empty the card. This is the part that
works beautifully (since it works).
(One of these days I must look more at the rereadpt part of this.
After removing the card, I still have the partition /dev/sdb1,
which is an error.)
Andries