yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] CodeKiller:
Galaxy S4 LTE

I confirm for the Galaxy S4 (like just above).

Official Samsung ROM with latest patch available trought Kies in Feb.

I see a letter drive but if I click on it it says "insert disk".
[Android Apps and Games] gortys:
Can you tell which kernel on which smartphone you install to get fuse drivers support?

Using HTC One M9 with Sense 7/Marshmallow/rooted rom.

Thanks.
[Android Apps and Games] leris2:
Hard mode works on LG G3 marshmallow.

Thank you

Στάλθηκε από το LG-D855 μου χρησιμοποιώντας Tapatalk
[Android Apps and Games] birdibird:
Both soft and hard mode work on BQ M4.5 stock 5.1 rom
[Android Apps and Games] nextheart:
Working in my Redmi 1S with CM12 & CM13 Roms. Thank you Gokul for this app.
[Android Apps and Games] lucky_sidhu:
I am not sure but my Sandisk class 10 is giving 6 mb RW speed
[Android Apps and Games] Souf0:
Hi,

Samsung Galaxy S2 (i9100) with CM13: don't work.

Regards
[Android Apps and Games] Sneakyghost:
HTC One M9 with Firmware 3.35.401.12 and ViperOneM9 ROM based on same RUU version 3.35.401.12 - almost stock setup in regards of kernel and drivers. There aren't any modifications in that ROM for that phone that interfere with the storage drivers. So this should theoretically work.

