title: Set time in cronjob for camera
body: <p>I've installed motion mmal on Raspberry Pi and its recording video whenever I run startmotion script:</p>
  
  <pre><code> #!/bin/sh
   nohup /home/pi/mmal/motion -n -c /home/pi/mmal/motion-mmalcam.conf        1&gt;/dev/null 2&gt;&amp;1 &lt;/dev/null &amp;
  </code></pre>
  
  <p>However, Its making continuous video until I stop motion.</p>
  
  <p>I want to make a video of 5 minute after every 10 minutes. I tried the timeout command:</p>
  
  <pre><code> #!/bin/sh
   timeout 5m nohup /home/pi/mmal/motion -n -c /home/pi/mmal/motion-mmalcam.conf        1&gt;/dev/null 2&gt;&amp;1 &lt;/dev/null &amp;
  </code></pre>
  
  <p>I was able to run script after every 1 hour by using this code:</p>
  
  <pre><code>0 * * * * nohup /home/pi/mmal/motion -n -c /home/pi/mmal/motion-                   mmalcam.conf        1&gt;/dev/null 2&gt;&amp;1 &lt;/dev/null &amp;
  
  5 * * * * pkill -9 motion
  </code></pre>
  
  <p>How can I run this script after every 10 minutes?</p>