/* * The following two functions are taken from the BMI323 spi driver code. * In section 6.4 of the BMI270 data it specifies that after a read * operation the first data byte from the device is a dummy byte
*/ staticint bmi270_regmap_spi_read(void *spi, constvoid *reg_buf,
size_t reg_size, void *val_buf,
size_t val_size)
{ return spi_write_then_read(spi, reg_buf, reg_size, val_buf, val_size);
}
/* * Remove the extra pad byte since its only needed for the read * operation
*/
data_buff[1] = data_buff[0]; return spi_write_then_read(spi, data_buff + 1, count - 1, NULL, 0);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.