However, choosing soft UMS leads to broken MTP (cannot be re-enabled) and on reboot, SystemUI and Prism (HTC's launcher) don't load their UI anymore = black screen.

Fix: reflash ROM dirty, without wiping app and system app data.

Very frustrating, especially, since the HTC One M9 from Sprint (US carrier) still has UMS, as far as I know.
[Android Apps and Games] BigJim.T32:
Confirmed working on my rooted i9505, running Cm12.1, no other alterations to kernel, etc.. other than what came installed with CM.

- Soft Method; Working.

- Hard Method; Working.

- Unmount UMS; Working.

- Enable MPT Mode; Possible User-Issue (see below)

However, there is something to bear in mind.

When I first used the app, and saw the black screen with the 4x buttons...;

[ENABLE UMS Soft Method] <- I assumed simply hitting one of these two upper buttons would make my card instantly mount via UMS

[ENABLE UMS Hard Method]

[Unmount UMS] <- I assumed simply hitting one of these two lower buttons would instantly return me to MPT

[Enable MPT Mode]

..I assumed that from a user's point of view, one would simply hit Enable UMS (either hard or soft), and that then the SD card would be visible in Windows, and behave as we all expect it to.

However, what I had to do was to enable UMS in your app, and then go to Android's Storage Settings menue, and from there hit the option to mount as UMS.

Doing only one or the other did not work for me (not sure if this is expected behavior or not?)

*This* is what enabled UMS for me. Until I did this, I was able to see the SD card in Windows, but it reports "Please insert a disk into drive \xxx" when I tried to access the SD Card in Windows.

So, anyone who is reporting it as not working, just check & make sure you went into Storage Settings, and if the option exists to switch mode (as it does in CM12/12.1), that you've got UMS ticked in this menue.

- ISSUE WITH "Enable MPT Mode"

When the phone is plugged-in to the PC via USB cable, and is mounted via UMS, the user has the ability to hit the Enable MPT Mode button.

When this is done, the user would expect the phone to instantly switch to MPT mode, and then for both the Phone Storage, and SD card to become accessible in Windows explorer, just like it does when you connect via MPT normally.

- What happens however, is the Phone Storage does not appear as a connected device.

- The SD Card is still visible as a connected device, but trying to access it in Windows Explorer brings the error message "Please insert a disk into drive \xxx".

If one wishes to connect via UMS, and then later switch back to MPT without physically disconnecting the device from your computer (for example to access the phone's internal storage), it seems the way to achieve this is to either un-mount UMS using your app's Unmount UMS button, or via the regular Windows disconnect USB device function (in the sys-tray).

Then, go to Storage Settings in Android, and select MPT mode from there.

At least, this is the behavior I've found while using the app with CM12.

[MENTION=6319272]GokulNC[/MENTION]; Seriously excellent work, I'm loving this! :good::good::good:

Really happy, proper UMS is the final thing I was hoping to get in place having moved to the i9505 from my S2, it was seriously getting on my t*ts that I was seemingly stuck with MTP...

I've tried to be as specific in my feedback as possible with the aim of helping you refine the app further - hope this helps! :)
[Android Apps and Games] S /\ E E D:
Hi, not working on my samsung galaxy s3 ( GT-I9300 ) with cm13.0 official ROM ( with cm stock kernel ) ...
[Android Apps and Games] cooltide:
Mate 8 Working

Working on my Huawei Mate 8, rooted Stock ROM Version NXT-C900B162 ...

Excellent work!!
[Android Apps and Games] TKPL:
Not working on Oppo Find 7a (with external SD)... :(
[Android Apps and Games] GokulNC:
Oh I didn't expect that to happen..

This app disables your SE Linux Enforcement (just by setenforce 0 command).

So I guess that's what caused the crashes and FC's.. (Maybe your device's system is heavily modified or kernel is not properly implemented) :/

1. (I guess) The reason why you need to go to Settings (in your device's CM) to enable UMS to work is that maybe your ROM uses a different mode (property) name for the UMS USB config. Universal default is 'mass_storage' and/or 'mass_storage,adb' (maybe with combination of other modes too)

2. Same reason why 'Enable MTP' doesn't work.. Default property name is 'mtp' or 'mtp,adb'
[Android Apps and Games] Vannyp:
When i try to install kingroot in my smartphone, it says an same application with same name exist but there in no kingroot app in my device, what to do?
[Android Apps and Games] BigJim.T32:
Understood, and that makes sense...

I reiterate, none of that is meant to take away from the pure utility of the app - it works perfectly for my needs; It enabled UMS, and using CM's Storage>Settings menu, I can toggle between MPT and UMS as I like - excellent.

Honestly, it makes me horny that I've got real UMS back. :D

I was simply trying to be as specific in my feedback as possible so that you had a user's PoV from someone using Cm12.1 - I could tell from the rest of the thread that not every device and rom combination can give detailed feedback so I just wanted to see if I could help with some detailed info...
[Android Apps and Games] PrinceThePrince:
Thanks man, worked hard method on Titan (Moto G2) CM13
[Android Apps and Games] RayeR:
Universal MASS STORAGE Enabler doesn't work for me on Galaxy S3-i9300 with CM13. There's appear mass storage device and drive letter on PC but it doesn't recognize FS and volume label of SD card.

I found that for some reason the block device /dev/block/vold/public:179_17 which should represent the SD doesn't work when mounted by mass storage apps. Instead it works with /dev/block/mmcblk1 directly. But I got read-only mode. I found that I need to elevate SE linux permissions to make it RW, so:

1) installed SELinuxModeChanger 3.2.apk and switched to permissive mode

2) installed SD card as USB drive 1.1.apk (MTP USB Switcher) and manually enter the device path to be: /dev/block/mmcblk1 (I think you could add this option to your app too)

3) switch to UMS mode by desktop icon and now it works fine with RW access.

OMFG, finally after a day and night of searching...
[Android Apps and Games] GokulNC:
That's what this app does..

No idea why you needed to do that manually..
[Android Apps and Games] RayeR:
I tried with another FAT formatted SD card and same problem. So I think it's good to have some option to manually enter the device path (via dialog or config file) - it will make it more universal...
[Android Apps and Games] Realz4747:
Thanks man!
[Android Apps and Games] jsauser11:
I have the same issue on Galaxy S3-I747 with CM13 nightly. Using Enabler causes a drive to show up in Windows, but no files or directories.

Can you elaborate on the method you used to get around this? I just want read access to my SD Card, so maybe a way to change the device path only or do I need to do the entire ModeChanger/MPT/USB switcher?

Thanks for any guidance you can provide.
[Android Apps and Games] BigJim.T32:
I didn't have to follow the sames steps as RayeR, but I'm guessing he means using these two apps;

SELinuxModeChanger,

and...

SD card as USB drive...

The first app, once set to permissive will run it's script upon each boot, requiring no further action from the user, and the second requires the user to manually enter the device path in it's settings.

I could not tell you if the same path "/dev/block/mmcblk1" would work for you (perhaps the required path in Marshmallow/CM13 is different to that provided by the app in this thread?), but that's the process I understood from the above post... :eek:
[Android Apps and Games] jsauser11:
Thanks. I was hoping to try just changing the block device as RayeR did as I only need read access with the USB Mass Storage as he seemed to do before he went to the permissive change and path change which he required for RW access. Is there any way to try that from a term. emulator with root?
[Android Apps and Games] RayeR:
Yes, I meant this app: https://play.google.com/store/apps/details?id=com.rotturm.mtpusbswitcher

Yes, you can simply do it in terminal (but need to do probably on every restart of device or maybe card insertion, etc)

echo /dev/block/mmcblk1 > /sys/devices/platform/s3c-usbgadget/gadget/lun0/file

first check if you also have the LUN file /sys/devices/platform/s3c-usbgadget/gadget/lun0/file as I have and correct the path. The device /dev/block/mmcblk1 can be simply guessed from listing of cat /proc/partitions, see mine:

http://rayer.g6.cz/hardware/galaxys3/mount.txt

You can join to please GokulNC to add an option for manual settion of the device. I really have no clue why device /dev/block/vold/public:179_17 mounted on /mnt/media_rw/SD_2GB_FD doesn't work via mass storage while it can be accessed inside phone. If you are OK with RO access you don't need to change SELinux mode. Maybe there's is more clear way to define a rule in SELinux to allow R/W access only for mass storage provider application instead globally changing to permisive mode but I'm not a Linux guru...
[Android Apps and Games] jsauser11:
Thanks for the reply. Checked /sys/devices/platform and there is no s3c-usbgadget directory there for the LUN. Maybe in a different place on mine since it is an I747?
[Android Apps and Games] aejaz123:
Not working on my samsung s3 neo gt i9300i, cm 12.1 by Rox, Kernel v2.1-zram by renix63
[Android Apps and Games] RayeR:
Try to search search some *usbgadget* e.g. via total commander somewhere in /sys/.

I didn't tried any other CM rom than CM13 mod by Tamasek here from XDA forum so I cannot tell how much it can differ for various CM ROMs and phones. I think it depends on kernel configuration - during compilation or what kernel params are passed to kernel by bootloader.
[Android Apps and Games] jsauser11:
Thanks for the tip. I searched /sys/ with ES File Explorer with target "usbgadget" and came up with a null result. Maybe it isn't installed correctly. On the windows end, when I run the Universal Mass Storage Enabler and connect the phone, the drive icon that shows up has windows driver samsung usbgadget, so I am guessing all is well on that end. All this just to get the music files on my phone to show up an a windows music library on my laptop. Thanks again for trying to help.
[Android Apps and Games] RayeR:
BTW for R/W access without needing to change SELinux mode I was trying to modify

/system/etc/permissions/platform.xml

as described here but it doesn't work on Marshmallow. I then tracked the access error in log via

cat /proc/last_kmsg | grep avc

and got result:

<36>[ 1045.427074] c0 type=1400 audit(1460597838.520:54): avc: denied { write } for pid=897 comm="file-storage" path="/dev/block/mmcblk1" dev=tmpfs ino=1133 scontext=u:r:kernel:s0 tcontext=u:object_r:block_device:s0 tclass=blk_file permissive=0

So we can see that for peocess file-storage was denied the write access to device /dev/block/mmcblk1 but I don't know how/where to write right rule to allow it...
[Android Apps and Games] GokulNC:
It's not about adding an option for manual selection for device-point location.. :)

Facts to note:

1. The default device-point location I've set in this app is: /dev/block/mmcblk1

(It's universal for all Android Devices which supports External Memory Card.

I don't know why you're asking set it manually, while the app does it automatically (when UMS enabled).

2. If a kernel has been implemented with fuse point drivers, the lun-file is by default symlinked to /sys/devices/virtual/android_usb/android0/f_mass_storage/lun/file .

(No need to search in /sys/devices/platform/ )

Without fuse drivers, enabling UMS is not possible, as I said in the OP :)
[Android Apps and Games] RayeR:
Aha, I didn't know this. But then I wonder why MTP USB switcher 1.1 works and your program doesn't. This program missing mount/unmount buttons so it's a bit anoyng that I must go to settings. If you have some logging feature I can try again to trace the problem...

EDIT: I just checked that I don't have valid path: /sys/devices/virtual/android_usb/android0/f_mass_storage/lun/file

but instead I have /sys/devices/virtual/android_usb/android0/f_mass_storage/lun0

where lun0 is a symlink to /sys/devices/platform/s3c-usbgadget/gadget/lun0 (and there's a "file").
[Android Apps and Games] jsauser11:
I am running Kernel version 3.4.111-cyanogenmod-g58d1f62. How do I tell if it has FUSE drivers in the kernel?
[Android Apps and Games] GokulNC:
The easiest way in our case would be:

1. Open ES Explorer and go to /sys/devices/

2. Just search "lun"

If you get any folder named lun or lun0 or lun1, inside which there's a file named "file", it means there's a facility to mount a logical partition..
[Android Apps and Games] GokulNC:
Version 1.2 added

--Optimized Code & Fixed Bugs

--Added 'Help' page ;)

--Used ProGuard (app size reduced to 34KB)

( [MENTION=1110685]RayeR[/MENTION] It should work for you now :))
[Android Apps and Games] RayeR:
Good job, it works now (I tried soft method) :)

