The photos on the catflap site are all made using a Raspberry Pi:
The wooden mount holds the Raspberry Pi with builtin NoIR camera module and an IR beam. The beam is basically a bunch of IR leds mounted in the grey junction box at the bottom of the mount. The wires lead to the two reed relais which are activated by the magnet glued onto the flap. There is a relais for incoming traffic as well as one for outbound traffic.