arduino-lmic icon indicating copy to clipboard operation
arduino-lmic copied to clipboard

No sign bit in uflt12f JavaScript decoder

Open jlesech opened this issue 2 years ago • 2 comments

Fix the uflt12f JavaScript decoder in README.

jlesech avatar Aug 27 '22 08:08 jlesech

The uflt12f decoder is for unsigned floats, to save bits for values like relative humidity that can't physically take negative values. That's why the name begins with u. So this change is really not applicable. Also, sSign (where it was added in the patch), is it not in scope in the local the function, and will either cause a runtime error or will cause the sign to be set by unrelated global data.

The custom in this project is to put unrelated changes in different PRs, so the abp feather changes should be a different PR. Thanks!

terrillmoore avatar Aug 27 '22 13:08 terrillmoore

I understand the goal of the uflt12f decoder :) But the goal of my PR is to remove it the sSign variable, not add it.

Sorry for the unrelated change, I did a mistake on my master branch. I removed the unrelated commit and I created another PR for the example sketch.

jlesech avatar Aug 27 '22 15:08 jlesech