FORUMS
Remove All Ads from XDA

[APP][ROOT] USB MASS STORAGE Enabler v1.6

756 posts
Thanks Meter: 814
 
Post Reply Email Thread
This app is to enable Mass Storage Mode for mounting your Memory Card as a USB Drive in Computer from your rooted device [Android 4.0+]..
It does not mount internal storage, and it will not work if your device doesn't have External Memory Card Support..

Download Link:
UMS Enabler (Universal) v1.6.2.apk
(can also be downloaded from XDA Labs)

(click here for older versions of app)

Steps to Enable UMS:

1. Connect phone using USB cable to Computer or TV or DVD/Audio Player or Mac (or even to other phone with OTG) or whatever.
2. Open the 'UMS Enabler' app and press 'Enable Mass Storage' and give it root access.
(Try 2-3 times if it doesn't work the first time itself)
3. Before disconnecting USB, eject from Computer and then press 'Disconnect Mass Storage' in app.

If it doesn't work, go to App Settings and choose the required settings, and try again.
Avoid using memory card from phone when in UMS mode..

Screenshot:
Click image for larger version

Name:	Screenshot UMS Enabler.png
Views:	4546
Size:	51.3 KB
ID:	3935226

Note:
This will work only if there is USB Gadget support in your kernel..
It is recommended to unmount the memory card from Settings->Storage before enabling UMS, to avoid issues.
(Not required if you don't make changes in memory card from computer, that is, if you're just using for read-only purpose.)
And remount similarly after use.
(required only if /dev/block/mmcblk1 is used, instead of the particular memory card partition mmcblk1p*)


Testers, please try and reply.
If it works, please leave a reply with your device model & ROM (and custom kernel if any) in which it's working so that I can make a list of working devices.

Hit the Thanks button if it worked for you..


Contributors
@GokulNC
@vikasb32 (Material Design)
@maais (Russian Localization)
@WormsWarII (French Localization)

Version Information
Status: Stable
Latest Version: 1.6.2
Last Release Date: 2017-02-26

Created 2015-11-03
Last Updated 2017-02-26

Source Code: https://github.com/GokulNC/USB_Mass_Storage_Enabler
(Feel free to contribute)
Attached Files
File Type: apk UMS_Enabler_1.6.1.apk - [Click for QR Code] (2.31 MB, 13824 views)
File Type: apk UMS_Enabler_1.6.2.apk - [Click for QR Code] (2.32 MB, 6138 views)
The Following 126 Users Say Thank You to GokulNC For This Useful Post: [ View ] Gift GokulNC Ad-Free
 
 
3rd November 2015, 03:42 PM |#2  
GokulNC's Avatar
OP Senior Member
Flag Chennai
Thanks Meter: 814
 
Donate to Me
More
Device Compatibility List
(Only the devices with external memory card support are listed)

Working on Devices:
Warning For These Devices Below:
HTC One M9
The Following 22 Users Say Thank You to GokulNC For This Useful Post: [ View ] Gift GokulNC Ad-Free
8th November 2015, 11:59 AM |#3  
GokulNC's Avatar
OP Senior Member
Flag Chennai
Thanks Meter: 814
 
Donate to Me
More
Changelogs :

To Do in Future:
* Reduce app size
* Automatically start app when USB is connected
* Create Notification when UMS is enabled, to unmount it easily.
* Force Mediascan after Unmount
* Add Dark Theme
* Enable ISO image mounting by selecting a compatible image.
* Find a way to enable ADB alone (in insecure mode)
* Switch completely to my RootShell class from Stericson's RootTools


Click here for latest changelogs: https://github.com/GokulNC/USB_Mass_.../Changelog.txt

v1.5.1 (25-Aug-2016):
-- Added Notification when UMS is enabled to unmount easily.
--fixed this bug in Advanced Settings
-- Removed the AsyncTask which caused high CPU utilization (to get USB Connection Status). Will use a BroadcastReceiver for that in the next Version.

v1.5.0 (21-Aug-2016):
-- Updated to Material Design by @vikasb32
(No changes other than UI)
* Report bugs if any

v1.4:
-- No need to manually unmount memory card (only required if memory card device block (/dev/block/mmcblk1) is directly used, instead of the particular partition mmcblk1p*)
-- Added Advanced Settings (in options) to choose the LUNs and partitions blocks manually from an automatically optimized searched list..

If you're choosing mmcblk1p1, you no need to unmount/remount from Storage Settings.
If you're using mmcblk1, unmount is required.

(Similarly for vold blocks, choose the right one.
For example in my phone, if there are 179:64 and 179:65 in /dev/block/vold/ , 179:64 refers to mmcblk1 and 179:65 refers to mmcblk1p1 )

v1.3:
-- App now automatically checks for External SD Card and presence of FUSE drivers.
-- Partial fix for devices in which it appears as CD Drive in Computer.
-- Properly Handled Exceptions and added Warning messages

v1.2:
--Optimized Code to remove stupid hackarounds & Fixed Bugs
--Added 'Help' page
--Used ProGuard (app size reduced to 34KB)

v1.1:
-- App now automatically disables SE Linux Enforcement thanks to @out386's idea
-- Added option to unmount Mass Storage
-- Changed the background to black

F.A.Q. :

1. "There's no drive for Internal Storage, only the memory card is there."
Solution: This app does not mount internal storage as UMS due to certain restrictions.
(The Internal Storage is actually present inside the /data partition which is formatted as EXT4/F2FS.)
This app can mount only the memory card. (You can try the USB Sharer app (link at bottom) for that purpose.)

2. An empty Removable USB Disk appears, upon clicking which appears "Please insert disk".
Solution:
Go to Advanced Settings and try using some other device block if any..

Also, make sure memory card is
a. inserted & formatted in recognizable file system format like FAT32, vFAT or exFAT.
b. not encrypted / adopted as Internal Storage (Since Android 6.0 Marshmallow, by which it's formatted as an EXT4 partition and encrypted).

3. It shows up as a CD-ROM or DVD (Optical) drive instead of USB (flash) drive, upon clicking which appears "Please Insert Disk / No Disk Inserted".
Quote:
Originally Posted by FrozenCow

The kernel needs support for this. Most stock kernels only have USB-emulation, some stock kernels only have CD-emulation. None of the stock kernels have the ability to switch between the two, that's why a custom kernel is needed. A number of CyanogenMod kernels have support for this.............

4. "It's working, but the drive is mounted as read-only."
(This issue was reported for Asus Zenfone 2)
Solution: Actually, one of the main purpose why this app needs to disable SE Linux is to remove the write-access restriction on memory card.
There might be occasions when even after setting SE Linux to Permissive, the memory card is mounted as read-only drive. In that case, follow these steps:
i. Unmount the memory card from the Storage Settings.
ii. Now 'Enable UMS' and see if you have write-access.
iii. After disconnecting USB, remount/mount the memory card again from Storage Settings.

5. App Force Close: "Unfortunately, app has stopped".
Please send the logcat.

6. "I've tried everything possible & I'm helpless" :
Solution: You can also try this if there's TWRP recovery for your device:
i. Boot into TWRP recovery & connect to USB.
ii. Select the option 'Mount'
iii. Click 'Mount USB Storage' (or something similar).

If that didn't help, you can also try the similar apps below:

Alternate Apps :
If this app doesn't work, there are several other alternative apps (by other developers) you can try:
(Might require SE Linux Mode set to 'Permissive')

Quote:

1. Multi Mount SD-Card ( Lite | Pro )

2. USB Sharer ( Free | Full )

3. SD Card as USB Drive ( Free )

4. DriveDroid ( Free | Paid )
(Only to mount ISO/IMG files to PC using UMS)


Libraries Used :
The Following 13 Users Say Thank You to GokulNC For This Useful Post: [ View ] Gift GokulNC Ad-Free
8th November 2015, 03:13 PM |#4  
Member
Flag Olecko
Thanks Meter: 11
 
More
Works perfectly on my LG L90. I don't have to deal with this stupid MTP anymore. CyanogenMod 11.
The Following User Says Thank You to DoctorRzepa For This Useful Post: [ View ] Gift DoctorRzepa Ad-Free
8th November 2015, 04:46 PM |#5  
OT-Xtreme's Avatar
Senior Member
Thanks Meter: 200
 
More
From my understanding this will work only if you have external sdcard storage.. ?
8th November 2015, 07:06 PM |#6  
Member
Thanks Meter: 10
 
More
Working on my S3 Mini (CM12 ROM by Maclaw) with hard method.

Need some options (like unmount UMS/MTP),but finally I can use UMS on my device!
Thanks!
The Following 2 Users Say Thank You to GFOLDISCOOL For This Useful Post: [ View ] Gift GFOLDISCOOL Ad-Free
8th November 2015, 07:16 PM |#7  
Spookymyo's Avatar
Senior Member
Flag Morristown, TN
Thanks Meter: 173
 
More
How is this different than the xposed module "HandleExternalStorage" which enables writing to the external SD card?
8th November 2015, 07:44 PM |#8  
Senior Member
Thanks Meter: 9
 
More
phone reboot immediately hit soft mode & empty (0bytes) partition on hard mode
onePlus One, 5.1.1 flexOS
9th November 2015, 04:58 AM |#9  
GokulNC's Avatar
OP Senior Member
Flag Chennai
Thanks Meter: 814
 
Donate to Me
More
Quote:
Originally Posted by OT-Xtreme

From my understanding this will work only if you have external sdcard storage.. ?

Yes, this will mount external sd storage only..
Internal storage is actually EXT4 format and is present in /data/media

Quote:
Originally Posted by GFOLDISCOOL

Need some options (like unmount UMS/MTP)

There's an option(button) for MTP.. You can use that.
I will add an option to 'Unmount UMS' soon

Quote:
Originally Posted by Spookymyo

How is this different than the xposed module "HandleExternalStorage" which enables writing to the external SD card?

That module enables read/write operation on memory card for all apps by editing /system/etc/permissions/platform.xml (I think so).
But this app is for enabling USB Mass Storage to mount memory card to computer directly like a flash drive..

Quote:
Originally Posted by mrhamed

phone reboot immediately hit soft mode & empty (0bytes) partition on hard mode
onePlus One, 5.1.1 flexOS

This works only if there's memory card in your device.
One Plus One doesn't have external memory support I think.
The Following 5 Users Say Thank You to GokulNC For This Useful Post: [ View ] Gift GokulNC Ad-Free
12th November 2015, 07:12 AM |#10  
Junior Member
Thanks Meter: 2
 
More
Thanks mate this is awesome its working on cm13.0 no need to download selinux enabler because its already on permisive
The Following 2 Users Say Thank You to xrexzerox For This Useful Post: [ View ] Gift xrexzerox Ad-Free
13th November 2015, 12:08 PM |#11  
GokulNC's Avatar
OP Senior Member
Flag Chennai
Thanks Meter: 814
 
Donate to Me
More
Version 1.1 added
-- App now automatically disables SE Linux Enforcement thanks to @out386
-- Added option to unmount Mass Storage
-- Changed the background to black
The Following 6 Users Say Thank You to GokulNC For This Useful Post: [ View ] Gift GokulNC Ad-Free
Post Reply Subscribe to Thread

Tags
enable usb mass storage, mass storage, mass storage mode, usb mass storage

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread