Done for the night

Added dimmer, added debug mode.