Skip to content
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

Please correct error in SPI busWriteBuf function. #10674

Open
and-sh opened this issue Feb 6, 2025 · 0 comments
Open

Please correct error in SPI busWriteBuf function. #10674

and-sh opened this issue Feb 6, 2025 · 0 comments

Comments

@and-sh
Copy link

and-sh commented Feb 6, 2025

Current Behavior

Due to error can not write buffer to SPI device.

Steps to Reproduce

use busWriteBuf function on spi device.

Expected behavior

buffer to be written in SPI device.

Suggested solution(s)

To write something to registers you need to clear MSB of address. To read set MSB.
This done correctly on busWrite and busRead functions

Correct

Image

Correct

Image

But for buffer something is wrong.

Correct

Image

Incorrect

Image

https://github.com/iNavFlight/inav/blob/master/src/main/drivers/bus.c#L286C1-L286C73

Additional context

All versions of Inav, at least from 3.0.0 have this problem.

@and-sh and-sh changed the title Please correct erroe in SPI c. Please correct error in SPI busWriteBuf function. Feb 6, 2025
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

No branches or pull requests

1 participant