Units can regain transportation by ending the turn in the same hex as the parent HQ. At the start of the next turn, the unit will regain transportation. It doesn't matter if the parent HQ or combat unit is in T-mode.
Depending on the terrain and distance, it could be more convenient to move the Army HQ to the unit, instead of the unit to the Army HQ, as the Army HQ is probably motorized.