Added checks for using I2C bus and SPI bus

Inputs/Outputs cannot be setup on I2C and SPI GPIO's when they have been
configured to be used in the setup script.