Home
last modified time | relevance | path

Searched refs:newXfer (Results 1 – 2 of 2) sorted by relevance

/device/google/contexthub/firmware/os/drivers/bosch_bmp280/
Dbosch_bmp280.c555 struct I2cTransfer *newXfer; in handleI2cEvent() local
560 newXfer = allocXfer(STATE_VERIFY_ID); in handleI2cEvent()
561 if (newXfer != NULL) { in handleI2cEvent()
562 newXfer->txrxBuf[0] = BOSCH_BMP280_REG_ID; in handleI2cEvent()
563 …ret = i2cMasterTxRx(I2C_BUS_ID, I2C_ADDR, newXfer->txrxBuf, 1, newXfer->txrxBuf, 1, i2cCallback, n… in handleI2cEvent()
565 releaseXfer(newXfer); in handleI2cEvent()
603 newXfer = allocXfer(STATE_AWAITING_COMP_PARAMS); in handleI2cEvent()
604 if (newXfer != NULL) { in handleI2cEvent()
605 newXfer->txrxBuf[0] = BOSCH_BMP280_REG_DIG_T1; in handleI2cEvent()
606 …ret = i2cMasterTxRx(I2C_BUS_ID, I2C_ADDR, newXfer->txrxBuf, 1, (uint8_t*)&mTask.comp, 24, i2cCallb… in handleI2cEvent()
[all …]
/device/google/contexthub/firmware/os/drivers/rohm_rpr0521/
Drohm_rpr0521.c606 struct I2cTransfer *newXfer; in handle_i2c_event() local
623 newXfer = allocXfer(SENSOR_STATE_INIT_GAINS); in handle_i2c_event()
624 if (newXfer != NULL) { in handle_i2c_event()
625 newXfer->txrxBuf[0] = ROHM_RPR0521_REG_ALS_PS_CONTROL; in handle_i2c_event()
626newXfer->txrxBuf[1] = (ROHM_RPR0521_GAIN_ALS0 << 4) | (ROHM_RPR0521_GAIN_ALS1 << 2) | ROHM_RPR0521… in handle_i2c_event()
627newXfer->txrxBuf[2] = (ROHM_RPR0521_GAIN_PS << 4) | PS_PERSISTENCE_ACTIVE_AT_EACH_MEASUREMENT_END; in handle_i2c_event()
628 i2cWrite(newXfer, 3); in handle_i2c_event()
634 newXfer = allocXfer(SENSOR_STATE_INIT_OFFSETS); in handle_i2c_event()
635 if (newXfer != NULL) { in handle_i2c_event()
636 newXfer->txrxBuf[0] = ROHM_RPR0521_REG_PS_OFFSET_LSB; in handle_i2c_event()
[all …]