added multiplexer and adjusted constants