microSD cardreader not working

I am interested if others have the same issue or if I have a device with additional hardware errors. I received my device four weeks ago, it has the factory system (Byzantium) with all available updates installed.

If I insert a sd card nothing changes, the card can’t be accessed. Some outputs (which are always the same no matter if the card is inserted or not):

lsusb:

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 2020:2060 Qualcomm, Incorporated Qualcomm CDMA Technologies MSM
Bus 001 Device 003: ID 0424:4041 Microchip Technology, Inc. (formerly SMSC) Hub and media card controller
Bus 001 Device 002: ID 0424:2640 Microchip Technology, Inc. (formerly SMSC) USB 2.0 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

There is no “ID 1d6b:0104 Linux Foundation Multifunction Composite Gadget”, see this statement from @david.boddie.

sudo dmesg | grep mmc:

[    0.430153] sdhci-esdhc-imx 30b50000.mmc: allocated mmc-pwrseq
[    0.466104] mmc0: SDHCI controller on 30b40000.mmc [30b40000.mmc] using ADMA
[    0.591754] mmc0: new HS400 MMC card at address 0001
[    0.592527] mmcblk0: mmc0:0001 032GB2 29.1 GiB 
[    0.593509]  mmcblk0: p1 p2
[    0.594048] mmcblk0boot0: mmc0:0001 032GB2 4.00 MiB 
[    0.594573] mmcblk0boot1: mmc0:0001 032GB2 4.00 MiB 
[    0.594945] mmcblk0rpmb: mmc0:0001 032GB2 4.00 MiB, chardev (245:0)
[    2.495077] mmc1: SDHCI controller on 30b50000.mmc [30b50000.mmc] using ADMA
[    2.512117] mmc1: new high speed SDIO card at address fffd

There is no additional entry when or if the micro sd card is inserted.

sudo blkid:

/dev/mmcblk0p1: UUID="719c7a55-0716-47c5-9ca0-238aac2b38ef" BLOCK_SIZE="1024" TYPE="ext2" PARTUUID="7757d6cf-01"
/dev/mmcblk0p2: UUID="43875d1d-3ee1-4757-b5fb-29e45254ea2b" TYPE="crypto_LUKS" PARTUUID="7757d6cf-02"
/dev/mapper/crypt_root: UUID="e55b9e3f-97b0-4bbc-ae18-638e30899105" BLOCK_SIZE="4096" TYPE="ext4"

sudo lsblk:

NAME           MAJ:MIN RM  SIZE RO TYPE  MOUNTPOINT
mmcblk0        179:0    0 29,1G  0 disk  
├─mmcblk0p1    179:1    0  465M  0 part  /boot
└─mmcblk0p2    179:2    0 28,7G  0 part  
  └─crypt_root 254:0    0 28,7G  0 crypt /
mmcblk0boot0   179:32   0    4M  1 disk  
mmcblk0boot1   179:64   0    4M  1 disk  

Here is what gnome disks shows with inserted card:

Which is the same no matter if the sd card is in or not. I have tested with several sd cards (Samsung EvoPlus, SanDisk Ultra) all of them working flawlessly on all other linux machines.

In my opinion this seems to be a hardware/power issue. Maybe the cardreader isn’t powered or correct cabled? Maybe the contacts between card an cardreader are not correct?

There are some similar posts, see e.g.
1, 2 ninth item and 3

Can anyone confirm this behaviour or help trouble-shooting? Thanks

1 Like

I’m confirming your finding.

@pit, please try following to see/list all empty devices (those that aren’t mounted yet), as we are actually looking for /dev/sda (inserted µSD card):
sudo lsblk -a
sudo fdisk -l /dev/sda
sudo blkid /dev/sda

1 Like

Thanks. So, does the cardreader also not work in your librem5?

Here are the outputs of your commands (card is inserted):

purism@pureos:~$  sudo lsblk -a
NAME           MAJ:MIN RM  SIZE RO TYPE  MOUNTPOINT
loop0            7:0    0    0B  0 loop  
loop1            7:1    0    0B  0 loop  
loop2            7:2    0    0B  0 loop  
loop3            7:3    0    0B  0 loop  
loop4            7:4    0    0B  0 loop  
loop5            7:5    0    0B  0 loop  
loop6            7:6    0    0B  0 loop  
loop7            7:7    0    0B  0 loop  
sda              8:0    1    0B  0 disk  
mmcblk0        179:0    0 29,1G  0 disk  
├─mmcblk0p1    179:1    0  465M  0 part  /boot
└─mmcblk0p2    179:2    0 28,7G  0 part  
  └─crypt_root 254:0    0 28,7G  0 crypt /
mmcblk0boot0   179:32   0    4M  1 disk  
mmcblk0boot1   179:64   0    4M  1 disk  

purism@pureos:~$  sudo fdisk -l /dev/sda
fdisk: cannot open /dev/sda: No medium found