Do I still need to have SELinux mode=permissive for R/W access or can your app grant write access itself?

UPDATE: OK I checked that if I set enforcing mode the application is able to switch it to permisive mode once I click enable UMS. So SELinux Mode Changer is not neccessary.
[Android Apps and Games] KaMyKaSii:
It would be possible to turn the app on an Xposed module and add this option natively in the USB settings of the system itself?
[Android Apps and Games] RayeR:
It seems that I still need to remount the SD card via Settings|USB storage|removable storage because if I didn't do it file browser in the phone was not able to see newly uploaded files. Yes, I pressed "Umount UMS" button before I disconnected USB cable. It was written successfully on SD but Android doesn't know about it. After I remount SD via settings and reload the directory in file manager I can see new files.
[Android Apps and Games] cooltide:
TWRP Impact?

As of recently I cannot access the SD card via TWRP anymore. No idea whether this is linked to UMS Enabler. Anybody shares this experience? Thx much!
[Android Apps and Games] RayeR:
I use TWRP 2.8.7.0 with F2FS support and I can mount and browse my SD card from there without problem. I use UMS Enabler every day from v1.2 was released.
[Android Apps and Games] 4833478abc:
Hey. After whole night of reading that it is "impossible" to do mass storage on Lollipop I found your app and it works! You are a genius sir, I shall offer you a beer. The phone is Xiaomi Redmi 3 with Lollipop 5.1.1 and some fishy MIUI 77.1.1.0 (double seven) probably installed by AliExpress seller because he also added multilanguage and Google Play to the phone. I only tested this on Linux MINT 17.3 so far. Works awesomly smooth, the only detail is that after writing files into the SD card the phone doesn't see them until I re-mount the card in the settings which has already been mentioned here.

