truct spi_device *sensor_spi=NULL; //spi_device 设备结构体信息 int sensor_spi_write(unsigned int addr, unsigned int val, size_t len) { int status; unsigned char write_buf[2]; write_buf[0] = addr; //在某个地址写什么值 write_buf[1] = val; status = spi_write(sensor_spi, w