Smart software linked to CCTV can spot dubious behaviour