[edit 10:43]

Works on Win 8 as well! Funny thing is that when I delete a file from SD card through the Mass Storage it is still fully accessible on the phone before re-mounting the card. I was expecting to see the files on the list but get an error when trying to access them, but the pictures I deleted are still there and I can view them normally. Interesting.
[Android Apps and Games] tennyleaz:
Not working on Galaxy S5 (lolipop 5.1).

Phone shows as an optical disk drive in PC, clicking it wont do anything...
[Android Apps and Games] ak117:
Also worked for me

Device:- Yu yunique ???
[Android Apps and Games] KaMyKaSii:
[MENTION=6319272]GokulNC[/MENTION], could you explain me how it is possible to mount the memory card in mass storage without desmount? Because it is still accessible by phone, and it seems impossible. I also want to know if it is normal the memory card be linked in two different places after enabling mass storage (I activated the write permission on the memory card in Lollipop). And on the SuperSU screenshot, if I send the same command by the terminal emulator but with the way of userdata, I can access the internal memory by PC while Android is running? Or the fact that the partition is ext4 will not work?
[Android Apps and Games] PetrSP7:
SG Note II GT-N7100

Works fine on this device (I am on ROOTED 4.4.2 but stock ROM N7100XXUFND3 with some tweaks only).

EDIT:

Arrrgh! I was too optimistic ... :rolleyes: Files transferred or deleted with TCMDR are (in device file manager) with no change : adding and / or deleting them I can see correctly on my PC when as UMS connected, but no real changes on microSD., sorry. :(
[Android Apps and Games] Tomo123:
Works on LG Spirit 4G LTE, with sort mode. I could kiss you for this! Thanks, dev!
[Android Apps and Games] sotoLOTO-:
Ditto the last post! Works on stock LG Spirit 2015. FW is v10h-eur-xx; lollipop 5 0 1.
[Android Apps and Games] GokulNC:
Actually you have to go to Settings->Storage and unmont your Memory Card before enabling UMS...

(I forgot to say that in post..)

If you don't, then the changes made in memory card in computer will not be reflected back to phone..

And, when you use memory card in phone, some new files (added from PC) might get corrupted..

So always unmount external SD Card before enabling UMS.

BTW, you can use Internal Storage, nothing will happen.

But don't use memory card in phone when UMS is enabled.

Remount it from Settings->Storage when you're done.
[Android Apps and Games] austin69:
Thanks mate this is awesome its working
[Android Apps and Games] sotoLOTO-:
Thanks a lot for the sweet app. I follow your recommendations but no matter what I do I cannot access the internal storage on my LG spirit 2015 on lollipop 5 0 1. Am I missing sth here?
[Android Apps and Games] Tomo123:
Same here, on LG Spirit H440N, 5.0.1, kernel 3.10.49.

External SD is accessible without issues, but no internal storage, although the drive is shown in the Windows Explorer.
[Android Apps and Games] sotoLOTO-:
For me the drive of the internal storage is NOT shown in the Windows Explorer.
[Android Apps and Games] GokulNC:
This app is for Memory Card only (External SD Card), not for Internal Storage, as I said in the OP :)
[Android Apps and Games] sotoLOTO-:
I guess the text I bolded and underlined from your post I'm quoting is what made me think your app allows browsing the internal memory. I now understand what you actually meant. Nevertheless, thanks for the work! :) Nice app! I guess if you talk to someone like alray who helped me a lot in this thread you might even get Tasker to automatically unmount ex sd card upon launching your app and that would make everybody's life easier :) ! Tasker rlz! :)
[Android Apps and Games] Tomo123:
I misunderstood, just like jonathansmith did :)

