astronomerroyal
New Member
Hi, I have a numeric keypad + LCD interface for my PIC project. Currently it only displays the value of the key you've pressed, and stores its face value in a register. That alone is a minor miracle, mostly thanks to Wilmshurst's book and Ilett's document.
I want to now add a useful and basic menu system. The user enters a value (for now just a one digit number) and presses ENTER. They may then go to a sub-menu and so on ... setting the flags and entering parameters that define the subsequent flow of the program.
I believe this is called a 'hierarchical menu system' and I was hoping to find a well thought out framework, upon which I would expand. I don't know C yet, so I want to do it in assembly.
What I would like to see is a descriptive overview, pseudo-code, or a pointer to a book or website that addresses this topic.
I realize there are many types of menu, so am mostly interested in seeing a cross-section of the methods used.
Some issues:
1) linear code vs. subroutines.
2) Many unique menus vs. single menu template that uses indirect addressing to send the data to the right register.
3) What are the factors that affect choice of design (e.g number of menu levels)?
4) How best to store the menu descriptions (e.g. individual characters in a 'computed goto' look-up table?)
5) What to do when user must enter multiple digit decimal numbers.
Many thanks in advance for your thoughts, and for reading this far,
AR.
I want to now add a useful and basic menu system. The user enters a value (for now just a one digit number) and presses ENTER. They may then go to a sub-menu and so on ... setting the flags and entering parameters that define the subsequent flow of the program.
I believe this is called a 'hierarchical menu system' and I was hoping to find a well thought out framework, upon which I would expand. I don't know C yet, so I want to do it in assembly.
What I would like to see is a descriptive overview, pseudo-code, or a pointer to a book or website that addresses this topic.
I realize there are many types of menu, so am mostly interested in seeing a cross-section of the methods used.
Some issues:
1) linear code vs. subroutines.
2) Many unique menus vs. single menu template that uses indirect addressing to send the data to the right register.
3) What are the factors that affect choice of design (e.g number of menu levels)?
4) How best to store the menu descriptions (e.g. individual characters in a 'computed goto' look-up table?)
5) What to do when user must enter multiple digit decimal numbers.
Many thanks in advance for your thoughts, and for reading this far,
AR.
Last edited: