You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 19, 2024. It is now read-only.
Hi,
I'm testing a library for SGP40 and I spent lot of time debuging, why the voc algorithm working on PC but not working on 8-bit MCU (Michrochip PIC18).
The issue is in file
function : static fix16_t fix16_mul(fix16_t inArg0, fix16_t inArg1)
when is at least one parameter negative, than the multiply overflow and returns unexpected result.
I make quick fix and in the algorithm I'm working only with positive numbers
->1. chceck if the result should be positive or negative
->2. both of arguments make positive (abs() )
->3. if result should be negative, return -ret_val;
The text was updated successfully, but these errors were encountered:
Hi @jirihusak many thanks for taking the time to debug and report this! We'll investigate the issue and possibly import your fix. Note that due to the holidays it will likely drag into next year. We'll leave this issue open until then.
We have updated the VOC algorithm to fix the 8-bit mcu fix point aritmetic issue.
Would you mind testing the updated version (release 7.1.2) and update us, if the mentioned issue can be resolved?
Hi,
I'm testing a library for SGP40 and I spent lot of time debuging, why the voc algorithm working on PC but not working on 8-bit MCU (Michrochip PIC18).
The issue is in file
function : static fix16_t fix16_mul(fix16_t inArg0, fix16_t inArg1)
when is at least one parameter negative, than the multiply overflow and returns unexpected result.
I make quick fix and in the algorithm I'm working only with positive numbers
->1. chceck if the result should be positive or negative
->2. both of arguments make positive (abs() )
->3. if result should be negative, return -ret_val;
The text was updated successfully, but these errors were encountered: