How to pause a shell script

Hi,

I've written a shell script to take photos with my camera.
After every picture taken, the picture is transmitted to the computer via usb and then deleted on the camera.
But sometimes there's an error and the picture is not deleted and so, after a certain time, the camera chip will be full.
When I try to delete the pictures on the camera manually, it'll shut down, because the script also wants to access it.

I don't wanna stop the script because it's quite a long complex measurement.
Is there a possibillity to pause the script somehow from outside?

Thank you very much!

One approach to how a script could pause would be:

LOOP:
Do your stuff
Check to see if file exists
   If so, then wait for something to happen
   (such as, keystroke entry or file to be deleted)
goto LOOP

Thus, if the file does not exist - say PauseMyProgram.txt - then you will continue with the LOOP'ing. So if you want to pause your script, simply create the file PauseMyProgram.txt and your script will wait until you satisfy your next requirement.

Thanks!
I'm not such a good coder.
Do you know how the code could look like?

# Stop process
kill -s TSTP pid

# Continue/Resume process
kill -s CONT pid

THANKS!!!!!
Works perfectly!