Skip to content

Initial commit for Review - #1

Merged
FacioErgoSum merged 1 commit into
mainfrom
development
Oct 29, 2026
Merged

FacioErgoSum merged 1 commit into
mainfrom
development

Conversation

@FacioErgoSum

Copy link
Copy Markdown
Collaborator

No description provided.

@gigapod gigapod left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor things

Comment thread src/sfTk/sfDevBMI330.cpp
sfTkError_t sfDevBMI330::begin(sfTkIBus *theBus)
{
// Adopt the supplied bus if one was given; otherwise keep whatever a prior call set.
if (theBus != nullptr)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just return if the bus is null. If not, then set the comm bus. No need for two if()s

Comment thread src/sfTk/sfDevBMI330.cpp

// How many dummy bytes precede read data is a property of the interface, not the register, so
// settle it once here rather than testing the bus type on every read.
if (_theBus != nullptr && _theBus->type() == ksfTkBusTypeSPI)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style - I'd just make this an inline if.

_dummyBytes = (_theBus != nullptr && _theBus->type() == ksfTkBusTypeSPI) ? kDummyBytesSPI : kDummyBytesI2C.

@FacioErgoSum
FacioErgoSum merged commit 93592c1 into main Oct 29, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants