problem with receive SMS

Grumpy_Mike:

I can not post it because it is work for my school that's all.

I don't see how that stops you.

Your problem is that you are using the pulse in function. This type of function is a blocking function, just like the delay function. It is stopping you from receiving the message.
So what you do is to detect the edge of the pulse, that is when it changes from low to high and make a note of the time that occurred.
That is not a blocking function and you can receive your message if one comes in.
Then when you see the reverse transition, that is from a high to low, you make a note of the time. The pulse width is the time between the two transitions.

Note if you do receive a message between transitions then the timing will be invalid, so you need a bit of logic to ignore that.

how can I do what you say ? i am using TCST2103 as anemometer, can you show me is something easy some tutorial ?