Quick code credited to Philip Whitfield "https://github.com/underdoeg/". I've only made a few modifications on the way the captured bits are processed.
Check example.py to see how it works.
documented gpio in example.py connect data and sck to GPIO 5 and 6
use as
sudo python example.py