Forum Discussion
Altera_Forum
Honored Contributor
13 years agoYou may include a test of the application FPGA code and Nios code on your flash before handling control over from the factory image.
Several parameters in the boot record can be checked, for example the device ID and the size of the image. By using the size of the image you should find the start of the Nios software code on the flash and there you may read the length of the Nios code. This you may use to check that the code outside this is erased. It is not a perfect test, but it detects if the flash has been partially programmed. Have not found how to verify checksum of the image on flash without calculating it by myslf and storing it on flash. I have not managed to find doumentation on the EPCS flash boot records, but some information can be found in the source of the nios bootloader.