Hi Arturo Arteaga,
1. Flash code check
Take an example, MDK associated with JLINK, when you download the code, there has a item: verify code download

If you don't use MDK IDE, just use JLINK with JFLASH to download the code, it also have the verify function:

So, if you just want to check the application code, I suggest you to verify it after download the code.
2. We don't have the lib which can check the whole flash(include the application code) in the code.
As you know, the flash contains the code area and blank flash area, code area, I think you can check it when you downloade the code, other blank flash area which you want to use it by calling the code, you can erase that flash sector, check the flash area data, whether it is 0XFF or not, then write the flash area, read it out, compare with the data you have written.
All these can be realized by the flash erase, write, read, these functions can be found in the C90TFS which I give you before.
Wish it helps you!
Have a great day,
Kerry
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------