loop recognising cards