Added memory pointers and bitmasks to set master clk