Clean, wash and soak 1 cup horse gram in warm/hot water for about 2 hours. Soaking helps in cooking the horse gram quicker.
Discard the water, transfer the soaked horse gram to a pressure cooker. Add about 2.5 cups water. Pressure cook for 4 whistles and let the pressure release naturally.
Next, drain this water and transfer to a container in which you will be making the rasam.
Then, again add about 1.25 cups water to the cooked horse gram and pressure cook for 3 or 4 more whistles. Drain the water like before and transfer to the same container. (refer notes 1)
In a small pan, add a tsp oil and in low heat roast 2.5 tsp coriander seeds, 1.25 tsp cumin seeds, 1/4 tsp fenugreek seeds, 1/3 tsp mustard seeds, 8 to 10 peppercorns, 8 byadagi/kashmiri dry red chillies, 2 guntur dry red chillies. All the spices should turn aromatic but make sure you don't burn them. (refer notes 2)
Let them all cool for some time and then transfer to a mixer jar along with 3 tbsp fresh grated coconut, 6 to 8 curry leaves, 1 onion fairly chopped (or 1/2 a large onion), a pinch of turmeric and asafoetida, 1 ladle of cooked horse gram.
Add water as required and make a smooth paste.
Transfer the ground masala to the cooked horse gram stock kept aside previously. Mix it thoroughly.
Also, soak a small gooseberry size tamarind in water for some time and squeeze the water. Add this as well.
Boil this for 8 to 10 minutes so that the rawness of the masala disappears and it cooks well. Add water if required. I did not add extra water other than the stock and some water that was used to transfer the contents in the mixer jar.
Add salt to taste and boil it for just a minute.
Finally, make a tempering with ghee/oil, mustard seeds, asafoetida, curry leaves, dry red chillies (optional). Pour this to the hot rasam along with chopped coriander leaves.
Immediately close a lid to trap the aroma well.