kopia lustrzana https://github.com/botheredbybees/kilnController
add a note about GPIO collisions with system SPI
rodzic
9874aeb1d8
commit
de0d3baadb
|
@ -41,7 +41,7 @@ gpio_door = 18
|
|||
# max6675 - bitbang SPI interface
|
||||
max31855 = 1
|
||||
max6675 = 0
|
||||
max31855spi = 0
|
||||
max31855spi = 0 # if you use this one, you MUST reassign the default GPIO pins
|
||||
|
||||
### Thermocouple Connection (using bitbang interfaces)
|
||||
gpio_sensor_cs = 27
|
||||
|
|
|
@ -20,6 +20,15 @@ try:
|
|||
import Adafruit_GPIO.SPI as SPI
|
||||
from max31855spi import MAX31855SPI, MAX31855SPIError
|
||||
log.info("import MAX31855SPI")
|
||||
spi_reserved_gpio = [7, 8, 9, 10, 11]
|
||||
if config.gpio_air in spi_reserved_gpio:
|
||||
raise Exception("gpio_air pin %s collides with SPI pins %s" % (config.gpio_air, spi_reserved_gpio))
|
||||
if config.gpio_cool in spi_reserved_gpio:
|
||||
raise Exception("gpio_cool pin %s collides with SPI pins %s" % (config.gpio_cool, spi_reserved_gpio))
|
||||
if config.gpio_door in spi_reserved_gpio:
|
||||
raise Exception("gpio_door pin %s collides with SPI pins %s" % (config.gpio_door, spi_reserved_gpio))
|
||||
if config.gpio_heat in spi_reserved_gpio:
|
||||
raise Exception("gpio_heat pin %s collides with SPI pins %s" % (config.gpio_heat, spi_reserved_gpio))
|
||||
if config.max6675:
|
||||
from max6675 import MAX6675, MAX6675Error
|
||||
log.info("import MAX6675")
|
||||
|
|
Ładowanie…
Reference in New Issue