It looks like I can eliminate the filter function by using "subshell piping" to allow passing vars outside the loop. Also, after trying a number of string splitting methods that do not work on the touch busybox shell, I found one that does work.
Because this is an interactive application, I want to optimize it for speed by not calling external processes (like "[" and "cat"), replacing them with built-ins (like "[[" and shell string functions) whenever possible.
I will post an updated script soon.
I am redirecting my shell script STDOUT and STDERR to the eInk screen now, and I will eventually use this touchscreen hack to add onscreen keyboad support, for use in recovery (or other) shell scripts, with minimal dependency on external processes.
Last edited by geekmaster; 03-03-2012 at 11:38 AM.