Skip to content

Catch the development branch to main #6

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Mar 5, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ The following examples are provided with the library

## Documentation

The full API and use documentation for this library is provided [here](http://docs.sparkfun.com/SparkFun_Qwiic_Ultrasonic_Arduino_Library/). For a quick reference, the main methods available in the library are listed [here](https://docs.sparkfun.com/SparkFun_Qwiic_Ultrasonic_Arduino_Library/functions.html).

The full API and use documentation for this library is provided [here](http://docs.sparkfun.com/SparkFun_Qwiic_Ultrasonic_Arduino_Library/). For a quick reference, the main methods available in the library are listed [here](https://docs.sparkfun.com/SparkFun_Qwiic_Ultrasonic_Arduino_Library/class_qwiic_ultrasonic.html).

Curious about the hardware this board works with - visit the SparkFun Qwiic Ultrasonic Distance Sensor [hardware repository](https://github.com/sparkfun/SparkFun_Ultrasonic_Distance_Sensor-Qwiic).

Expand Down
2 changes: 1 addition & 1 deletion docs/doxygen/doxygen-config
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ ALWAYS_DETAILED_SEC = YES
# operators of the base classes will not be shown.
# The default value is: NO.

INLINE_INHERITED_MEMB = NO
INLINE_INHERITED_MEMB = YES

# If the FULL_PATH_NAMES tag is set to YES, doxygen will prepend the full path
# before files name in the file list and in the header files. If set to NO the
Expand Down
6 changes: 3 additions & 3 deletions src/sfTk/sfDevUltrasonicDist.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ sfTkError_t sfDevUltrasonicDist::triggerAndRead(uint16_t &distance)
uint8_t rawData[2] = {};

// Get the distance
sfTkError_t err = _theBus->readRegisterRegion(kUltrasonicDistanceReadCommand, rawData, numBytes, bytesRead);
sfTkError_t err = _theBus->readRegister(kUltrasonicDistanceReadCommand, rawData, numBytes, bytesRead);

// Check whether the read was successful
if (err != ksfTkErrOk)
Expand All @@ -82,7 +82,7 @@ sfTkError_t sfDevUltrasonicDist::changeAddress(uint8_t &address)
return ksfTkErrFail;

// Write the new address to the device. The first bit must be set to 1
err = _theBus->writeByte(address | 0x80);
err = _theBus->writeUInt8(address | 0x80);
}
else if (_fwVersion == kQwiicUltrasonicFWLatest)
{
Expand All @@ -96,7 +96,7 @@ sfTkError_t sfDevUltrasonicDist::changeAddress(uint8_t &address)
const uint8_t toWrite[2] = {kUltrasonicAddressChangeCommand, tempAddress};

// Write the new address to the device
err = _theBus->writeRegion(toWrite, numBytes);
err = _theBus->writeData(toWrite, numBytes);
}
else
{
Expand Down
Loading