mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-11-10 15:04:19 +00:00
Fix address in I2C scanner (#865)
This commit is contained in:
parent
fbd05598ad
commit
c2c17c761e
1 changed files with 2 additions and 2 deletions
|
@ -472,8 +472,8 @@ void cli_command_i2c(Cli* cli, string_t args, void* context) {
|
|||
for(uint8_t row = 0; row < 0x8; row++) {
|
||||
printf("%x | ", row);
|
||||
for(uint8_t column = 0; column <= 0xF; column++) {
|
||||
bool ret =
|
||||
furi_hal_i2c_rx(&furi_hal_i2c_handle_external, (row << 4) + column, &test, 1, 2);
|
||||
bool ret = furi_hal_i2c_rx(
|
||||
&furi_hal_i2c_handle_external, ((row << 4) + column) << 1, &test, 1, 2);
|
||||
printf("%c ", ret ? '#' : '-');
|
||||
}
|
||||
printf("\r\n");
|
||||
|
|
Loading…
Reference in a new issue