All perfect praise be to Allah, The Lord of the worlds. I testify that there is none worthy of worship except Allah and that Muhammad, sallallahu ‘alayhi wa sallam, is His slave and Messenger.
If the person hears the athaan while eating or reciting the Quran, he should stop eating or reciting in order to reply to the mu'aththin (repeat after him). An-Nawawi wrote about replying to the athaan, "If the Muslim hears the athaan while reading, reciting Thikr (expressions of remembrance of Allah), listening to a religious lesson, or the like, he should interrupt that, reply to the athaan, and then resume whatever he was doing if he wishes to do so." [Al-Majmoo‘]
Ibn Taymiyyah wrote, "When a person hears the athaan while reciting the Quran or supplicating, he should pause and reply to the athaan because otherwise he would miss replying to it." [Sharh Al-‘Umdah]
If the person is reciting the Quran and passes by someone, he should greet him, and he should also interrupt the recitation to answer the greeting of another. An-Nawawi wrote, "If the reciter passed by a group of people, he greets them and then continues his recitation. If he repeats the Ta‘awwuth (saying 'A‘oothu billahi min ash-shaytaan Ar-Rajeem') before he resumes, that would be good. It is recommended for the passerby to greet the person reciting the Quran, and it is obligatory on the one reciting the Quran to greet him back verbally." [Al-Majmoo‘]
When the person hears the athaan while lying in bed, he is not obliged to get up; rather, he only replies to it. It is also allowed to reply to the athaan while going out of the house. In general, the Muslim is required, when he hears the athaan, to say what the mu'aththin says, because the Prophet, sallallahu ‘alayhi wa sallam, said, "When you hear the mu'aththin, then say the same that he says..." [Muslim and others]
Allah knows best.