modified to work with SPItest.hp