[APP][ROOT] SG USB Mass Storage Enabler

Search This thread

MohammadAG

Inactive Recognized Developer
Sep 7, 2009
1,080
5,504
30
Jerusalem
mohammadag.xceleo.org
SG USB Mass Storage Enabler allows you to export your microSD card over USB as a Mass Storage device. It will never be able to export the internal storage on the device.

I originally made this app for myself for the SGS3, as I needed some more flexibility in mounting/unmounting than Easy UMS offered. However, I backed out from releasing it as I thought it wasn't a nice gesture towards Easy UMS's dev.

Features:
  • Allows you to use your microSD card as a USB Mass Storage device.
  • Shortcuts on your homescreen to easily enable/disable USB Mass Storage mode.
  • Warns the user if they try to disable Mass Storage mode without unmounting/ejecting on the PC side.
  • Auto-detect files needed for wider compatibility.
  • Auto-switch to Mass Storage mode when a USB cable is connected and back to MTP when it's disconnected (pro add-on).

Tested working on:
Sony Xperia Z1
Samsung Galaxy Note II (GT-N7100)
Samsung Galaxy SIII (GT-I9300)
Samsung Grand Duos (GT-I9082) - Thanks to wan Mohd in Play Store reviews.
Samsung Galaxy S4 (GT-I9500) - Thanks to taiseer999 in the replies below.
Samsung Galaxy S4 (GT-I9505) - Thanks to Solomon Chow in Play Store reviews.
Samsung Galaxy S4 (SGH-I337) - Thanks to Delyan Georgiev in Play Store reviews.


Screenshots:

godOwHm.png
mHuB6oB.png


Download:
Get it from the Play Store!
2.3.1 APK: http://mohammadag.xceleo.org/public/Android/SGUSBMassStorageEnabler_2.3.1.apk

Support development:
Like the app? Please consider buying the in app pro add-on Thank you :)
 
Last edited:

MohammadAG

Inactive Recognized Developer
Sep 7, 2009
1,080
5,504
30
Jerusalem
mohammadag.xceleo.org
Could you get the app to mount the internal memory of the Galaxy S4 to?

Or is that kinda hard to fix atm according to the Linux filesystem as you described in the app?

I'm asking since it's normal that both the internal and memory card gets mounted when you mount the device.

They way USB mass storage works is by exporting the whole device block over USB. It's the same as connecting the microSD directly to the PC.

S3 onwards, /sdcard is not a partition anymore, it's faked using fuse and is actually located in /data/media. So to export it you'd need to unmount /data. I've never tried that but I'm guessing it'd cause some serious problems if the device is online, and it'll cause some data loss since I'm sure you'd need to force the unmount.

And even after succeeding with the above, you'll be greeted with a Windows error since it can't read ext3/4, so it's useless for most users.

TL;DR it can't be "fixed". It's a limitation in both UMS and how you can't simultaneously mount a partition on two devices without causing some damage.

Sent from my GT-N7100 using xda app-developers app
 

Tom-Helge

Senior Member
They way USB mass storage works is by exporting the whole device block over USB. It's the same as connecting the microSD directly to the PC.

S3 onwards, /sdcard is not a partition anymore, it's faked using fuse and is actually located in /data/media. So to export it you'd need to unmount /data. I've never tried that but I'm guessing it'd cause some serious problems if the device is online, and it'll cause some data loss since I'm sure you'd need to force the unmount.

And even after succeeding with the above, you'll be greeted with a Windows error since it can't read ext3/4, so it's useless for most users.

TL;DR it can't be "fixed". It's a limitation in both UMS and how you can't simultaneously mount a partition on two devices without causing some damage.

Sent from my GT-N7100 using xda app-developers app
Ok, thank you for your quick answer :good::D
 
  • Like
Reactions: MohammadAG

MohammadAG

Inactive Recognized Developer
Sep 7, 2009
1,080
5,504
30
Jerusalem
mohammadag.xceleo.org
@MohammadAG

I'm using the Android File Transfer desktop app on a Mac now. Would this have any conflicts that you'd know of? Thanks!

This should be the same as plugging in a normal flash drive. So no, there shouldn't be any conflicts. :)



Not working on Verizon Galaxy S4 SCH-I545. Any way to make this happen?

In a terminal emulator or using adb, type the command
Code:
 find /sys -name lun*

and post the output.

Sent from my GT-N7100 using xda app-developers app
 

eah7271

New member
May 29, 2013
3
0
This should be the same as plugging in a normal flash drive. So no, there shouldn't be any conflicts. :)





In a terminal emulator or using adb, type the command
Code:
 find /sys -name lun*

and post the output.

Sent from my GT-N7100 using xda app-developers app

sh-4.2$ find /sys -name lun*
/sys/devices/virtual/android_usb/android0/f_mass_storage/lun
/sys/devices/platform/msm_hsusb/gadget/lun0
sh-4.2$
 

MohammadAG

Inactive Recognized Developer
Sep 7, 2009
1,080
5,504
30
Jerusalem
mohammadag.xceleo.org

dtm4lifebaby

