etc:users:jcmvbkbc:hardware
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| etc:users:jcmvbkbc:hardware [2016/08/08 20:53] – ↷ Page moved from users:jcmvbkbc:hardware to etc:users:jcmvbkbc:hardware kel | etc:users:jcmvbkbc:hardware [2026/08/29 16:52] (current) – jcmvbkbc | ||
|---|---|---|---|
| Line 42: | Line 42: | ||
| == topology.xml controller line == | == topology.xml controller line == | ||
| < | < | ||
| + | |||
| + | === SPI master === | ||
| + | == Pin functions == | ||
| + | * 5: MOSI | ||
| + | * 7: CS0 | ||
| + | * 9: SCK | ||
| + | * 13: MISO (pulled up by default) | ||
| + | |||
| + | == PyFTDI-based example == | ||
| + | API doc: https:// | ||
| + | < | ||
| + | from pyftdi import ftdi, spi | ||
| + | |||
| + | ftdi.Ftdi.add_custom_vendor(vid = 0x15ba) | ||
| + | ftdi.Ftdi.add_custom_product(vid = 0x15ba, pid = 0x002a) | ||
| + | |||
| + | ftdi.Ftdi.show_devices() | ||
| + | |||
| + | ctrl = spi.SpiController() | ||
| + | ctrl.configure(" | ||
| + | port = ctrl.get_port(freq = 1000000, cs = 0) | ||
| + | |||
| + | port.write(b' | ||
| + | port.read(1, | ||
| + | port.read(1, | ||
| + | </ | ||
etc/users/jcmvbkbc/hardware.1470678794.txt.gz · Last modified: 2016/08/08 20:53 by kel