My app writes a text file onto the phone’s external storage. I know it works fine because I can find the file via a file manager. What I’m stumped by is this : I can see that the file has been created on the SD Card via the file manager on my phone. When I enable USB storage and connect it to my computer, I don’t see the text file.
The path was : “mnt/sdcard/test.txt”
I can see it on my phone. When I mount the sd-card to my computer, I don’t see it.
Why is this?
The user permissions have been set correctly. Otherwise the file will not be seen even on the phone.
If you agree to connect the USB storage then the SD card is unmounted and it’s not visible to Android and only as USB storage device to the attached USB port.
If you are a developer and you want to investigate files on your device you should connect your device and use
adblike thatThere is nothing wrong, you are only missing what Android really does and how you are supposed to connect your terminal to the device.