bitbangio module contains classes to provide digital bus protocol
support regardless of whether the underlying hardware exists to use the
First try to use
busio module instead which may utilize peripheral
hardware to implement the protocols. Native implementations will be faster
than bitbanged versions and have more capabilities.
All classes change hardware state and should be deinitialized when they
are no longer needed if the program continues after use. To do so, either
deinit() or use a context manager. See
Lifetime and ContextManagers for more info.
import bitbangio from board import * i2c = bitbangio.I2C(SCL, SDA) print(i2c.scan()) i2c.deinit()