melexis / mlx90640-library

MLX90640 library functions
Apache License 2.0
241 stars 192 forks source link

Sample data to validate API #4

Closed adibacco closed 4 years ago

adibacco commented 6 years ago

In reference to the following code snippet:

_static uint16_t eeMLX90640[832]; static uint16_t mlx90640Frame[834]; paramsMLX90640 mlx90640; static float mlx90640To[768]; MLX90640_DumpEE (slaveAddress, eeMLX90640); MLX90640_ExtractParameters(eeMLX90640, &mlx90640); MLX90640_GetFrameData (0x33, mlx90640Frame); tr = MLX90640_GetTa(mlx90640Frame, &mlx90640) – TA_SHIFT; MLX90640CalculateTo(mlx90640Frame, &mlx90640, emissivity, tr, mlx90640To);

It would be really nice if you could upload a file with the eeMLX90640, mlx90640Frame, mlx90640, mlx90640To and tr

Just as test to prove that the API are doing their job.

slavysis commented 6 years ago

That is a great suggestion and I am currently working on it. I will upload it soon.

Best regards

adibacco commented 6 years ago

That is good news. This will make your wonderful library even more useful. In theory in the datasheet there are some examples but getting all data from a PDF is not so easy. In this way, anyone could verify if the code is performing correctly. I just need to export those data structures from Eclipse (View->Memory export raw binary) and do a comparison.

adibacco commented 6 years ago

Just to start I'm attaching eeprom contents as reported in MPLX90640 datasheet "Revision 11, 4 may 18".

eeData_content.txt

slavysis commented 6 years ago

I have uploaded a xlsx file with input data - EEPROM data, frame 0 data and frame 1 data in the first sheet. The second sheet contains all the parameters that should be extracted based on that input EEPROM data. In the third sheet you can find the object temperatures calculated based on the input data and the extracted parameters. I hope this will be helpful and if you have some suggestions how to make this file a better tool, please let me know.

Best regards

adibacco commented 6 years ago

Really awesome data. They are very useful, what emissivity did you use?

slavysis commented 6 years ago

Emissivity is 1.0.

Best regards