adding jon's modifications to spi macro