How to enter/exit a stock that is locked with upper circuit/lower circuit

If a stock (for example Ruchi Soya) is locked with upper circuit, is it possible to enter (BUY) it, if yes how?

Similarly, if one wants to exit a stock (Adani Green) which is locked with lower circuit, how to exit?

You can place AMO or order right after market open to Buy/Exit stocks hitting Upper/Lower Circuit but there is no guarantee that your order will get filled as in Upper Circuit stocks there will be plenty of willing buyers while very low sellers and in stocks hitting Lower Circuit there will be plenty of sellers but very less buyers, due to this imbalance Buying and Exiting such stocks isn’t easy.

Thank you very much.