[maemo-users] N810 - executing script when digital camera is plugged in and mounted

From: Frederik Vanrenterghem frederik at vanrenterghem.biz
Date: Thu Oct 8 13:20:00 EEST 2009
Hi all,

I would like to execute a script that copies the pictures from my digital
camera when it's plugged into my nokia tablet. The script functions
correctly when executed from the command-line after plugging in the camera.

Adding the following rule to /etc/udev/rules.d/zz99_camera.rules works only
partially:
ACTION=="add", BUS=="usb", \
  SYSFS{idVendor}=="054c", SYSFS{idProduct}=="0010", \
  RUN+="/home/user/autoPicturesImport.sh"

The script is executed correctly, but it can't copy anything from the
mounted camera, as the file system on it is not available. That is made
available only once this script completes (as evidenced by including a long
sleep command in there).

How can I ensure all actions to automount the camera are completed before
this script is executed?

Thanks in advance for your insight!

Best regards,
Frederik
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maemo.org/pipermail/maemo-users/attachments/20091008/4b7298db/attachment.htm 
More information about the maemo-users mailing list