a gardening tool such as a grass trimmer is provided with a tool head , a motor for driving the tool head , a front housing for accommodating the motor , a trigger switch for activating the motor , a trigger operable to control the trigger switch , a battery pack for providing electric energy to the motor , a circuit board for electrically connecting the motor to the battery pack , and a rear housing for accommodating the circuit board . the rear housing forms a housing chamber for accommodating the trigger switch , the circuit board , and wires between the circuit board and the trigger switch .