adding SPI access functions (incomplete)