No problem, dev, since the external memory card mass storage support is wonderful on itself.

Helped me transfer important documents off an old as Moses Windows XP PC that had no internet connection :) I had no memory sticks at the time and it was a time sensitive situation. Phew!

I tip my hat to you.
[Android Apps and Games] gkdmin24:
Working on LG G Pro 2 CM13! Thanks!! 3x speed than MTP.
[Android Apps and Games] mapcar:
Hi, can you describe what exactly happens? On my Redmi 3 I still don't have mass storage option in usb settings, while app says what mass mode is on and finally in Linux I see two unmountable usb devices and a CD-ROM device with Readme:

"This directory contains the raw data that OEMs want to expose

to end-users.

Due to the limitation of mass storage. The cdrom ISO file should

be larger than 600KBytes.

If you put less files into this directory. Then it will create

a dummy file to fill the gap."

Yet. still no access to phone's data =(
[Android Apps and Games] sotoLOTO-:
I second the 'I shall offer you a beer' idea! What a fantastic proposition! :)
[Android Apps and Games] GokulNC:
Version 1.3 added

-- 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 ;)
[Android Apps and Games] sotoLOTO-:
Thanks, dev! :)
[Android Apps and Games] slimshouki:
Working gr8 on my S4 e330s

1st time in history your app shows my sd card as mass storage since I purchased my mob after your update. Thank you developer
[Android Apps and Games] RayeR:
Instead of that anoying warning everytime would be possible to add some mount/unmount button that would do the same as mount/unmount in options|storage? Or maybe display the warning only at 1st run or allow to set no waring on further run. It's one more tap on every usage...
[Android Apps and Games] GokulNC:
I know that's annoying... But it's to make sure you do it everytime, because that's an important step..

Ok, I'll add a "Do Not Show Again" Checkbox to it..

And, unmounting cannot be done by this app automatically, since there's no way to umount memory card using SDK packages and there's no working shell commands for that in Android.

So the only way is through Settings->Storage.

If you find any other working way to do it, let me know :)
[Android Apps and Games] sotoLOTO-:
Tasker, as I said?

PS - It's not that annoying. You don't have to keep on launching this app again and again. The pop-up makes sense.
[Android Apps and Games] GokulNC:
Yeah, I'm working on it..

It seems someone did it on Galaxy S3 here: [App][Tasker]EasyUMS
[Android Apps and Games] RayeR:
Thanks :)

Aha, I belived that it is possible to call mount/umount shell commands with root access as usual under Linux and I would expect that it is what GUI Settings->Storage is actually doing. I didn't tried myself yet - does it throw some error on umount? Could't it be easily RE from the ROM image what the GUI is doing? If not it may save some time to add a button as shortcut to open Settings->Storage directly
[Android Apps and Games] PetrSP7:
OK THX, I will try ...
[Android Apps and Games] KaMyKaSii:
This helps?
[Android Apps and Games] PetrSP7:
This way it works correctly
[Android Apps and Games] GokulNC:
Sorry, no. It's not that simple now.

Try it yourself and see if it's working.. :)

It's more complicated than 'umount' and 'mount' commands.

We need to interact with the 'vold' daemon to do it, which I think can be done with the 'vdc' command in Android, but I don't see any proper documentation for it.

Done. Check the new v1.3.1 in OP.

Is the name 'Unmount/Remount Memory Card' OK for that button.?
[Android Apps and Games] sotoLOTO-:
10x for work, dev! Yes, the name sounds ok. Or it could be 'Mount/Unmount' or 'Unmount/Mount' or simply 'Unmount' since unmounting is what we need to achieve. Eventually later on we'll figure out that we need to re-mount the exSD card in order to use it :)
[Android Apps and Games] RayeR:
Yes, it works nice now. It saves some taps and time, good work :)
[Android Apps and Games] KaMyKaSii:
Or only "(Un)mount"