Formatting a MMC card with FAT32 via the Terminal...? help!

cheesy9999

Registered
Yes you may be wondering WHY, but its because I have a memory card that needs to be FAT32 for a MP3 player and Disk Utility won't format it correctly, so I'm resorting to Mac OS X's Unix underpinnings.

I've found several utilities that may work (using the apropos command) but I don't know which device the USB MMC card reader is. How do I figure this out? I sort of narrowed it down by disonnecting the USB MMC card reader, wainting a minute, plugging it back in and inserting the card, waiting another minute, then running the command "ls -lt /dev" to list all the devices in order that they were modified. These are the ones that were modified during the minute I inserted the card:

brw-r----- 1 tomrobin operator 14, 10 Feb 11 01:44 disk1
br--r----- 1 tomrobin operator 14, 11 Feb 11 01:44 disk1s1
brw-r----- 1 tomrobin operator 14, 13 Feb 11 01:44 disk1s2
crw-r----- 1 tomrobin operator 14, 10 Feb 11 01:44 rdisk1
cr--r----- 1 tomrobin operator 14, 11 Feb 11 01:44 rdisk1s1
crw-r----- 1 tomrobin operator 14, 13 Feb 11 01:44 rdisk1s2

Does this make sense? Thats the only way I could think of but it didn't narrow it down enough. I don't know Unix very well (obviously) so I'm sorry if this is a completely stupid idea. I also tried looking up the card in the Get Info panel, Disk Utility, and Apple System Profiler with no luck.

Is it even possible to format a memory card with those DOS utilities?

Please help.
 
Thank you! That helped me get one step closer. I found that the device is /dev/disk3s2.

I then tried to run sudo newfs_msdos /dev/disk3s2 but was told the device was busy. So I deleted the partition using Apple's Disk Utility (essentially unmounting it) and tried again, but this time I get a permission denied error (even though I used sudo)...now what?
 
You should have unmounted the disk before running the newfs command.

Now you should refresh the disk arbitration table with: disktool -r and then df again and then diskutil followed by the correct arguments. (Run it without arguments to get an acceptable syntax list.)
 
Thank you, you are a big help. Bear with me, I'm a unix newbie...

Basically here's my problem. I have this disk:
Code:
/dev/disk3
   #:                   type name               size      identifier
   0:                        UNTITLED           *30.6 MB  disk3
   1:                        UNTITLED           30.6 MB   disk3
but I want it to be formated with the same type of filesystem as this disk:
Code:
/dev/disk3
   #:                   type name               size      identifier
   0: FDisk_partition_scheme                    *7.7 MB   disk3
   1:             DOS_FAT_12 CANON_DV           7.6 MB    disk3s1

I've tried sudo diskutil partitionDisk disk3 1 DOS_FAT_12 30.63M but it doesn't do anything, it just repeats the syntax.

I tried fdisk too:
[Tom-Robinsons-Computer:~] tomrobinson% fdisk /dev/disk3
fdisk v1.02
fdisk: unable to open /dev/disk3


Do I need to actually log in as root instead of using "sudo"? How do I? I tried typing in root in the Mac OS X login panel but it didn't work. "su" doesn't work either.
 
mild rave
sudo is 'substitute user do' or 'super user do', depending on who you ask. Anything that you need to do as root, you can do with sudo. If you want to actually get a root shell, just type sudo -s and enter your administrator password. You will then have a full root shell. There's no need to enable root or login as root to do anything on OS X. You can always do what needs be done with sudo (including launching GUI Carbon or Cocoa apps as root).
 
Originally posted by gatorparrots

There's no need to enable root or login as root to do anything on OS X. You can always do what needs be done with sudo (including launching GUI Carbon or Cocoa apps as root).

I'm not disputing your point about not having to log in as root, although I'm now curious... I haven't run across anything that *had* to be done logged in as root although on Mac OS X server the root account is enabled by default.

Would anybody know why?
 
I assume that the card was working properly before formatting.
Had it been previously tested?
Are you able to format the card HFS?
 
Yes, it worked before I formated it. I can still format it as HFS, HFS+, UFS, MS-DOS, etc, and it WILL mount in my computer, the only problem is that it won't work in my MP3 player (Ericsson HPM-10 attachment for Ericcson cell phones)

I formatted it because I was having a problem which I later figured out was unrelated to the format: (when I ejected the card it would make a tiny file for every MP3 called "._FILENAME.mp3" causing the player to give an error when it came upon that file. To solve it I just have to go into the terminal, navigate to the card, and type "rm ._*")

Like I said above, the card still mounts fine in Mac OS X, I can copy files and everything, but when I insert it into my MP3 player it gives me an error "File System Error". I examined two other cards which DO work in the player and they are formated as "DOS_FAT_12" and "DOS_FAT_16". I assume "DOS_FAT_32" should aslo work, and I tried formatting the card as a FAT 32 volume under Windows XP but it gave me an error saying the volume was too small or something. There were no options for FAT 12 or 16, but there was an option for just plain "FAT", which I tried, but it would still not work in the player.

Thanks for the help.
 
Just because the mp3 player supports FAT 16 I wouldn't automaticaly assume that it would support FAT 32. FAT 32 is a much more complex file system that would not give any added gain to such a small partition size. FAT 32 was primarily created to overcome a barrier in partition size.

If I were to create an mp3 player the FS I would implement would be FAT 16, since all modern OS's recognize fat 16 and it's extremely simple.

If you can't get the MP3 player to recognize the card in FAT 16 it won't be readable under FAT 32 either. Maybe there was info hidden on the card that was needed for proper operation. By formating the card this was lost. Possibly a hidden boot volume, just like volumes on OS X boot CD's
 
http://www.esato.com/board/viewtopic.php?topic=2292&forum=15

apparently the way that the card is formatted can have just as much effect on the function as the format in which it's formatted.

I did notice on their that they said that you can not use FAT 32 as your FS

Also... here's another post from the same forum
Regard the error message.

I put my MMC card in a friends Palm device and when I put it back into the MP3 player I got this message.

It turned out that the palm wrote a small file to the MMC like an .ini file. When I deleted this file on my PC the error was gone.

It might be caused due to how your Trash Can settings are configured. Ensure that Windows does not set up a Trash Can on your removable drives as this will set up a file on your mmc card also.

Regarding variable bit rates. I use the dBAmp freeware that allows conversion from wma/mp3 to wma/mp3 at any bit rate including variable.

I played about with these to see if I could get better compression with less quality loss. They played perfect but I didn't notice any difference so I now stick with 96kbs which is fine for me.

Hope this helps

Andrew

I'm wondering if you have .ds_store or some other hidden OS X files on the disk
 
I probably do have some hidden files...but i think I also have them on my other cards that do work. but thanks for the tip, I'll try it.
 
I was finally able to format it...using a video camera.

I never did figure out how to format it using a computer, but oh well, i'll just make sure I don't format it again and I should be ok
 
Back
Top