Go for something like
this.
(Not a specific endorsement, but the feature set I would look for)
It claims it can do motion activated recording.
How long you can record depends on disk space and resolution.
Unless you or no#1 son has too much smut on your computer as it is I would imagine you should be fine