]> Repositories - Adafruit_Blinka-hackapet.git/blobdiff - examples/pi_busio_i2c.py
Massive pylinting session and added Github Actions
[Adafruit_Blinka-hackapet.git] / examples / pi_busio_i2c.py
index 93f59e64e1577f1068e6bf3e92b70a45eaaaee46..48c0223ef38b909ebb1e9e651abd0ef5937415fc 100755 (executable)
@@ -12,6 +12,7 @@ if not 0x18 in i2c.scan():
     print("Didn't find MCP9808")
     exit()
 
+
 def temp_c(data):
     value = data[0] << 8 | data[1]
     temp = (value & 0xFFF) / 16.0
@@ -19,6 +20,7 @@ def temp_c(data):
         temp -= 256.0
     return temp
 
+
 while True:
     i2c.writeto(0x18, bytes([0x05]), stop=False)
     result = bytearray(2)