the different stages and aspects of meditation need to be practiced, and are attained in the context of a coherent holistic path, according to the Buddha’s teaching. A convenient and comprehensive scheme is the one of virtue (sīla), concentration or meditation (samādhi), and wisdom (paññā). So let me outline in more detail accordingly, though thereby I also refer to exegetical material, and not just sutta alone.
A discourse which illustrates the detailed and process-like nature of this path runs as follows:
Thus, Ānanda, (1)–(2) the purpose and benefit of wholesome virtuous behavior is non-regret; (3) the purpose and benefit of non-regret is joy; (4) the purpose and benefit of joy is rapture; (5) the purpose and benefit of rapture is tranquility; (6) the purpose and benefit of tranquility is pleasure; (7) the purpose and benefit of pleasure is concentration; (8) the purpose and benefit of concentration is the knowledge and vision of things as they really are; (9) the purpose and benefit of the knowledge and vision of things as they really are is disenchantment and dispassion; and (10) the purpose and benefit of disenchantment and dispassion is the knowledge and vision of liberation. Thus, Ānanda, wholesome virtuous behavior progressively leads to the foremost. (AN X, 1)
This classification fits in with all other usual classifications of the path such as the seven factors of enlightenment (satta bojjhaṅgā) and the noble eight-fold (or ten-fold) path (ariya aṭthaṅgika magga). So it is of crucial importance to note that one cannot develop right Buddhist meditation apart from virtue. In what follows therefore a brief summary of what is the purity of virtue according to an ancient Buddhist manual, the visuddhi-magga, which here does not seem to contradict anything I know from the suttas.
Untornness, however, is accomplished by the complete non-breaking of the training precepts, by making amends for those broken for which amends should be made, by the absence of the seven bonds of sexuality, and, as well, by the non-arising of such evil things as anger, enmity, contempt, domineering, envy, avarice, deceit, fraud, obduracy, presumption, pride (conceit), haughtiness, conceit (vanity), and negligence (MN 7), and by the arising of such qualities as fewness of wishes, contentment, and effacement (MN 24).
Important to note that purity of virtue is not just merely keeping the precepts but also purified mental states can be classified under virtue. This is the kind of virtue which leads to samādhi. It is interesting to note also that this purity depends largely on qualities mentioned last in the foregoing quote, also seclusion (viveka is I think the Pāli word here) is part of the series actually.
So having purified yourself in virtue this way you may, in brief synopsis, attend to a meditation subject according to your inclination among the 38 (or 40), such as mindfulness of breathing (ven. Ñanamoli has written a comprehensive account on this subject: https://www.bps.lk/olib/bp/bp502s.pdf), loving-kindness meditation (Ñanaponika I would like to refer here to: http://www.accesstoinsight.org/lib/authors/nyanaponika/wheel006.html) , color contemplation or meditation on the Buddha etc. These subjects can be classified also among the famous four foundations of mindfulness (satipaṭṭhāna). Also insight meditation (vipassanā), the intuitive and liberating grasp of the true nature of things is classified among these satipaṭṭhāna. The settled, continuous, knowing, wise application of these might be called successful meditation. This passage from the mahāsatipaṭṭhāna-sutta (DN 22) reflects this approach on the basis of the above mentioned accomplishment in virtue:
Here, monks, a monk dwells contemplating (the nature of) the body [mindfulness of breathing fits under this category among others] in the body, ardent, fully aware, and mindful, after removing avarice and sorrow regarding the world. […] Here, monks, a monk who has gone to the wilderness, or has gone to the root of a tree, or has gone to an empty place, sits down. After folding his legs crosswise, setting his body straight, and establishing mindfulness at the front, being very mindful he breathes in, mindful he breathes out.
Ven. Anālayo has written a good book about satipaṭṭhāna, which can be downloaded and read here, free of charge: https://www.buddhismuskunde.uni-hamburg.de/pdf/5-personen/analayo/direct-path.pdf. For more see the visuddhi-magga.
Also Rupert Gethin tries to analyze in a nice paper the nature of meditation according to the pāli-nikāyas. Free access here: https://www.academia.edu/11728648/On_the_practice_of_Buddhist_meditation_according_to_the_Pali_Nikāyas_and_exegetical_sources
A good discussion on the term samādhi also here: https://dhammawheel.com/viewtopic.php?f=23&t=10150&start=20
Hope that helped at least a bit in further guiding.