(&self, ec: &CrosEc, addr: u16)
| 793 | } |
| 794 | |
| 795 | fn read_i16(&self, ec: &CrosEc, addr: u16) -> EcResult<u16> { |
| 796 | let i2c_response = i2c_read(ec, self.i2c_port, self.i2c_addr >> 1, addr, 0x02)?; |
| 797 | i2c_response.is_successful()?; |
| 798 | Ok(u16::from_le_bytes([ |
| 799 | i2c_response.data[0], |
| 800 | i2c_response.data[1], |
| 801 | ])) |
| 802 | } |
| 803 | |
| 804 | /// Read a 32-bit value from a ManufacturerAccess block command (SMBus block format with length prefix) |
| 805 | fn read_i32(&self, ec: &CrosEc, addr: u16) -> EcResult<u32> { |
no test coverage detected