I am trying to read MCP3201 with 44100 samples per second. The chip has top clock frequency of 1Mhz, which should be sufficient for 62500 two-byte samples per second.
sampnumb = 44100 spi = spidev.SpiDev() spi.open(0,0) spi.max_speed_hz = 125000000 for i in range(sampnumb): dat = spi.xfer2([0x00, 0x00])
It actually takes almost 2s to read as many samples. Using 976000 for max_speed_hz makes it even slower.
Are there any ways to make sampling faster in Python? If not, is this possible to achieve fast sampling any other way?