So it is as if the card wasn’t present at all. Like the outputs in my first post already indicated. But what is the error? Hardware(power,cable,contacts), software(driver, os)?

Has someone a working sd cardreader on his librem5? If yes, the output of lsusb and sudo dmesg | grep mmc would be much appreciated.

2 Likes

I’m certainly not expert here but still think that lsscsi tool might help (while: No medium found) further:
sudo apt install lsscsi

Now, this outputs confirm properly working microSD card reader (with /dev/sda1 mounted):


EDIT: This time I’ve used Jumpdrive to upload here related Screenshot and happy to confirm below sudo fdisk -l output (as Librem 5 still connected to my computer), useful one:

Disk /dev/sdc: 29.12 GiB, 31267487744 bytes, 61069312 sectors
Disk model: e microSD       
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 29.12 GiB, 31268536320 bytes, 61071360 sectors
Disk model: e eMMC
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

@pit, please let us know if related /dev/sdX for Disk model: e microSD output visible to you?

2 Likes

sudo dmesg | grep usb-storage would be microSD related one, please post output of yours here.

1 Like

Thanks. The outputs of the commands with lsscsi are identical no matter if the card is inserted or not, and they are identical to your outputs.

This is the output of sudo dmesg | grep usb-storage:

[    4.072756] usb-storage 1-1.1:1.0: USB Mass Storage device detected
[    4.074222] scsi host0: usb-storage 1-1.1:1.0
[    4.074519] usbcore: registered new interface driver usb-storage

Could you post the output of the following commands on the librem5 (when a card is inserted):

lsusb
sudo dmesg | grep mmc
sudo lsblk
sudo fdisk -l
1 Like

This one looks good to me, as it should be! Other outputs from my phone, that you requested, would not bring us where you need to get (and not have much time at the moment). But below posting of yours makes me believe that we need to reformat your microSD card(s). Let me think about on how to do that, let me know if you want to reformat your microSD card outside of the Librem 5.

While mounted microSD card should read like this (mine here is of size 32GB, just by coincidence at this moment):

sda    8:0  1 29.1G 0 disk 
└─sda1
       8:1  1 29.1G 0 part /media/pur
1 Like

Ok, I formated the sd cards to exfat, ext2, ext4, vfat. No change.
I will contact purism the following day, if I get no further. If you (or someone else with a functioning sd reader in the librem5) have time, it would be great to see the output of

lsusb
sudo dmesg | grep mmc
sudo lsblk

Thanks.

2 Likes

@pit, as you are really ready (because I think that your microSD card, as is now, isn’t readable within Librem 5) to sacrifice (erase all of your current data) one of your microSD cards you might start here (further steps, actual formatting, as needed, might afterwards be done on Librem 5 as well):


Etc.

2 Likes

Hopefully the image of the output of those commands helps. It looks to me that the card reader hardware can be seen but the card is not being recognised, as you say you have tried a number of cards all of which work on another Linux system, I’d be inclined to think it’s a hardware fault.

Adding fdisk output…

3 Likes

@pit, perhaps sharing here fdisk --list output of used microSD card(s), from outside of the phone, might help us further. And even cleaning contacts of used SanDisk Ultra microSD (or other one) with some microfiber cloth might indeed help to be recognized within here related device.

1 Like

Thank you all for your feedback. Great community. I’ll keep you posted, if there is a solution.

Good idea, I’ll try this, although the sandisk is brandnew, the samsung ones are older.

I assume it is a contact problem between sd card and sd cardreader, or a circuit problem between reader and board.

2 Likes

I have to ask cause there were cases like that before - are you 100% sure you’re putting the card the right way in?

If so, then it’s probably best to contact support.

(also, please move the tray only when the phone is off, it isn’t really meant to be hotplugged)

2 Likes

This is the way I insert the card:


That should be right?

2 Likes

Yes indeed (Thanks!), and @pit, I really do hope that this might be solution here within this thread (as I even took BPP-L503 battery out before inserting microSD card into the Librem 5 microSD slot, with contacts facing up toward flashlight side), as shown within picture you’ve just posted.

2 Likes

I now took the battery out for an hour. Afterwards I inserted sd card and battery back. Nothing changed.

2 Likes

@Loki and I just hoped that we can help you. Consequently now I’m admitting that is much better that you address your microSD issue toward support@ team from Purism, as @dos already recommended here.

2 Likes

Yes, thank you once again, I will contact them tomorrow.

2 Likes

Lol the MicroSD card can’t be hotplugged? I am having them same issue so I decided to test another another MicroSD and they work without issue on Android and I’m just now finding this out with the hotplug issue… Can this cause the SD card reader to short circuit?

1 Like

Yes, possibly. Switch it off before swapping cards.
https://docs.puri.sm/Librem_5/Setup.html#install-the-nano-sim-card-and-microsd-card

2 Likes