The b2tf.py and b2tf2.py examples demonstrate drawing a multiple seven segment displays on the same screen. The b2tf.py code uses the sevensegment.py widget from the snippets directory to perform the drawing. The b2tf2.py performs the same task but uses the ext-sevenseg extension to draw the seven segment displays.
The ext-sevenseg extension is loaded with the code in patch_b2tf2.py. This loads extension coprocessor commands including the CMD_SEVENSEG function into the device. To verify the version of the extension loaded and the components the function the loader code tests the return string containing information on the extension from the coprocessor.
The patch_b2tf2.py file is generated by EVE Asset Builder (EAB).
The format of the command call is as follows:
MPSSE example:
python b2tf.py --connector ft232h
FT4222 example in single mode (--mode 0):
python b2tf.py --connector ft4222module
FT4222 example in dual mode (--mode 1) or quad mode (--mode 2):
python b2tf.py --connector ft4222module --mode 2
The example contains a single file which comprises all the demo functionality.
| File/Folder | Description |
|---|---|
| b2tf.py | Example source code file using the sevensegment widget |
| b2tf2.py | Example source code file using the function |
| sevensegment.py | Snippet source code for seven segment displays |
| patch_b2tf2.py | Extension loader module from EAB |
| docs | Documentation support files |
