Agricultural machines spend a significant part of their time on non-productive operations such as maneuvering near the boundaries of the field and loading or offloading of inputs or outputs (here referred to as servicing). This paper integrates existing methods for route optimization so as to minimize the time spent on turns and machine servicing on fields cultivated in straight rows. The following variables are optimized: (1) the orientation (angle) of the tracks, (2) the order of tracks, and (3) the types of turns between tracks. The angle of the tracks relative to field boundaries influences the number and lengths of the machine tracks, the number of turns and the positions where the machine can be serviced. Track order and the type of turns are selected to achieve overall efficiency. The algorithm was tested by computing routes for a set of fields of different sizes and assuming different operations. On small fields that do not require servicing, optimizing the turns between tracks resulted in a reduction of up to 50 % in turning time compared to the prevailing practice of navigation between adjacent tracks. A comparison of two sprayers in terms of servicing efficiency suggested that the algorithm can help selecting machinery for given field geometries. In some cases requiring machine servicing, the track orientation giving the shortest turning time did not produce the least servicing time. This illustrates that machine servicing should be taken into consideration for global optimization of machine traffic.