]> Repositories - Adafruit_Blinka-hackapet.git/commitdiff
Fixes issue with SPI on Orange Pi Zero and R1
authorMelissa LeBlanc-Williams <melissa@adafruit.com>
Sat, 5 Oct 2019 01:11:31 +0000 (18:11 -0700)
committerMelissa LeBlanc-Williams <melissa@adafruit.com>
Sat, 5 Oct 2019 01:11:31 +0000 (18:11 -0700)
src/adafruit_blinka/microcontroller/generic_linux/spi.py
src/busio.py

index 58a465db727588abb1b758c1c5987292e1f30f3c..cf4a06c6cd259ea5ce20f286d8db22c22970ad98 100755 (executable)
@@ -37,7 +37,7 @@ class SPI:
         # does not support setting SPI_NO_CS mode bit (issue #104)
         if not self.chip.AM33XX and not self.chip.IMX8MX and not self.chip.SAMA5 \
          and not self.chip.APQ8016 and not self.chip.T210 and not self.chip.T186 \
         # does not support setting SPI_NO_CS mode bit (issue #104)
         if not self.chip.AM33XX and not self.chip.IMX8MX and not self.chip.SAMA5 \
          and not self.chip.APQ8016 and not self.chip.T210 and not self.chip.T186 \
-         and not self.chip.T194:
+         and not self.chip.T194 and not self.chip.SUN8I:
             try:
                 self._spi.no_cs = True  # this doesn't work but try anyways
             except AttributeError:
             try:
                 self._spi.no_cs = True  # this doesn't work but try anyways
             except AttributeError:
index 9003bab9f257add8fef9108b88e449aebe1a398a..94f8f674a96660d0bb5ce68dca2bec211e100a09 100755 (executable)
@@ -32,7 +32,7 @@ class I2C(Lockable):
                 break
         else:
             raise NotImplementedError(
                 break
         else:
             raise NotImplementedError(
-                "No Hardware I2C on (scl,sda)={}\nValid UART ports: {}".format((scl, sda), i2cPorts)
+                "No Hardware I2C on (scl,sda)={}\nValid I2C ports: {}".format((scl, sda), i2cPorts)
             )
 
     def deinit(self):
             )
 
     def deinit(self):