Why doesn't a SD card work? [answered]
Why doesn't a SD card work? Tried 2GB and 32GB SD card, but neither was recognized.
We have moved to a new Sailfish OS Forum. Please start new discussions there.
Why doesn't a SD card work? Tried 2GB and 32GB SD card, but neither was recognized.
The best way is to format your SD Card with BTRFS or Ext4 filesystem. If you have enabled developer mode you can format the SD card this way (as root) :
mkfs.btrfs /dev/mmcblk1p1
Please note all SD card data will be erased
You also need to modify /usr/sbin/mount-sd.sh like that :
#!/bin/bash
SDCARD=/dev/sdcard
DEF_UID=$(grep "^UID_MIN" /etc/login.defs | tr -s " " | cut -d " " -f2)
DEF_GID=$(grep "^GID_MIN" /etc/login.defs | tr -s " " | cut -d " " -f2)
DEVICEUSER=$(getent passwd $DEF_UID | sed 's/:.*//')
MNT=/run/user/$DEF_UID/media/sdcard
if [ "$ACTION" = "add" ]; then
if [ -b /dev/mmcblk1p1 ]; then
ln -sf /dev/mmcblk1p1 $SDCARD
elif [ -b /dev/mmcblk1 ]; then
ln -sf /dev/mmcblk1 $SDCARD
else
exit $?
fi
su $DEVICEUSER -c "mkdir -p $MNT"
case "${ID_FS_TYPE}" in
vfat|ntfs|exfat)
mount $SDCARD $MNT -o uid=$DEF_UID,gid=$DEF_GID
;;
*)
mount $SDCARD $MNT
chown $DEVICEUSER: $MNT
;;
esac
else
umount $SDCARD
if [ $? = 0 ]; then
rm -f $SDCARD
else
umount -l $MNT
rm -f $SDCARD
fi
fi
Thank you! Why is it the "best" way to do so? That's the question in first place. This answer will serve users who are not familiar with all of the complexities, still they will have a clue on why this, what are its pros and cons.
NikosAlexandris ( 2013-12-27 11:43:23 +0200 )editApologies, this was the right comment, put on the wrong place though. I thought your reply was for https://together.jolla.com/question/2645/recommended-file-system-type-partitioning-scheme-for-the-microsd-card/ :D
NikosAlexandris ( 2013-12-27 11:45:01 +0200 )editI think it would be great to have line numbering as well for some longer pieces of code in the forum. It would help to identify the code lines of interest/in question.
NikosAlexandris ( 2013-12-28 13:46:50 +0200 )editMight be "just" filesystem problem?
From PiratePad: "Jolla doesn't currently support Microsoft's exFAT due licensing reasons so 64GB cards need to be formatted to use other file system like ext4 to get them working"
Oh, btw, this is a duplicate for https://together.jolla.com/question/292/my-jolla-does-not-recognise-any-micro-sd-card-what-i-can-do/?answer=296#post-id-296
me too, uSD card 16GB (FAT32) verified unable to read/watch/listen video/picture/music from my uSD so i really need Sailfish can read/write on FAT32 uSD card, please I don't want another filesystem on uSD advantage about FAT32, all system are able to read/write without limitation ! uSD was used on Nokia N8-00 without doing anything (factory formatted FAT32) I need to read folder DCIM and all subfolders
This thread is public, all members of Together.Jolla.Com can read this page.
Asked: 2013-12-26 17:44:29 +0200
Seen: 3,193 times
Last updated: Dec 27 '13
My Jolla does not recognise any micro sd card. What I can do? [answered]
Recommended file system type & partitioning scheme for the microSD card? [answered]
Use alternative file systems for SD card
MicroSD as removable drive in Windows [released]
Bug: SD card formatted to ext4/btrfs is not mounted automatically [released]
Camera should have an option to select where to save photos [released]
BUG: micro sd (music) files disappear/appear randomly [duplicate]
what file system is on the SD card? and how do you verify that it is recognized?
Kontio ( 2013-12-26 17:50:10 +0200 )editSee also Recommended file system....
NikosAlexandris ( 2013-12-27 00:20:25 +0200 )editThis question seems to actually be a duplicate of https://together.jolla.com/question/292/my-jolla-does-not-recognise-any-micro-sd-card-what-i-can-do/. Right?
NikosAlexandris ( 2013-12-28 06:33:38 +0200 )edit