New member
Sep 27, 2010
3
1
I'm still unable to get your app working with Verizon S4. When I enable the feature, my phone launches the verizon installer on the PC for about 5 seconds, then goes back to MTP
 
Last edited:

Majesty00

Senior Member
Aug 10, 2010
54
15
Hello,

No surprise here, but it doesn't seem to work with a Galaxy Nexus (I9250). Too bad, I hate MTP!

Anyway, thanks! :)
 

Top Liked Posts

  • There are no posts matching your filters.
  • 193
    SG USB Mass Storage Enabler allows you to export your microSD card over USB as a Mass Storage device. It will never be able to export the internal storage on the device.

    I originally made this app for myself for the SGS3, as I needed some more flexibility in mounting/unmounting than Easy UMS offered. However, I backed out from releasing it as I thought it wasn't a nice gesture towards Easy UMS's dev.

    Features:
    • Allows you to use your microSD card as a USB Mass Storage device.
    • Shortcuts on your homescreen to easily enable/disable USB Mass Storage mode.
    • Warns the user if they try to disable Mass Storage mode without unmounting/ejecting on the PC side.
    • Auto-detect files needed for wider compatibility.
    • Auto-switch to Mass Storage mode when a USB cable is connected and back to MTP when it's disconnected (pro add-on).

    Tested working on:
    Sony Xperia Z1
    Samsung Galaxy Note II (GT-N7100)
    Samsung Galaxy SIII (GT-I9300)
    Samsung Grand Duos (GT-I9082) - Thanks to wan Mohd in Play Store reviews.
    Samsung Galaxy S4 (GT-I9500) - Thanks to taiseer999 in the replies below.
    Samsung Galaxy S4 (GT-I9505) - Thanks to Solomon Chow in Play Store reviews.
    Samsung Galaxy S4 (SGH-I337) - Thanks to Delyan Georgiev in Play Store reviews.


    Screenshots:

    godOwHm.png
    mHuB6oB.png


    Download:
    Get it from the Play Store!
    2.3.1 APK: http://mohammadag.xceleo.org/public/Android/SGUSBMassStorageEnabler_2.3.1.apk

    Support development:
    Like the app? Please consider buying the in app pro add-on Thank you :)
    12
    Hey Guys

    I have successfull modified SG USB Mass Storage Enabler so it working with Kitkat...

    It only one tested with a i9505 Device with PAC 4.4 installed!!

    EDIT: 2 User with other jflte Device report me it works too (jfltexx, jflteatt and jfltecan) so i'm sure all jflte based Devices work!

    If you want have it with a another Device such as Note2, S3 or other Sammy-Device go in your Device and search /dev/block/vold and give me the Info what the Name of the files in this Folder stored (its called179:XX)

    I will made a specially Version for this Device


    Info for @MohammadAG

    I have changed with MultiTool following Smalifiles:
    ae.smali line 501 from const-string v1, "/dev/block/vold/" to const-string v1, "/dev/block/vold/179:33"
    MainActivity.smali from const-string v3, "/dev/block/vold/" to const-string v3, "/dev/block/vold/179:33"

    When you now add a Value to use the right 179:XX File for the different Devices, think with that is the App usable with KitKat again
    9
    Could you get the app to mount the internal memory of the Galaxy S4 to?

    Or is that kinda hard to fix atm according to the Linux filesystem as you described in the app?

    I'm asking since it's normal that both the internal and memory card gets mounted when you mount the device.

    They way USB mass storage works is by exporting the whole device block over USB. It's the same as connecting the microSD directly to the PC.

    S3 onwards, /sdcard is not a partition anymore, it's faked using fuse and is actually located in /data/media. So to export it you'd need to unmount /data. I've never tried that but I'm guessing it'd cause some serious problems if the device is online, and it'll cause some data loss since I'm sure you'd need to force the unmount.

    And even after succeeding with the above, you'll be greeted with a Windows error since it can't read ext3/4, so it's useless for most users.

    TL;DR it can't be "fixed". It's a limitation in both UMS and how you can't simultaneously mount a partition on two devices without causing some damage.

    Sent from my GT-N7100 using xda app-developers app
    7
    Test this with following:

    echo /dev/block/vold/179:XX > /sys/devices/platform/s3c-usbgadget/gadget/lun0/file
    echo /dev/block/vold/179:XX > /sys/devices/virtual/android_usb/android0/f_mass_storage/lun_ex/file
    echo /dev/block/vold/179:XX > /sys/devices/virtual/android_usb/android0/f_mass_storage/lun/file
    echo /dev/block/vold/179:XX > /sys/devices/virtual/android_usb/android0/f_mass_storage/lun0/file
    echo /dev/block/vold/179:XX > /sys/devices/platform/msm_hsusb/gadget/lun0/file

    Use as XX at first 8 and then 0

    Report me witch Number works, i create a specially for I9500

    EDIT: I have created one for i9500, for the S3 and for the Galaxy Note 2, please test and report
    5
    I fixed the issue locally but only for the Note 3, I'll implement a KitKat workaround soon. This is because of Google's new "no apps can write to SD card" policy.

    Sent from my C6903 using Tapatalk