# Anybody use iRiver IFP series as USB Mass storage device?

## kwon37xi

iRiver support USB Mass storage device driver for IFP series.

I installed that driver on my IFP-180T.

It works fine with my Windows 98.

But with my gentoo box, It works strangely.

I use another 32MB USB Mass Storage Device, it works very fine on my gentoo box.

dmesg After attaching IFP-180t

------

hub.c: new USB device 00:07.2-2, assigned address 3

usb-uhci.c: interrupt, status 2, frame# 1432

scsi1 : SCSI emulation for USB Mass Storage devices

  Vendor: iRiver    Model: iFP Mass Driver   Rev: 1.00

    Type:   Direct-Access                      ANSI SCSI revision: 02

Attached scsi removable disk sdb at scsi1, channel 0, id 0, lun 0

SCSI device sdb: 256000 512-byte hdwr sectors (131 MB)

sdb: Write Protect is off

 /dev/scsi/host1/bus0/target0/lun0: p1 p2 p3 p4

WARNING: USB Mass Storage data integrity not assured

------

dmesg After mount /dev/sdb1 /mnt/ifp/

 I/O error: dev 08:11, sector 0

  I/O error: dev 08:11, sector 64

  SCSI device sdb: 256000 512-byte hdwr sectors (131 MB)

  usb-uhci.c: interrupt, status 3, frame# 333

  sdb: Write Protect is off

   /dev/scsi/host1/bus0/target0/lun0: p1 p2 p3 p4

---

then if I try 'ls /mnt/ifp', English font is changed to strange characters and if I try 'df' my computer stops and goes down - I have to push reboot button.

I use, gentoo-sources 2.4.20, and the followings are the modules  installed and loaded when I try IFP-180t.

----

Module                  Size  Used by    Not tainted

sd_mod                 11244   4  (autoclean)

ppp_synctty             7220   0  (unused)

ppp_async               8192   1

ppp_generic            18848   3  [ppp_synctty ppp_async]

slhc                    5456   0  [ppp_generic]

nls_cp949             141500   4  (autoclean)

nls_cp437               4348   4  (autoclean)

vfat                   13140   4  (autoclean)

fat                    34648   0  (autoclean) [vfat]

usb-storage            61720   2

usb-uhci               32076   0  (unused)

usbcore                76032   1  [usb-storage usb-uhci]

agpgart                14868   0  (unused)

ne2k-pci                6080   1

8390                    7648   0  [ne2k-pci]

8139too                17448   1

mii                     2672   0  [8139too]

sr_mod                 17464   0  (unused)

sg                     29036   0  (unused)

scsi_mod               93940   5  [sd_mod usb-storage sr_mod sg]

----

I use via board cel 766, USB 1.0. No SCSI device.

Help plz.[/quote]

----------

## DigitalDan

I have the same problem.  I have tried the newer "e" version but it still doesn't work.  Let me know if you solved the problem or if anyone else is using the iRiver with ums.  

Thanks

----------

## Dracnor

Have you seen the ifp project at sourceforge? 

http://ifp-driver.sourceforge.net

I haven't tried UMS, but I am going to look into it tonight.  There were some people on the mailing list who were able to get it to work.  Let me know if you can.

Bill

----------

## DigitalDan

Yeah I used to use that setup but it was all command line or through mc.  Someone devolped a java based utility but it still needed some work on it.  I think that the ums is the best way to go since one can use their own file manager.  

I still have not been able to get the ums to work in linux perfectly.  When I mount the player and browse, it creates jibberish.  EX: 

```
dan@dan mp3Player $ ls *

ifp-1xxt.hex

tuner:

???l?(?g.;k?  d@??????.?c?  tuner000.rec  ??r????*.??x  ??e?[??b.?lm  ???u?k?q.cjz

?????e??.???  n8??oq1+.:,?  y)????zz.]??  ???n??%].??d  ??uywm?].?y?  ??.?;.7??

$????f@?.zif  r?)??pzx.??m  y>????0?.???  ?????ed?.,<?  ??i?????.?/~  ?{s`??:y.?ak

