To solve this optimization problem, we first need to define the decision variables and the objective function. Let's denote:

- \(x_1\) as the number of boxes of nutritional cereal produced,
- \(x_2\) as the number of boxes of kids' cereal produced,
- \(x_3\) as the number of boxes of sugary cereal produced.

The objective is to maximize revenue. Given the revenues per box are $1 for nutritional cereal, $1.50 for kids' cereal, and $2 for sugary cereal, the total revenue \(R\) can be represented as:
\[ R = x_1 + 1.5x_2 + 2x_3 \]

We have constraints based on the availability of oat and sugar:

- Each box of nutritional cereal requires 3 units of oat, so \(3x_1\),
- Each kids' cereal requires 1.5 units of oat, so \(1.5x_2\),
- Each sugary cereal requires 2 units of oat, so \(2x_3\).
Given 500 units of oat are available, the oat constraint is:
\[ 3x_1 + 1.5x_2 + 2x_3 \leq 500 \]

For sugar:
- Each box of nutritional cereal requires 1 unit of sugar, so \(x_1\),
- Each kids' cereal requires 1.5 units of sugar, so \(1.5x_2\),
- Each sugary cereal requires 4 units of sugar, so \(4x_3\).
Given 700 units of sugar are available, the sugar constraint is:
\[ x_1 + 1.5x_2 + 4x_3 \leq 700 \]

Also, we cannot produce a negative number of cereals, so:
\[ x_1 \geq 0, x_2 \geq 0, x_3 \geq 0 \]

Now, let's translate this into Gurobi code in Python:

```python
from gurobipy import *

# Create a new model
m = Model("Cereal_Production")

# Define the decision variables
x1 = m.addVar(name="Nutritional_Cereal", vtype=GRB.CONTINUOUS, lb=0)
x2 = m.addVar(name="Kids_Cereal", vtype=GRB.CONTINUOUS, lb=0)
x3 = m.addVar(name="Sugary_Cereal", vtype=GRB.CONTINUOUS, lb=0)

# Set the objective function
m.setObjective(x1 + 1.5*x2 + 2*x3, GRB.MAXIMIZE)

# Add constraints
m.addConstr(3*x1 + 1.5*x2 + 2*x3 <= 500, name="Oat_Constraint")
m.addConstr(x1 + 1.5*x2 + 4*x3 <= 700, name="Sugar_Constraint")

# Optimize the model
m.optimize()

# Print the results
for v in m.getVars():
    print(f"{v.varName}: {v.x}")

print(f"Objective Value: {m.objVal}")
```