When booking a roomette on an Amtrak train, meals are included. Based on the time of boarding and detraining, how do I know if I'm entitled to a particular meal the same day? For example, if I arrive at Denver at 6:38 PM (18:38), do I get dinner before I leave the train? If, a week later, I depart from Denver with the same train at 7:10 PM (19:10), do I get dinner after entering?
That's a good question, but it is dependent on quite some factors.
They usually postpone or advance the meal times depending on the stops. Denver is a long stop, for maintenance (I suppose you will be on the California Zephyr) so it will probably be either earlier or later.
Remember also that Amtrak is not always on time (particularly after 2 days running). So it is likely that you will not arrive at 6.38pm but maybe a little later (or earlier).
To answer precisely your question, Amtrak mentions the following : "Lunch reservations are taken from 11:30 am - 3 pm; dinner reservations are taken from 5 pm - 9 pm."
So I would say you can expect to have an early dinner on the train in this case. You can still ask your car attendant the exact policy about it when you board the train, if you are unsure.