Skip to content

Commit

Permalink
Merge pull request #23 from jrw429/master
Browse files Browse the repository at this point in the history
correct type
  • Loading branch information
caternuson committed May 16, 2023
2 parents e62011d + c43f19a commit 4d16fb1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Adafruit_AS7341.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ bool Adafruit_AS7341::begin(uint8_t i2c_address, TwoWire *wire,
*/
bool Adafruit_AS7341::_init(int32_t sensor_id) {

// silence compiler warning - variable may be used in the future
(void)sensor_id;

Adafruit_BusIO_Register chip_id =
Adafruit_BusIO_Register(i2c_dev, AS7341_WHOAMI);

Expand Down Expand Up @@ -240,7 +243,7 @@ void Adafruit_AS7341::delayForData(int waitTime) {
if (waitTime > 0) // Wait for that many milliseconds
{
uint32_t elapsedMillis = 0;
while (!getIsDataReady() && elapsedMillis < waitTime) {
while (!getIsDataReady() && elapsedMillis < (uint32_t)waitTime) {
delay(1);
elapsedMillis++;
}
Expand Down

0 comments on commit 4d16fb1

Please sign in to comment.