I think Lee was taken by complete surprise how quickly the Army of the Potomac was on his heals.
No, I don't think he was at all. He knew where Hooker was (later Meade). He expected to be followed, wanted to be followed. He turned at Gettysburg because of the roads and strategic importance of that town.