Preheat the oven to 350 degrees. Prepare two 9x13 casserole dishes with nonstick cooking spray.
In a large skillet over medium-high heat, melt the butter. Add the onion and cook until softened. Stir in the flour, thyme, and black pepper, allowing to cook for 1 to 2 minutes. Slowly add the milk and broth to the skillet, stirring constantly. Bring the mixture to a boil and continue stirring until thickened. Remove the skillet from the heat.
In a large mixing bowl, combine the ham, noodles, lemon juice, cream sauce, and asparagus, mixing to combine. Divide the pasta evenly between the two casserole dishes.
Top the casseroles with the cheese.
Bake for 20 minutes. Remove from the oven and add a layer of the fried onions. Return to the oven and continue baking for an additional 5 to 10 minutes.