Measure the width of the bunk bed frame at the location where you will be installing your shelving. Decide whether you wish for the shelf to be the same length as the bunk bed or inset slightly from the edges. Have your measurement reflect that decision.
Transfer the measurement to the shelf board by setting out the measuring tape along the board and marking the previous distance with a pencil. Use the measuring tape or some straight surface to turn the marking into a line perpendicular to the length of the board.
Cut the board along the marked line using the saw, positioning the main part of the board on a table or flat surface and leaving the end free to drop down when severed. Use sandpaper to sand the cut edges to the desired roundness or smoothness and repeat this motion for the rest of the board's edges.
Position the shelf at the desired spot on the bunk bed and place the carpenter's level on top of it. Once the shelf has been made level, make two markings directly above the board, with each marking evenly centered on the bunk bed support to which the shelf will be attached. Remove the board and use the measuring tape to move those markings quarter of an inch downward, erasing the previous markings.
Pre-drill holes through both markings using the drill and a drill bit that is just smaller than the 2-inch wood screws. Hold the shelf board back in place and use the pencil or a long screw to mark the back of the shelf board through those pre-drilled holes. Remove the shelf board and predrill 1-inch holes in the markings on the shelf board.
Return the shelf board to its position and attach it to the bunk bed using the 2-inch wood screws. Test its strength and attachment, and add additional wood screws with pre-drilled holes if necessary based on the length of the shelf and the weight of the objects that the shelf will hold.