7 segment display project. The main counting procedure is here and there is also some SPI comms as well but I don't remember why..