13

I want to prepare an SD card for use in an old camera using CHDK. The card needs to be FAT16 formatted. This doesn’t work from Terminal anymore, maybe already for years. Disk Utility provides ''FAT'', but this is FAT32. I have no other (Windows) computer. What do I do?

1
  • How large is the SD Card? FAT16 has a nominal size limit of 2GB. diskutil should still be able to do FAT16 up to 2GB, I use it a lot.
    – Tetsujin
    Commented Feb 11, 2016 at 7:25

4 Answers 4

32

You can format any drive to FAT16 with newfs_msdos Command

1) Launch Terminal

2) Find The Drive you Want to Format

#mount
/dev/disk2 on / (hfs, local, journaled)
devfs on /dev (devfs, local, nobrowse)
/dev/disk4s1 on /Volumes/USB_Disk (msdos, local, nodev, nosuid, noowners)

In this case, my disk is disk4. Your disk will most likely be different! Be sure to reference the correct disk - you can and will lose your data if you format the wrong drive!!!

3) Unmount the disk

#diskutil unmountDisk disk4
Unmount of all volumes on disk4 was successful

4) Format the drive

#sudo newfs_msdos -F 16 /dev/disk4

After a few moments, your drive will format.

5) Remount the drive (optional)

#diskutil mount /dev/disk4

It will probably show up as "NO NAME" on your Desktop. You can rename it here or to do it at the time of formatting use -v Type in a Volume Name when you format the drive.

7
  • This results in a FAT32 formatted drive.
    – lejonet
    Commented Feb 10, 2016 at 21:04
  • 2
    You can also try newfs_msdos -F 16 /dev/xxxxxx where xxxxxx is your drive that you want to format. Let me know if that works and I will update the answer.
    – Allan
    Commented Feb 10, 2016 at 21:27
  • Thanks, this worked (first it gave me 'resource busy', had to unmount first).
    – lejonet
    Commented Feb 10, 2016 at 21:39
  • 1
    I'll update the answer for you....
    – Allan
    Commented Feb 10, 2016 at 21:51
  • In OS X 10.8.5 I didn't have to use sudo to have newfs_msdos format my disk. Are you saying in 10.11 it's required? Anyway, nice directions. +1 Commented Feb 11, 2016 at 0:04
8

For what it's worth, this seems to work on High Sierra:

diskutil eraseDisk "MS-DOS FAT16" SOMENAME /dev/disk#

It still needs to be unmounted first.

2
  • Hi ammulder, and welcome to ask different! On this site, it is preferred that answers explain exactly what you're doing and why it works - especially with terminal commands like this. Thanks, and happy answering! Commented Dec 1, 2017 at 1:31
  • My command looks like below, and it works: diskutil eraseDisk "MS-DOS FAT16" "WINDOWSXP" MBR disk2
    – Zhang Buzz
    Commented Feb 2, 2018 at 21:30
6

I spend all evening to understand how to format a USB stick to FAT16 and its so simple and just copy these commands to your terminal:

  1. diskutil unmountDisk disk4

  2. sudo newfs_msdos -F 16 /dev/disk4

  3. diskutil mount /dev/disk4

This works for all sizes of drives.

Note: For other users: the reference to disk4 in the commands above may need to be changed to ensure it refers to the correct drive.

1
  • This is a duplicate of the accepted answer, except more compact, and lacking the useful mount command to see what drives are mounted.
    – velkoon
    Commented Oct 2, 2021 at 2:32
-8

Why so hard to explain things, it is the main reason why many new users get away from linux.

Just do mkfs.vfat -F16 /dev/sdb(x) if you want to name the USb, flash, etc... put this in addiction -n (name), then it looks like this:

mkfs.vfat -F16 /dev/sdb(x) -n (name) and hit enter.

1
  • 4
    OS X/macOS is not Linux and OS X/macOS doesn't have mkfs.vfat command. Commented Jan 19, 2017 at 12:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .