A manipulator comprising: a mounting base for mounting the manipulator; a gripping unit for gripping a drill rod; a swivel arm attached to the mounting base and to the griping unit, wherein the swivel arm comprises at least six controlled swivels (220 to 230) between the mounting base and the gripping unit, wherein each swivel (220 to 230) has an individual axis (500 to 510) of rotation for moving the gripping unit according to a programmed three-dimensional trajectory; at least one processor and at least one memory including a computer program code, wherein the at least one memory and the computer program code are configured, with the at least one processor, to: control the plurality of swivels (220 to 230) to cause the swivel arm to automatically move the gripping unit according to the programmed three-dimensional trajectory between a first position and a second position, wherein: in the first position, the gripping unit is able to grip or release the drill rod directly from/to a storage unit for a plurality of drill rods, and in the second position, the gripping unit is able to grip or release the drill rod when the drill rod is along a drilling axis connected to a drill string entering a borehole; and control the gripping unit to automatically grip or release the drill rod in the first position or in the second position. a mounting base for mounting the manipulator; a gripping unit for gripping a drill rod; a swivel arm attached to the mounting base and to the griping unit, wherein the swivel arm comprises at least six controlled swivels (220 to 230) between the mounting base and the gripping unit, wherein each swivel (220 to 230) has an individual axis (500 to 510) of rotation for moving the gripping unit according to a programmed three-dimensional trajectory; at least one processor and at least one memory including a computer program code, wherein the at least one memory and the computer program code are configured, with the at least one processor, to: control the plurality of swivels (220 to 230) to cause the swivel arm to automatically move the gripping unit according to the programmed three-dimensional trajectory between a first position and a second position, wherein: in the first position, the gripping unit is able to grip or release the drill rod directly from/to a storage unit for a plurality of drill rods, and in the second position, the gripping unit is able to grip or release the drill rod when the drill rod is along a drilling axis connected to a drill string entering a borehole; and control the gripping unit to automatically grip or release the drill rod in the first position or in the second position. control the plurality of swivels (220 to 230) to cause the swivel arm to automatically move the gripping unit according to the programmed three-dimensional trajectory between a first position and a second position, wherein: in the first position, the gripping unit is able to grip or release the drill rod directly from/to a storage unit for a plurality of drill rods, and in the second position, the gripping unit is able to grip or release the drill rod when the drill rod is along a drilling axis connected to a drill string entering a borehole; and control the gripping unit to automatically grip or release the drill rod in the first position or in the second position. in the first position, the gripping unit is able to grip or release the drill rod directly from/to a storage unit for a plurality of drill rods, and in the second position, the gripping unit is able to grip or release the drill rod when the drill rod is along a drilling axis connected to a drill string entering a borehole; and control the gripping unit to automatically grip or release the drill rod in the first position or in the second position.