got display working, reinstated most of old functionality, implemented selfTest function