This article demonstrates a new method of programming artificial chemistries. It uses the emerging capabilities of the system's dynamics for information-processing purposes. By evolution of metabolisms that act as control programs for a small robot one achieves the adaptation of the internal metabolic pathways as well as the selection of the most relevant available exteroceptors. The underlying artificial chemistry evolves efficient information-processing pathways with most benefit for the desired task, robot navigation. The results show certain relations to such biological systems as motile bacteria.