The method involves operating a driving motor (4) by a control unit (5). The root canal instrument (3) is connected with the output shaft (6). The reciprocation movement of root canal instrument is enabled in different rotation directions with respect to different rotation angles respectively. Independent claims are included for the following: (1) device for controlling driving apparatus for root canal instrument; and (2) rotary handpiece for treating root canal.