inputted to a flag a in step s6 the transmissivity vo is stored in the address vladr in the resister ma in step s7 a check is performed whether the flag vsel is 11111 or not if not the flag vsel is replaced with a next value and an address next to the address vladr is established in the register madr thereafter control is returned to step s4 by repeating this operation at each address in the register madr a transmissivity corresponding to a respective value of the flag vsel is stored if the contents of the flag is 11111 the control is returned to the main routine after lighting the lamp 20 in step s9 thus all sensitivities vo corresponding to the received lights at the receiver 6 are obtained when the lower cloth is disposed between the emitter 5 and the receiver 6 and are stored in the ram 21 when the switch 19 is closed in step s10 a routine for detecting the transmissivity of the upper cloth and the lower cloth arranged in layered configuration is performed in step s12 5 bit flag vsel to be inputted to the ports p3 through p7 is initialized at 0 and the contents of the register madr is set to an address vhadr at which is initially to be stored the transmissivity of the upper cloth arranged in layered configuration with the lower cloth thus initialization is completed in.