Added support for MPU6500 basic functionality#581
Added support for MPU6500 basic functionality#581universam1 merged 9 commits intouniversam1:masterfrom
Conversation
|
You need to patch the MPU6050.cpp file as well or it will fail on this function; accelgyro.testConnection(). This code will work;
|
I didn't want to make any changes to the standard MPU6050 repository so I tried to remove the "accelgyro.testConnection()" line in the main ISpindel.cpp file and replace it so that function was never used. Did I miss it somewhere else other than the repo? |
Sorry, my misstake. didnt look at the changes. just noticed that there was a call to that method in the code. |
universam1
left a comment
There was a problem hiding this comment.
Linter : code formatter fails
|
Is it worth altering that if statement a bit by adding brackets so as to not rely on operation order i.e.: |
https://docs.microsoft.com/en-us/cpp/c-language/precedence-and-order-of-evaluation?view=msvc-170 parentheses are not necessary here |
|
I know they aren't strictly needed, it's more of a good practise / style kind of thing, also for readability. |
I honestly have no idea what this is. I haven't changed this from your master branch. Any ideas why it's failing on here but not when I build it on my PC? |
|
Could I please get some advice on how to deal with the Linter fail, any pointer would be greatly appreciated. I honestly have no idea why it keeps failing. https://github.com/universam1/iSpindel/runs/6349107436?check_suite_focus=true |
|
Is the dark green stuff in the files changed bit the stuff the linter doesn't like? I can't find the results of the linter. |
|
It's in the link below. I added the linter to my fork for testing. https://github.com/Bananamannn/iSpindel/runs/6418152846?check_suite_focus=true |
|
@Bananamannn All you had to to to get rid of format errors is just execute "Format document" command in VS Code (assuming you have clang-format installed by default) |
Oh right, thanks for the info. I'll defiantly do it that way next time. I did it all through the Github editor this round. |
Bananamannn
left a comment
There was a problem hiding this comment.
Fixed formatting. Linter now passes
universam1
left a comment
There was a problem hiding this comment.
+1
Excellent @Bananamannn thanks for contribution

Will need to be double checked using a MPU6050 as I don't have one on hand. However MPU6500 seems to work just fine