Aquarium Reef Controller, stage 1, the LCD shield,

The technique you're looking for is called a "state machine".
While the arduino supports some object orientated programming, you're still mostly doing procedural programming.

A state machine is the thing to use in these situations.
Essentially, your menu would have 3 or 4 states.

  1. (default) display data
    if button is pressed, go to state 2
  2. display the basic menu options
    if button is pressed, either change the selection or go to the state of the selected item
  3. light intensity was chosen, button up raises the intensity displayed, button down lowers it. the select button changes the output, has a delay, and returns to state 1.

Now I won't do your work for you and put it into actual code, but I hope you get the idea now :slight_smile: