if (test $1) then if (test $1 = "eject") then if (test "$mmc_present" != "0") then umount /mmc && rmdir /mmc rmmod mmc.o rmmod vfat.o rmmod fat.o mmc_present=0 else echo "MMC Card not present!" fi elif (test $1 = "insert") then if (test "$mmc_present" != "1") then insmod -q fat.o insmod -q vfat.o insmod -q mmc.o mkdir -p /mmc mount /dev/mmc/disc0/part1 /mmc mmc_present=1 else echo "MMC Card already present!" fi else echo "Usage: mmc " fi else echo "Usage: mmc " fi