How to read data from a serial (SPI) connection in C?

后端 未结 3 1521
无人及你
无人及你 2021-01-23 09:51

I am trying to write a program that will be installed on a Linux MCU (Raspberry Pi) that will read serial data coming to it from yet another MCU (something homegrown that I will

3条回答
  •  情歌与酒
    2021-01-23 10:21

    Have you find Linux documentation of SPI ?

    There are couple good documents: spi-summary and spidev.

    There is also example in file spidev_fdx.c, where read() is used for SPI device.

    But usually reading from SPI is handled by ioctl() function.

提交回复
热议问题