Keeping record of last two minute Audio/video recording?(python script added)

Hi,
I want to use Note 2camera as a third empire video rec. of a cricket match. to do this somehow Note 2 should keep video record of last two or three minute only .rest should be delete so thus whatever happens in the match recently (just two minute before) i can see reply of it. i hope i have present what i want in good words.(actually my English is not good)
actually i have done this in my nokia N900 before this using this puthon script

You might consider looking in the Play Store for "dash cam" apps. They may be able to record the most recent few minutes and automatically remove older videos. As for the Python script, there are Python engines (also in the Play Store) that should theoretically let you use your existing script. One example is QPython.