Yes, and thank you for all your help with this project.
Finally got this working well. Attached are the code, the complete circuit, and a bit of explanation on how the RNG portion of the circuit works.
I REALLY appreciate all the ideas and effort in helping with this project! Prior obligations require a few day hiatus in my work on this, but I look forward to trying out the change in approach, and I will post the entire and circuit when I have it working properly. Thanks again.
I am ignorant on how to ensure the stacks are not exceeded. By stop, I mean that after the NewPWbutton is pushed, sometimes only 13, or 14, or 15 characters are displayed on the LCD. I get a new set of characters each time I press the button, and often will get all 16 characters the code asks for, but not each time. Code attached. Thanks again for your help.
Anobium, Substituting your code completely eliminated the problem with the PIC freezing. Now, the code completes to display 16 characters often, but stops most often at 14 characters, sometimes at 15, sometimes at 13. I thought that perhaps one of the ASCII codes might result in truncation of the LCD display, but the range limitation (code 33-126 minus 92) seems appropriate. I tried adding time delays in the Display sub, but that didn't help. The randomness of the display has me foxed.
Thanks Stan and Anobium; this information will be very helpful with my project!
Thanks very much! I have no formal computer science education, and your response led me to learn about how stacks work, and how deep recursion results in stack overflow.
Thank you; code attached. Project description: An external random number generator circuit feeds random bytes to PORTB, code checks for uniqueness, then displays bytes as printable ASCII characters.