Add crossdomain code. Add fan and light control code.