Air Conditioner works great around town but car is like a sauna on a trip

1999 Nissan Maxima. My AC works great until I take a trip. About an hour into the trip the AC slowly stops cooling. I turn the fan onto high to unthaw, this works a little but it is still very warm. If I slow down to about 45 going through a town the cooling will improve until I return to highway speed. My mechanic has checked the freon, changed the sensor two times. When it has stopped cooling I have checked under the hood and the AC is still clicked in, as if the AC does not click off when it is cool enough and freezes. My mechanic has come to the conclusion that there may be something in the computer. Does any one have any ideas.

Check your engine vacuum at road speed. If the engine is getting tired, it may not draw enough vacuum to keep the blend door in the “cool” position…

On a trip, you could try turning the AC on and off every 30 seconds or so to mimic what the “freeze prevention” thermistor and circuit are supposed to do. This would confirm your suspicions.