An apparatus for planning a drilling sequence for a rock drilling rig comprising at least two drilling booms (Boom1 - Boom3), which are provided with drilling units for drilling drill holes to a face of a rock surface ; the apparatus comprises at least one control unit (CU), comprising a processor for executing a drilling sequence planning program ; the control unit (CU) is provided with a drilling pattern comprising drill hole data on drill holes to be drilled, wherein the drill hole data comprises at least position data of starting points of the drill holes ; and wherein execution of the drilling sequence planning program in the processor of the apparatus is configured to generate a drilling sequence for the provided drilling pattern , wherein the drilling sequence comprises data on drilling order of the drill holes and selection of boom for drilling each drill hole ; characterized in that the control unit (CU) is provided with data on drilling booms, wherein the data comprises data on number of the booms, reach of the booms, and further, positions of the booms relative to the drilling pattern ; the control unit (CU) is configured to search several drilling steps further for each drilling unit , and based on that, is configured to produce several possible drilling sequence scenarios each of which defining different drilling order, drilling unit selection and transfers of the drilling units between neighboring drill holes ; the control unit (CU) is provided with at least one data element comprising pre-determined rules for defining cost values for several possible actions of the drilling steps; the control unit (CU) is configured to detect actions required by the drilling steps of the searched drilling sequence scenarios and is configured to calculate total costs for the searched drilling sequence scenarios based on the mentioned rules; and the control unit (CU) is configured to select one drilling sequence scenario of the examined scenarios having the lowest total cost for the several following drilling steps. the apparatus comprises at least one control unit (CU), comprising a processor for executing a drilling sequence planning program ; the control unit (CU) is provided with a drilling pattern comprising drill hole data on drill holes to be drilled, wherein the drill hole data comprises at least position data of starting points of the drill holes ; and wherein execution of the drilling sequence planning program in the processor of the apparatus is configured to generate a drilling sequence for the provided drilling pattern , wherein the drilling sequence comprises data on drilling order of the drill holes and selection of boom for drilling each drill hole ; characterized in that the control unit (CU) is provided with data on drilling booms, wherein the data comprises data on number of the booms, reach of the booms, and further, positions of the booms relative to the drilling pattern ; the control unit (CU) is configured to search several drilling steps further for each drilling unit , and based on that, is configured to produce several possible drilling sequence scenarios each of which defining different drilling order, drilling unit selection and transfers of the drilling units between neighboring drill holes ; the control unit (CU) is provided with at least one data element comprising pre-determined rules for defining cost values for several possible actions of the drilling steps; the control unit (CU) is configured to detect actions required by the drilling steps of the searched drilling sequence scenarios and is configured to calculate total costs for the searched drilling sequence scenarios based on the mentioned rules; and the control unit (CU) is configured to select one drilling sequence scenario of the examined scenarios having the lowest total cost for the several following drilling steps. <EOS>