Cockroaches exploit tactile cues from their antennae to avoid predators. During escape running the same sensors are used to follow walls. We hypothesise that selection of these mutually exclusive behaviours can be explained without representation of the stimulus or an explicit switching mechanism. A neural model is presented that embodies this hypothesis. The model incorporates behavioural and neurophysiological data and is embedded in a mobile robot in order to test the response to stimuli in the real world. The system is shown to account for data on escape direction and high-speed wall-following in the cockroach, including the counter-intuitive observation that faster running cockroaches maintain a closer distance to the wall. The wall-following behaviour is extended to include discrimination of tactile escape cues according to behavioural context. We conclude by highlighting questions arising from the robot experiments that suggest interesting hypotheses to test in the cockroach.