According to the present invention, a channel protection film is formed a little smaller in area than the gate electrode formed of a shielding metal film. The invention also relates to a method for transforming a locking mechanism to an end-of-stroke mechanism. Electrically conductive particles are then added to the resin to form a mixture.