,?tm+?>?.6??  s-??????.|u?  ??u?g.l??     ??(?$??i.?`?  ?8b????z.e?\  ???0^d?j.(m?

voice:

?~?r:???.??j  %?^"?t??.@=+  voice000.rec  ?\?g>?k?.?<n  ????????.???  ??.6?g

???c???b.?c?  +?c5????.4?z  ??9??g??.???  ?b?????v.g?o  ?cx.?p?       ?f?????2.'??

?0et??/?.???  f??'?-bb.?[?  ??[rb???.?ox  ??im=??j.??)  ??{??9 a.???

???;?)??.??8  h??zz?[?.???  ?]????r?.???  ?zu?h???.y1?  ??+?[??z.l4?

$?????ob.e?   p-?????b.???  ??p???lf.?*?  ????*z??.k??  ?????b|?.?[&
```

also it creates 4 sda spots

```
dan@dan mp3Player $ cd /dev/sd

sd    sda   sda1  sda2  sda3  sda4
```

So I don't know if iRiver has actually used the mass storage driver spec.  

P.S.  I tired both the 1.0c and 1.0e driver.  Above output is the 1.0c.  With the 1.0e driver when i try to mount I get a error invalid filesystem or unable to read filesystem, something like that.. cannot remember.  I did have it properly formatted and in fat.

----------

## Dracnor

I tried the UMS firmware, and I could not upload files, although I was able to view the contents of the device.  Not sure what the problem is...

----------

## DigitalDan

Figured out how to use the device.  The file system type needs to be a msdos.  So do a 

```
mount -t msdos /dev/sda /mnt/mp3Player
```

The only problem is that the string length is severly limited.  Hopefully there still is a better way.

----------

## jwells

 *KillerDOC wrote:*   

> Figured out how to use the device.  The file system type needs to be a msdos.  So do a 
> 
> ```
> mount -t msdos /dev/sda /mnt/mp3Player
> ```
> ...

 

to enable long filename support, specify vfat instead of msdos:

```
mount -t vfat /dev/sda /mnt/mp3Player
```

it works well for me on a 2.4.* kernel with the 1.0e UMS firmware.

anyone had any luck getting this to work with  2.6.*?

----------

## erob

 *Dracnor wrote:*   

> Have you seen the ifp project at sourceforge? 
> 
> http://ifp-driver.sourceforge.net
> 
> ....
> ...

 

thx man!

IT WORKS! (i got the IFP-380T - 128MB mem)

anyway I just followed the instructions in the provided readme file. Make sure you have libusb installed (i got dev-libs/libusb-0.1.7-r1)

now i can put my mp3s via midnight commander to my player! 

so long! 

erob

----------

## vent

i just wanted to chime in that i was able to get an ifp-395 working with ums firmware. works like a charm and i love it. can't wait for the ogg support that's supposed to be coming.

btw, i've read that the file transfer is slower if you're using ums. i'm averaging about 0.2M/s with the drive mounted sync, and that does seem a bit slow. what's everyone else's experience with transfer speeds?

----------

## kpoman

Hi!

I have a IFP 380T !

I had it working (not very fast though) with UMS firmware, but under 2.4 kernels !

Now with 2.6 I cant seem to have it working; I have some data to show you, I hope somebody can help me:

```

root@shuttle kpoman # fdisk -l /dev/sda 

Disk /dev/sda: 131 MB, 131072000 bytes

5 heads, 50 sectors/track, 1024 cylinders

Units = cylinders of 250 * 512 = 128000 bytes

   Device Boot      Start         End      Blocks   Id  System

/dev/sda1   ?      939366     8484986   943202437   64  Novell Netware 286

Partition 1 has different physical/logical beginnings (non-Linux?):

     phys=(32, 114, 46) logical=(939365, 4, 12)

Partition 1 has different physical/logical endings:

     phys=(369, 105, 51) logical=(8484985, 1, 35)

Partition 1 does not end on cylinder boundary.

/dev/sda2   ?     7880954    10055022   271758385+  20  Unknown

Partition 2 has different physical/logical beginnings (non-Linux?):

     phys=(378, 121, 37) logical=(7880953, 4, 47)

Partition 2 has different physical/logical endings:

     phys=(357, 117, 46) logical=(10055021, 0, 17)

Partition 2 does not end on cylinder boundary.

/dev/sda3   ?     7675951     8578355   112800441   20  Unknown

Partition 3 has different physical/logical beginnings (non-Linux?):

     phys=(370, 111, 53) logical=(7675950, 3, 1)

Partition 3 has different physical/logical endings:

     phys=(356, 114, 37) logical=(8578354, 0, 32)

Partition 3 does not end on cylinder boundary.

/dev/sda4   ?           1    13538079  1692259840    0  Empty

Partition 4 has different physical/logical beginnings (non-Linux?):

     phys=(0, 0, 0) logical=(0, 0, 1)

Partition 4 has different physical/logical endings:

     phys=(0, 0, 0) logical=(13538078, 3, 30)

Partition 4 does not end on cylinder boundary.

Partition table entries are not in disk order

root@shuttle kpoman # 

```

with kernels 2.4 I used to get /dev/sda1 and /dev/sda2 but now I havent them, I only get a /dev/sda which trhows those errors upt ehre

also doing this:

root@shuttle kpoman # mount -t msdos /dev/sda /mnt/iriver/

mount: /dev/sda: can't read superblock

root@shuttle kpoman # 

So I wonder if someone can help me, or at least tell me it works on their 2.6 machine, so I can try to find what error I could have done,

please help and thanks for reading  :Wink: 

----------

## funkmankey

just got my 180T, using the v3.06 manager firmware for now.

here is an ebuild for ifp-driver:

https://bugs.gentoo.org/show_bug.cgi?id=38730

interested to hear how the v1.11 UMS driver is working for people.... still undecided which one to use.

----------

## gazoombo

Alright. So I've got a nifty little iFP-390T, and I'm using the 1.11 UMS firmware which is wonderful for windows. problem is when I connect it under linux (2.4.22-gentoo-r5) it is recognized as a usb mass storage device and scsi emulation is set up for it, but it doesn't create sda. all I can find under /dev/scsi is a generic character device, but should a UMS be a block device? please help me.  :Confused: 

dmesg output when I plug it it:

```
hub.c: new USB device 00:02.1-1, assigned address 2

scsi1 : SCSI emulation for USB Mass Storage devices

  Vendor: iRiver    Model: iFP Mass Driver   Rev: 1.00

  Type:   Direct-Access                      ANSI SCSI revision: 02

WARNING: USB Mass Storage data integrity not assured

USB Mass Storage device found at 2

```

----------

## gazoombo

hmm I just upgraded my system to 2.6.3.

now when I attach my iFP it creates /dev/sda but when I try to mount I get

'mount: /dev/sda: can't read superblock'

'fdisk -l /dev/sda' shows no partitions.

anyone have this working in 2.6 yet?

----------

## Doublehead

 *gazoombo wrote:*   

> hmm I just upgraded my system to 2.6.3.
> 
> now when I attach my iFP it creates /dev/sda but when I try to mount I get
> 
> 'mount: /dev/sda: can't read superblock'
> ...

 

I have excactly the same problem. Kernel gentoo-dev-sources-2.6.3-r2 and a iRiver 180T with UMS 1.11 firmware. It worked completely when I was running kernel 2.4.

----------

## gazoombo

I've been looking everywhere for kernel patches for this. It seems the iFP line incorrectly reports itself as a removable device even though it cannot be ejected.  Not sure if thats why we're having trouble or not.  I'd really like to get this working because I use mine as a UMS to bring things to and from school.   :Confused: 

----------

## asiobob

have you had any luck with this?

----------

## gazoombo

Yes. I found I patch in the linux-kernel mailing list for the 2.6 kernel that stops the kernel from sending a 'lock' command to the UMS. the iRiver iFP apparently lists itself as removable but can't actually be locked or ejected and therefore hangs on the lock command. Or something like that.

----------

## asiobob

ahh good, you wouldn't happen to have this patch would you?

----------

## gazoombo

```

--- linux/include/scsi/scsi_devinfo.h.orig   2004-01-13 04:03:19.000000000 +0100

+++ linux/include/scsi/scsi_devinfo.h   2004-01-13 04:12:19.509266640 +0100

@@ -19,4 +19,5 @@

 #define BLIST_MS_SKIP_PAGE_08   0x2000   /* do not send ms page 0x08 */

 #define BLIST_MS_SKIP_PAGE_3F   0x4000   /* do not send ms page 0x3f */

 #define BLIST_USE_10_BYTE_MS   0x8000   /* use 10 byte ms before 6 byte ms */

+#define BLIST_NORMB               0x10000 /* Known to be not removable */

 #endif

--- linux/drivers/scsi/scsi_scan.c.orig   2004-01-13 04:03:19.000000000 +0100

+++ linux/drivers/scsi/scsi_scan.c   2004-01-13 04:13:07.728936136 +0100

@@ -536,7 +536,8 @@

       sdev->online = FALSE;

    }

 

-   sdev->removable = (0x80 & inq_result[1]) >> 7;

+   sdev->removable = (((0x80 & inq_result[1]) >> 7) &&

+      !(*bflags & BLIST_NORMB));

    sdev->lockable = sdev->removable;

    sdev->soft_reset = (inq_result[7] & 1) && ((inq_result[3] & 7) == 2);

 

--- linux/drivers/scsi/scsi_devinfo.c.orig   2004-01-13 04:03:19.000000000 +0100

+++ linux/drivers/scsi/scsi_devinfo.c   2004-01-13 04:13:40.591940200 +0100

@@ -183,6 +183,7 @@

    {"SGI", "TP9500", "*", BLIST_SPARSELUN | BLIST_LARGELUN},

    {"MYLEX", "DACARMRB", "*", BLIST_SPARSELUN | BLIST_LARGELUN},

    {"XYRATEX", "RS", "*", BLIST_SPARSELUN | BLIST_LARGELUN},

+   {"iRiver", "iFP Mass Driver", NULL, BLIST_NORMB},

    { NULL, NULL, NULL, 0 },

 };

 

```

I believe that the author of the patch (Javier Marcet) posts on this board also. Although I do not know under what name.

----------

## funkmankey

nb: in the latest kernel sources, 0x10000 in scsi_devinfo.h seems to be reserved for some other device, so the patch may not work anymore without a little tweakage (just change it to 0x12000 or some junk)

----------

## asiobob

hmm so I need to change the firmware to support USB mass storage and I need windows for this :/ I don't have windows.

Any other good players that play mp3 and ogg?

cheers for the heads up funkmankey

----------

## guy

Over at http://ifp-driver.sourceforge.net/, they have a great filesystem module for the iriver iFP's. Install the kernel module and mount the iriver with:

```

mount -t iriver none /mnt/iriver

```

This works with the default firmware and is not needed with the UMS. Transfer speeds seem great..

----------

