moved spi to core.spi, as refactoring was half way