Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 5359

Interfacing (DSI, CSI, I2C, etc.) • Python spidev xfer2 still working?

$
0
0
I ran an older Python script that used spidev and got an error for using xfer2:

Code:

import spidevspi_device  = 0spi_channel = 0max_speed_hz = 10000000 # 10MHzfram = spidev.SpiDev(spi_device, spi_channel)fram.max_speed_hz = max_speed_hzfram.xfer2([0x00, 0x00])
I got this error:

Code:

OSError: [Errno 22] Invalid argument
Is Python spidev no longer supported on RPi4b?

Statistics: Posted by chipace — Fri May 24, 2024 2:58 am



Viewing all articles
Browse latest Browse all 5359

Trending Articles