Carbon nanotubes as substrates for molecular spiropyran-based switches