Help - Search - Members - Calendar
Full Version: Determine When A Cf Card Is Mounted?
OESF Forums > Distros, Development, and Model Specific Forums > Model Specific Forums > C1000/3x00 General discussions
BarrySamuels
Is there a way to determine when a CompactFlash card is mounted? If I can do that I then want to run a script automatically.

Any help appreciated.
Cagilaba
I'm not sure what you want to do with the script, but if you simply want to find out whether a CF is mounted, you can do "df -h" and look for /dev/hda1 which will be mounted at /mnt/cf or /usr/mnt.rom/cf. SD is /dev/mmcda1 at /mnt/card.
BarrySamuels
QUOTE(Cagilaba @ Nov 7 2005, 02:57 PM)
I'm not sure what you want to do with the script, but if you simply want to find out whether a CF is mounted, you can do "df -h" and look for /dev/hda1 which will be mounted at /mnt/cf or /usr/mnt.rom/cf. SD is /dev/mmcda1 at /mnt/card.
*


I want to avoid the need to keep checking. I was hoping to be able to run a script automatically whenever a CF card is mounted.

I want the script simply to run VisualQ if the card is a camera card. I can easily determine that because it will have a /dcim/100olymp directory on it.
lardman
Take a look at Mickeyl's pcmcia-applet for Opie, it allows you to perform actions depending on which card you have inserted.


Si
BarrySamuels
QUOTE(lardman @ Nov 7 2005, 03:45 PM)
Take a look at Mickeyl's pcmcia-applet for Opie, it allows you to perform actions depending on which card you have inserted.
*


Thanks - but where do I find it? A google search finds only one occurence as part of a 'wish list'.
Will it run on a Sharp Rom?
xenophobe
QUOTE(BarrySamuels @ Nov 7 2005, 12:52 PM)
Is there a way to determine when a CompactFlash card is mounted? If I can do that I then want to run a script automatically.

Any help appreciated.
*


Look at /etc/pcmcia/ide file.
This file starts every time your CF card inserts, ejects etc.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2014 Invision Power Services, Inc.