Okay, got it working (sort of).  I am able to user the new user function to write a drawn pattern to flash memory and then use the unlock function to retrieve the saved pattern and compare it to the new one.  However, some patterns still aren't working and I can't seem to generate more than one pattern each time I reprogram the PIC24.  Probably need to erase the memory first and then write to it each time.  By the way, each word of memory is TWO hex values, that was the problem.