Skip to content

Commit

Permalink
no reverse bits
Browse files Browse the repository at this point in the history
  • Loading branch information
Sabramz committed Jun 1, 2024
1 parent 93a2446 commit 00bd491
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion general/src/pca9539.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ HAL_StatusTypeDef pca9539_write_pin(pca9539_t* pca, uint8_t reg_type, uint8_t pi
return status;
}

data_new = reverse_bits(data & ~(1u << pin)) | (buf << pin);
data_new = (data & ~(1u << pin)) | (buf << pin);

return pca_write_reg(pca, reg_type, &data_new);
}

0 comments on commit 00bd491

Please sign in to comment.