A recording/producing device for writing data on a recording medium, or reading data from the recording medium, wherein data matching a recording pattern so specified as to include a plurality of mutually different sets of mark lengths and space lengths is written on the recording medium, and the data is then read to generate data signals. An edge shift detector uses data signals to measure the edge shift amount of a mark formed on a recording medium for each set of a mark length and a space length. A record controller sets a recording parameter for each set of a mark length and a space length based on the measured edge shift amount.