These notes of a course given at IRMA in April 2009 cover some aspects of the representation theory of fundamental groups of manifolds of dimension at most 3 in compact Lie groups, mainly SU(2). We give detailed examples, develop the techniques of twisted cohomology and gauge theory. We review Chern–Simons theory and describe an integrable system for the representation space of a surface. Finally, we explain some basic ideas on geometric quantization. We apply them to the case of representation spaces by computing Bohr–Sommerfeld orbits with metaplectic correction.