get_dat_matrix now reads from a text file
Master and slave now get params from text file