Quote Originally Posted by In-Tech View Post
How many bytes are you writing in each block?
Ls Droid works with strings rather then bytes so packet size it a bit misleading here but my App is writing 2K blocks(4K characters).

Curious how you verify the write is correct? Thanks
Do you mean on each block or at the end of the flash?

Each block uses a checksum that the PCM verifies when a block is written. If the checksum calculated by the flash kernel does not match the value sent by the app the kernel will reply with a 7F message indicating the checksum is incorrect. Each block also has a size value attached to it that the flash kernel checks to make sure the block is complete. If the block is not the correct size specified there is also a corresponding 7F message that will be sent back to the app by the flash kernel.



When the flash is complete the app also checks for a complete write at the end in 2 ways, first it checks the kernel to make sure the correct number of blocks have been written and then it reads the last 2 bytes of the PCM by address to make sure they are correct. If either check fails the app will alert the user and the flash kernel will continue running and allow you to start the flash over again with the same file or with another file if you'd rather write something else.