This base block is to help write blocks that communicate with chips over I2C. It provides functionality so that your blocks work on a variety of platforms.
- platform: The Platform used for i2c communication (e.g. RaspberryPi|Edison|FT232H|...)
- I2C_address: I2C address to communicate with (e.g. '0x40')
Not all dependencies are required for all uses of the block. It matters what Platform
you are using.
Communicate I2C over USB with a FT232H chip.
-
This block uses the Adafuit_Python_GPIO package for I2C communication but it requires a special branch that supports python 3.
-
Also required is the libftdi library for communicating with the FT232H chip. Follow the Adafruit install instructions with two slight modifications.
- Replace the step
cmake -DCMAKE_INSTALL_PREFIX="/usr/" ../
withcmake -DCMAKE_INSTALL_PREFIX="/usr/" -DPYTHON_EXECUTABLE="/usr/bin/python3.4" ../
. - After the
cmake ...
step and before themake
step. Modify the filebuild/python/ftdi1PYTHON_wrap.c
. In line 3161, replacePyUnicode_AsUTF8String
withPyUnicode_AsLatin1String
. Otherwise the library won't work completely with python3. A bug has reported to the libftdi mailing list.
- Replace the step
None
Any list of signals.
None